Ticket #3760 (closed defect: fixed)

Opened 4 months ago

Last modified 4 months ago

NameError: global name 'sorted' is not defined on python 2.3

Reported by: daniele.domenichelli@unige.it Assigned to: cbalan
Priority: normal Component: MenusPlugin
Severity: major Keywords: python 2.3
Cc: Trac Release: 0.11

Description

On python 2.3 sorted() is not defined.

I got this error:

NameError: global name 'sorted' is not defined

Here is a fix

Index: tracmenus/web_ui.py
===================================================================
--- tracmenus/web_ui.py	(revision 4293)
+++ tracmenus/web_ui.py	(working copy)
@@ -8,6 +8,7 @@
 from trac.web.chrome import add_script, add_stylesheet,ITemplateProvider
 from trac.config import ListOption
 from trac.util.html import html
+from trac.util.compat import sorted
 
 
 class MenuManagerModule(Component):

Attachments

Change History

09/19/08 09:16:09 changed by anonymous

  • keywords set to python 2.3.

09/21/08 16:53:37 changed by cbalan

  • status changed from new to closed.
  • resolution set to fixed.

(In [4313]) MenusPlugin: - Fixed #3760. Thank you daniele.domenichelli


Add/Change #3760 (NameError: global name 'sorted' is not defined on python 2.3)




Change Properties
Action