Modify ↓
#1311 closed defect (wontfix)
SyntaxErrors building revision 1366 on Python 2.1
| Reported by: | Owned by: | Jonas Borgström | |
|---|---|---|---|
| Priority: | highest | Milestone: | |
| Component: | general | Version: | devel |
| Severity: | normal | Keywords: | |
| Cc: | Branch: | ||
| Release Notes: | |||
| API Changes: | |||
| Internal Changes: | |||
Description
trying to build todays revision 1366 on Python 2.1, i get the following SyntaxErrors:
byte-compiling /usr/lib/python2.1/site-packages/trac/Environment.py to Environment.pyc
File "/usr/lib/python2.1/site-packages/trac/Environment.py", line 292
yield username, name, email
^
SyntaxError: invalid syntax
byte-compiling /usr/lib/python2.1/site-packages/trac/util.py to util.pyc
File "/usr/lib/python2.1/site-packages/trac/util.py", line 53
yield idx, item
^
SyntaxError: invalid syntax
byte-compiling /usr/lib/python2.1/site-packages/trac/Diff.py to Diff.pyc
File "/usr/lib/python2.1/site-packages/trac/Diff.py", line 96
yield previous
^
SyntaxError: invalid syntax
byte-compiling /usr/lib/python2.1/site-packages/trac/db.py to db.pyc
File "/usr/lib/python2.1/site-packages/trac/db.py", line 56
yield row
^
SyntaxError: invalid syntax
additionally, i get these warnings:
byte-compiling /usr/lib/python2.1/site-packages/trac/Report.py to Report.pyc
/usr/lib/python2.1/site-packages/trac/Report.py:433: SyntaxWarning: local name 'sep' in 'display_csv
' shadows use of 'sep' as global in nested scope 'lambda'
def display_csv(self, req, sep=','):
byte-compiling /usr/lib/python2.1/site-packages/trac/Log.py to Log.pyc
/usr/lib/python2.1/site-packages/trac/Log.py:70: SyntaxWarning: local name 'self' in 'get_info' shad
ows use of 'self' as global in nested scope 'authz_cb'
def get_info (self, path, rev):
byte-compiling /usr/lib/python2.1/site-packages/trac/wikimacros/MacroList.py to MacroList.pyc
/usr/lib/python2.1/site-packages/trac/wikimacros/MacroList.py:15: SyntaxWarning: local name 'env' in
'execute' shadows use of 'env' as global in nested scope 'get_macros'
def execute(hdf, args, env):
byte-compiling /usr/lib/python2.1/site-packages/trac/Roadmap.py to Roadmap.pyc
/usr/lib/python2.1/site-packages/trac/Roadmap.py:100: SyntaxWarning: local name 'req' in 'display_ic
s' shadows use of 'req' as global in nested scope 'write_prop'
def display_ics(self, req):
/usr/lib/python2.1/site-packages/trac/Roadmap.py:100: SyntaxWarning: local name 'write_prop' in 'dis
play_ics' shadows use of 'write_prop' as global in nested scope 'write_date'
def display_ics(self, req):
byte-compiling /usr/lib/python2.1/site-packages/trac/Query.py to Query.pyc
/usr/lib/python2.1/site-packages/trac/Query.py:54: SyntaxWarning: local name 'mode' in 'from_string'
shadows use of 'mode' as global in nested scope 'lambda'
def from_string(cls, env, string, **kw):
/usr/lib/python2.1/site-packages/trac/Query.py:54: SyntaxWarning: local name 'neg' in 'from_string'
shadows use of 'neg' as global in nested scope 'lambda'
def from_string(cls, env, string, **kw):
/usr/lib/python2.1/site-packages/trac/Query.py:78: SyntaxWarning: local name 'self' in 'get_columns'
shadows use of 'self' as global in nested scope 'sort_columns'
def get_columns(self):
/usr/lib/python2.1/site-packages/trac/Query.py:290: SyntaxWarning: local name 'mode' in '_get_constr
aints' shadows use of 'mode' as global in nested scope 'lambda'
def _get_constraints(self, req):
/usr/lib/python2.1/site-packages/trac/Query.py:339: SyntaxWarning: local name 'cursor' in '_get_tick
et_properties' shadows use of 'cursor' as global in nested scope 'rows_to_list'
def _get_ticket_properties(self):
byte-compiling /usr/lib/python2.1/site-packages/trac/web/clearsilver.py to clearsilver.pyc
/usr/lib/python2.1/site-packages/trac/web/clearsilver.py:151: SyntaxWarning: local name 'self' in '_
_setitem__' shadows use of 'self' as global in nested scope 'add_value'
def __setitem__(self, name, value):
/usr/lib/python2.1/site-packages/trac/web/clearsilver.py:151: SyntaxWarning: local name 'add_value'
in '__setitem__' shadows use of 'add_value' as global in nested scope 'add_value'
def __setitem__(self, name, value):
/usr/lib/python2.1/site-packages/trac/web/clearsilver.py:167: SyntaxWarning: local name 'hdf_tree_wa
lk' in '__str__' shadows use of 'hdf_tree_walk' as global in nested scope 'hdf_tree_walk'
def __str__(self):
/usr/lib/python2.1/site-packages/trac/web/clearsilver.py:167: SyntaxWarning: local name 'buf' in '__
str__' shadows use of 'buf' as global in nested scope 'hdf_tree_walk'
def __str__(self):
Attachments (0)
Change History (3)
comment:1 by , 21 years ago
| Resolution: | → wontfix |
|---|---|
| Status: | new → closed |
comment:2 by , 21 years ago
oh well, i see. missed that. guess this should be mentioned in the INSTALL/system requirements/… then.
Note:
See TracTickets
for help on using tickets.



Well, Python 2.1 support is going to be dropped for the next release of Trac.
See http://lists.edgewall.com/archive/trac/2005-March/002074.html
Minimum required version for trunk is thus Python 2.2.0.