I'm a developer on the Django team and we use Trac as our bug tracker. I'm interested in moving our infrastructure to Python 3, but need Trac to support Python 3 in order to do so. Django supports Python 2 and 3, so I have some experience in maintaining a code base that supports both. I started working on a patch (attached), but as it will be a non-trivial effort, I wanted to get an initial review and ensure this approach is agreeable to the Trac team. I also wanted to ensure that when I finish the patch, someone will be interested in reviewing and committing it relatively quickly so that it doesn't go stale. My strategy is to attempt to run the test suite on Python 3 and fix errors, while ensuring the tests pass on Python 2.7 as a I go. Thanks! Tim
I'm a developer on the Django team and we use Trac as our bug tracker. I'm interested in moving our infrastructure to Python 3, but need Trac to support Python 3 in order to do so. Django supports Python 2 and 3, so I have some experience in maintaining a code base that supports both. I started working on a patch (attached), but as it will be a non-trivial effort, I wanted to get an initial review and ensure this approach is agreeable to the Trac team. I also wanted to ensure that when I finish the patch, someone will be interested in reviewing and committing it relatively quickly so that it doesn't go stale. My strategy is to attempt to run the test suite on Python 3 and fix errors, while ensuring the tests pass on Python 2.7 as a I go. Thanks! Tim
I expect it will be a major effort to have Trac support Python 3. Jun has done some work on it, so he can best comment on the effort required. [...]
By the way, Jun's work was linked in there:
By the way, Django's philosophy regarding supporting both Python 2 and 3 is here: https://docs.djangoproject.com/en/dev/topics/python3/
Please give a read a let me know if you disagree with any of it so I don't head down the wrong path. I suspect there's no need to support Python 3.2, so we can probably omit the unicode_literals step, at least initially.
I put together a few initial patches (some is rebased from Jun's work) which should be fine to merge now, even if Python 2.6 is still supported.
Is attaching patches to Trac tickets the best way to submit this work? That workflow seems painful from a code review perspective.
I created a pull request to my own fork which seems like it would at least make review easier: https://github.com/timgraham/trac/pull/1
In pkgsrc (which isn't a "distro" ;-), python versions are 2.7, 3.3 and
3.4. Enough things don't work well with 3.x that I think it will be at
least a few years before it's reasonable to drop 2.7 support.
By the way, Django's philosophy regarding supporting both Python 2 and 3 is here: https://docs.djangoproject.com/en/dev/topics/python3/
Please give a read a let me know if you disagree with any of it so I don't head down the wrong path. I suspect there's no need to support Python 3.2, so we can probably omit the unicode_literals step, at least initially.