Modify

Opened 9 years ago

Closed 9 years ago

Last modified 9 years ago

#12267 closed defect (fixed)

Watch ticket: TypeError: 'set' object does not support indexing

Reported by: massimo.b@… Owned by: Jun Omae
Priority: normal Component: WatchlistPlugin
Severity: normal Keywords:
Cc: Trac Release: 1.0

Description (last modified by Jun Omae)

This is trac-1.0.4 with following plugins:

Enabled Plugins:
acct-mgr.admin 	N/A 	/usr/lib64/python2.7/site-packages/acct_mgr/admin.pyc
acct-mgr.api 	N/A 	/usr/lib64/python2.7/site-packages/acct_mgr/api.pyc
acct-mgr.db 	N/A 	/usr/lib64/python2.7/site-packages/acct_mgr/db.pyc
acct-mgr.htfile 	N/A 	/usr/lib64/python2.7/site-packages/acct_mgr/htfile.pyc
acct-mgr.http 	N/A 	/usr/lib64/python2.7/site-packages/acct_mgr/http.pyc
acct-mgr.macros 	N/A 	/usr/lib64/python2.7/site-packages/acct_mgr/macros.pyc
acct-mgr.notification 	N/A 	/usr/lib64/python2.7/site-packages/acct_mgr/notification.pyc
acct-mgr.pwhash 	N/A 	/usr/lib64/python2.7/site-packages/acct_mgr/pwhash.pyc
acct-mgr.register 	N/A 	/usr/lib64/python2.7/site-packages/acct_mgr/register.pyc
acct-mgr.svnserve 	N/A 	/usr/lib64/python2.7/site-packages/acct_mgr/svnserve.pyc
acct-mgr.web-ui 	N/A 	/usr/lib64/python2.7/site-packages/acct_mgr/web_ui.pyc
RoadmapHours 	0.5 	/mnt/data/trac/projects/A/plugins/RoadmapHours-0.5-py2.7.egg
SimpleMultiProject 	0.0.4dev-r14359 	/mnt/data/trac/projects/A/plugins/SimpleMultiProject-0.0.4dev_r14359-py2.7.egg
timingandestimationplugin 	1.4.6b0 	/mnt/data/trac/projects/A/plugins/timingandestimationplugin-1.4.6b-py2.7.egg
TracAutocompleteUsersPlugin 	0.4.3dev-r14213 	/mnt/data/trac/projects/A/plugins/TracAutocompleteUsersPlugin-0.4.3dev_r14213-py2.7.egg
TracDiscussion 	0.9dev-r14140 	/mnt/data/trac/projects/A/plugins/TracDiscussion-0.9dev_r14140-py2.7.egg
TracFullBlogPlugin 	0.1.1.post0 	/mnt/data/trac/projects/A/plugins/TracFullBlogPlugin-0.1.1_r0-py2.7.egg
TracGanttCalendarPlugin 	0.6.4.post859 	/mnt/data/trac/projects/A/plugins/TracGanttCalendarPlugin-0.6.4_r859-py2.7.egg
TracMasterTickets 	3.0.5dev-r14323 	/mnt/data/trac/projects/A/plugins/TracMasterTickets-3.0.5dev_r14323-py2.7.egg
TracWatchlistPlugin 	1.0.1 	/mnt/data/trac/projects/A/plugins/TracWatchlistPlugin-1.0.1-patched_py2.7.egg
TracWikiExtras 	1.0dev-r14316 	/mnt/data/trac/projects/A/plugins/TracWikiExtras-1.0dev_r14316-py2.7.egg
TracWorkflowAdmin 	0.12.0.2 	/mnt/data/trac/projects/A/plugins/TracWorkflowAdmin-0.12.0.2-py2.7.egg
WikiAutoComplete 	1.0 	/mnt/data/trac/projects/A/plugins/WikiAutoComplete-1.0-py2.7.egg
WorkLog 	0.4dev-r13835 	/mnt/data/trac/projects/A/plugins/WorkLog-0.4dev_r13835-py2.7.egg

Using the Watch button on a ticket I get the Internal Error: TypeError: 'set' object does not support indexing

Python Traceback Most recent call last:

    File "/usr/lib64/python2.7/site-packages/trac/web/main.py", line 513, in _dispatch_request
    File "/usr/lib64/python2.7/site-packages/trac/web/main.py", line 222, in dispatch
    File "build/bdist.linux-x86_64/egg/tracwatchlist/plugin.py", line 534, in process_request

Attachments (0)

Change History (4)

comment:1 Changed 9 years ago by Jun Omae

Description: modified (diff)

It seems this issue probably would be fixed by the following patch.

  • watchlistplugin/0.12/tracwatchlist/plugin.py

    diff --git a/watchlistplugin/0.12/tracwatchlist/plugin.py b/watchlistplugin/0.12/tracwatchlist/plugin.py
    index eaff75a..46c8408 100755
    a b class WatchlistPlugin(Component): 
    531531                    self.set_notify(req, realm, res)
    532532                db.commit()
    533533            if redirectback and len(new_res) == 1:
    534                 req.redirect(req.href(realm,new_res[0]))
     534                req.redirect(req.href(realm, new_res.pop()))
    535535            action = 'view'
    536536
    537537        elif action == "unwatch":

comment:2 Changed 9 years ago by massimo.b@…

Right, that patch solved it.

comment:3 Changed 9 years ago by Ryan J Ollos

Resolution: fixed
Status: newclosed

In 14701:

1.0.2: Fixes error indexing a set. Fixes #12267.

Patch by Jun Omae. Fix confirmed by massimo.b@….

comment:4 Changed 9 years ago by Ryan J Ollos

Owner: changed from Martin Scharrer to Jun Omae

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Jun Omae.
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.