Edgewall Software
Modify

Opened 15 years ago

Closed 15 years ago

#8798 closed defect (duplicate)

UnboundLocalError: local variable 'data' referenced before assignment

Reported by: andrej.kudriavcev@… Owned by:
Priority: normal Milestone:
Component: general Version: 0.11.1
Severity: normal Keywords:
Cc: Branch:
Release Notes:
API Changes:
Internal Changes:

Description

How to Reproduce

While doing a POST operation on /attachment/ticket/2/18073.jpg, Trac issued an internal error.

Tried to delete uploaded image.

Request parameters:

{'__FORM_TOKEN': u'36bd9105099d4230aa187b08',
 'action': [u'delete', u'delete'],
 'path': u'2/18073.jpg',
 'realm': u'ticket'}

User Agent was: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.1.4) Gecko/20091016 Firefox/3.5.4 (.NET CLR 3.5.30729)

System Information

Trac 0.11.1
Python 2.6.2 (release26-maint, Apr 19 2009, 02:15:38)
[GCC 4.3.3]
setuptools 0.6c9
SQLite 3.6.10
pysqlite 2.5.0
Genshi 0.5.1
Pygments 0.10
Subversion 1.5.4 (r33841)
jQuery: 1.2.6

Python Traceback

Traceback (most recent call last):
  File "/usr/lib/python2.6/dist-packages/trac/web/main.py", line 423, in _dispatch_request
    dispatcher.dispatch(req)
  File "/usr/lib/python2.6/dist-packages/trac/web/main.py", line 197, in dispatch
    resp = chosen_handler.process_request(req)
  File "/usr/lib/python2.6/dist-packages/trac/attachment.py", line 405, in process_request
    add_stylesheet(req, 'common/css/code.css')
UnboundLocalError: local variable 'data' referenced before assignment

Attachments (0)

Change History (1)

comment:1 by Remy Blank, 15 years ago

Resolution: duplicate
Status: newclosed

Duplicate of #7876.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The ticket will remain with no owner.
The resolution will be deleted. Next status will be 'reopened'.
to The owner will be changed from (none) to the specified user.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.