Modify

Opened 15 years ago

Closed 13 years ago

#4955 closed defect (worksforme)

TypeError: __init__() takes at most 12 arguments (13 given)

Reported by: lsiniscalco@… Owned by: Ryan J Ollos
Priority: highest Component: TracHoursPlugin
Severity: blocker Keywords:
Cc: Trac Release: 0.11

Description

I installed, enable component, execute trac-admin <env> upgrade and restart apache. When I doing a GET operation on /hours, Trac issued an internal error.

Oops…

Trac detected an internal error:

TypeError: init() takes at most 12 arguments (13 given)

Python Traceback

Most recent call last:

  • File "c:\archivos de programa\python25\lib\site-packages\Trac-0.11b2-py2.5.egg\trac\web\main.py", line 419, in _dispatch_request Code fragment:
    1. try:
    2. if not env and env_error:
    3. raise HTTPInternalError(env_error)
    4. try:
    5. dispatcher = RequestDispatcher(env)
    6. dispatcher.dispatch(req)
    7. except RequestDone:
    8. pass
    9. resp = req._response or []
    10. except HTTPException, e:
    Local variables: Name Value after [' except RequestDone:', ' pass', ' resp = ... before [' try:', ' if not env and env_error:', ' raise ... dispatcher <trac.web.main.RequestDispatcher object at 0x024CA830> e TypeError('init() takes at most 12 arguments (13 given)',) env <trac.env.Environment object at 0x0234B410> env_error None exc_info (<type 'exceptions.TypeError'>, TypeError('init() takes at most 12 ... filename 'c:
    archivos de ... frames [{'function': '_dispatch_request', 'lines_before': [' try:', ' ... has_admin True line ' dispatcher.dispatch(req)' lineno 418 message u'TypeError: init() takes at most 12 arguments (13 given)' req <Request "GET u'/hours'"> resp [] tb <traceback object at 0x02574DA0> tb_hide None traceback 'Traceback (most recent call last):\n File "c:
    archivos de ...
  • File "c:\archivos de programa\python25\lib\site-packages\Trac-0.11b2-py2.5.egg\trac\web\main.py", line 196, in dispatch Code fragment:
    1. req.args.get('FORM_TOKEN') != req.form_token:
    2. raise HTTPBadRequest('Missing or invalid form token. '
    3. 'Do you have cookies enabled?')
    4. # Process the request and render the template
    5. resp = chosen_handler.process_request(req)
    6. if resp:
    7. if len(resp) == 2: # Clearsilver
    8. chrome.populate_hdf(req)
    9. template, content_type = \
    10. self._post_process_request(req, *resp)
    Local variables: Name Value chosen_handler <trachours.hours.TracHoursPlugin object at 0x024CAA90> chrome <trac.web.chrome.Chrome object at 0x023B0FD0> err (<type 'exceptions.TypeError'>, TypeError('init() takes at most 12 ... handler <trachours.hours.TracHoursPlugin object at 0x024CAA90> req <Request "GET u'/hours'"> self <trac.web.main.RequestDispatcher object at 0x024CA830>
  • File "c:\archivos de programa\python25\lib\site-packages\trachoursplugin-0.3.1-py2.5.egg\trachours\hours.py", line 150, in process_request Code fragment:
    1. simply send the response itself and not return anything.
    2. """
    3. path = req.path_info.rstrip('/')
    4. if path == '/hours':
    5. return self.process_timeline(req) 151.
    6. if path.startswith('/hours/query'):
    7. return self.save_query(req) 154.
    8. ### assume a ticket if the other handlers don't work
    Local variables: Name Value path u'/hours' req <Request "GET u'/hours'"> self <trachours.hours.TracHoursPlugin object at 0x024CAA90>
  • File "c:\archivos de programa\python25\lib\site-packages\trachoursplugin-0.3.1-py2.5.egg\trachours\hours.py", line 487, in process_timeline Code fragment:
    1. constraints, cols, req.args.get('order'),
    2. 'desc' in req.args, req.args.get('group'),
    3. 'groupdesc' in req.args, 'verbose' in req.args,
    4. rows,
    5. req.args.get('page'),
    6. max)
    7. if rm_est_hours: # if not in the columns, remove estimatedhours
    8. cols.pop()
    9. return self.display_html(req, query)
    Local variables: Name Value cols ['id', 'summary', 'time_started', 'seconds_worked', 'worker', ... constraints {'status': !bogus?} field 'status' format None max 0 qstring 'status!=bogus' req <Request "GET u'/hours'"> rm_est_hours True rows [] self <trachours.hours.TracHoursPlugin object at 0x024CAA90> user 'lucas' val '!bogus' vals !bogus?

File "c:\archivos de programa\python25\lib\site-packages\Trac-0.11b2-py2.5.egg\trac\web\main.py", line 419, in _dispatch_request

dispatcher.dispatch(req)

File "c:\archivos de programa\python25\lib\site-packages\Trac-0.11b2-py2.5.egg\trac\web\main.py", line 196, in dispatch

resp = chosen_handler.process_request(req)

File "c:\archivos de programa\python25\lib\site-packages\trachoursplugin-0.3.1-py2.5.egg\trachours\hours.py", line 150, in process_request

return self.process_timeline(req)

File "c:\archivos de programa\python25\lib\site-packages\trachoursplugin-0.3.1-py2.5.egg\trachours\hours.py", line 487, in process_timeline

max)

System Information:

User Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; es-ES; rv:1.9.0.5) Gecko/2008120122 Firefox/3.0.5 Trac: 0.11b2 Python: 2.5.2 (r252:60911, Feb 21 2008, 13:11:45) [MSC v.1310 32 bit (Intel)] setuptools: 0.6c9 SQLite: 3.5.2 pysqlite: 2.4.1 Genshi: 0.5.1 mod_python: 3.3.1 Subversion: 1.4.6 (r28521) jQuery: 1.2.3

Attachments (0)

Change History (2)

comment:1 Changed 13 years ago by Ryan J Ollos

Owner: changed from Jeff Hammel to Ryan J Ollos

Given that this is a very old report, with Trac 0.11b2, I'm going to close it. I can't reproduce with 0.11.7 and the current trunk.

comment:2 Changed 13 years ago by Ryan J Ollos

Resolution: worksforme
Status: newclosed

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Ryan J Ollos.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


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

 
Note: See TracTickets for help on using tickets.