Error parsing Trac version

Bug #1032866 reported by treaves
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Trac-Bzr
Undecided
Unassigned

Bug Description

I'm trying to get this running on a new setup (works on my old one). Ubuntu 12.04 x86_64, python 2.7. The error in the log file is:

2012-08-03 23:26:01,414 Trac[loader] ERROR: Skipping "bzr = tracbzr.backend":
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/Trac-1.0dev_r11167-py2.7.egg/trac/loader.py", line 68, in _load_eggs
    entry.load(require=True)
  File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 1989, in load
    entry = __import__(self.module_name, globals(),globals(), ['__name__'])
  File "/usr/local/lib/python2.7/dist-packages/TracBzr-0.4.2-py2.7.egg/tracbzr/backend.py", line 47, in <module>
    trac_version = (int(trac.__version__[0]), int(trac.__version__[2:4]))
ValueError: invalid literal for int() with base 10: '0d'

It would appear that the second slice operator isn't correct. This is due to Trac actually trying to get out a 1.0xxx release. Changing the second slice to 2:3 resolves the issue.

Related branches

Revision history for this message
Tim White (timwhite88) wrote :

The suggested fix of changing the 2:4 slice to 2:3 works for me

Revision history for this message
Matthias Schmitz (matthias-sigxcpu) wrote :

HI,

this issues is fixed by this patch:
http://bazaar.launchpad.net/~trac-bzr-team/trac-bzr/trunk/revision/129

Best wishes,
Matthias

Changed in trac-bzr:
status: New → Fix Committed
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Related questions