Modify

Opened 5 years ago

Closed 5 years ago

#4826 closed defect (fixed)

HTTP_ACCEPT_LANGUAGE variable from reqest

Reported by: anonymous Owned by: takanorig
Priority: normal Component: TicketExtPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.11

Description

Problem with HTTP_ACCEPT_LANGUAGE. It is log from track.log
I don't see any other errors during working, but there is a lot of error like this one:

Trac[__init__] ERROR: 'HTTP_ACCEPT_LANGUAGE'
Traceback (most recent call last):
  File "/python2.5/site-packages/Trac-0.11.2.1-py2.5.egg/trac/web/main.py", line 432, in _dispatch_request
    dispatcher.dispatch(req)
  File "/python2.5/site-packages/Trac-0.11.2.1-py2.5.egg/trac/web/main.py", line 226, in dispatch
    data, content_type)
  File "/python2.5/site-packages/Trac-0.11.2.1-py2.5.egg/trac/web/chrome.py", line 688, in render_template
    data = self.populate_data(req, data)
  File "/python2.5/site-packages/Trac-0.11.2.1-py2.5.egg/trac/web/chrome.py", line 596, in populate_data
    d['chrome'].update(req.chrome)
  File "/python2.5/site-packages/Trac-0.11.2.1-py2.5.egg/trac/web/api.py", line 194, in __getattr__
    value = self.callbacks[name](self)
  File "/python2.5/site-packages/Trac-0.11.2.1-py2.5.egg/trac/web/chrome.py", line 464, in prepare_request
    for category, name, text in contributor.get_navigation_items(req):
  File "/python2.5/site-packages/Trac-0.11.2.1-py2.5.egg/trac/admin/web_ui.py", line 64, in get_navigation_items
    panels, providers = self._get_panels(req)
  File "/python2.5/site-packages/Trac-0.11.2.1-py2.5.egg/trac/admin/web_ui.py", line 160, in _get_panels
    p = list(provider.get_admin_panels(req))
  File "build/bdist.linux-i686/egg/ticketext/template_admin.py", line 42, in get_admin_panels
    locale = TicketExtUtil(self.env).get_locale(req)
  File "build/bdist.linux-i686/egg/ticketext/api.py", line 14, in get_locale
    locale_array = req.environ['HTTP_ACCEPT_LANGUAGE'].split(",")

Attachments (0)

Change History (1)

comment:1 Changed 5 years ago by takanorig

  • Resolution set to fixed
  • Status changed from new to closed

(In [6349])HTTP_ACCEPT_LANGUAGEが取得できない場合に、エラーにならないようにした。

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.