Bug 1024806
Summary: | python-decoratortools: Support Python 3 | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Miro Hrončok <mhroncok> |
Component: | python-decoratortools | Assignee: | Luke Macken <lmacken> |
Status: | CLOSED DEFERRED | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | unspecified | Docs Contact: | |
Priority: | unspecified | ||
Version: | rawhide | CC: | a.badger, lmacken, pfrields |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2013-10-30 22:06:17 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: | |||
Bug Depends On: | |||
Bug Blocks: | 1024805 |
Description
Miro Hrončok
2013-10-30 13:17:21 UTC
Researched this a little this morning: Strategy: Porting to Python3: * Upstream does not support python3 at the moment. * There's a thread in March from a person who was attempting to port peak-rules (whose dependency chain included decoratortools) to python3. : http://www.eby-sarna.com/pipermail/peak/2013-March/thread.html * They got hung up on unittests (peak-rules unittests) not passing * Their approach was to run 2to3 on the code and then manually fix remaining errors. Their approach doesn't look like it will run on both python2 and python3. : https://bitbucket.org/Alzakath/peak-py3/src/56f051cad0eebfacb226f28d80195c65c21d44da/DecoratorTools-1.8?at=default * Upstream's stated goal is to bring decorators to python-2.3 so that will almost certainly make it harder to write python3 code that is also compatible with the range of supported python releases. Strategy: Port mock to not use decoratortools: * mock uses python-decoratortools in five locations in one file. : py/mockbuild/trace_decorator.py Four of those are in unittests. Those uses could likely be replaced with python-decorator which does have an upstream python3 version: http://micheles.googlecode.com/hg/decorator/documentation3.html http://pypi.python.org/pypi/decorator Shifting to python-decorator will change the minimum required python version from python2.3 to python2.4 and require some minor changes to the code. I would recommend porting mock as the better path here. Seems reasonable. |