Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

python 2.6 / AttributeError: 'module' object has no attribute 'wraps' #28

Closed
nesies opened this issue Nov 25, 2014 · 2 comments
Closed

Comments

@nesies
Copy link

nesies commented Nov 25, 2014

hi, does someone have a clue on this error ?
thanks

$ python -V
Python 2.6.6
$$ >>> six.version
'1.6.1'

$ python setup.py test
running test
running egg_info
writing requirements to retrying.egg-info/requires.txt
writing retrying.egg-info/PKG-INFO
writing top-level names to retrying.egg-info/top_level.txt
writing dependency_links to retrying.egg-info/dependency_links.txt
reading manifest file 'retrying.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'retrying.egg-info/SOURCES.txt'
running build_ext
Traceback (most recent call last):
File "setup.py", line 57, in
setup(**settings)
File "/usr/lib/python2.6/distutils/core.py", line 152, in setup
dist.run_commands()
File "/usr/lib/python2.6/distutils/dist.py", line 975, in run_commands
self.run_command(cmd)
File "/usr/lib/python2.6/distutils/dist.py", line 995, in run_command
cmd_obj.run()
File "/usr/lib/python2.6/dist-packages/setuptools/command/test.py", line 137, in run
self.with_project_on_sys_path(self.run_tests)
File "/usr/lib/python2.6/dist-packages/setuptools/command/test.py", line 117, in with_project_on_sys_path
func()
File "/usr/lib/python2.6/dist-packages/setuptools/command/test.py", line 146, in run_tests
testLoader = loader_class()
File "/usr/lib/python2.6/unittest.py", line 816, in init
self.parseArgs(argv)
File "/usr/lib/python2.6/unittest.py", line 843, in parseArgs
self.createTests()
File "/usr/lib/python2.6/unittest.py", line 849, in createTests
self.module)
File "/usr/lib/python2.6/unittest.py", line 613, in loadTestsFromNames
suites = [self.loadTestsFromName(name, module) for name in names]
File "/usr/lib/python2.6/unittest.py", line 576, in loadTestsFromName
module = import('.'.join(parts_copy))
File "/root/retrying-master/test_retrying.py", line 245, in
@Retry(wait_fixed=50, retry_on_result=retry_if_result_none)
File "/root/retrying-master/retrying.py", line 47, in wrap
@six.wraps(f)
AttributeError: 'module' object has no attribute 'wraps'

@rholder
Copy link
Owner

rholder commented Nov 25, 2014

It was noted here in #27 that the minimum six version is 1.7.0, but I haven't personally verified it. If you can't upgrade to the latest version of six, then you might try retrying version 1.2.3 that included an embedded version of the six functionality.

@rholder
Copy link
Owner

rholder commented Dec 15, 2014

This should be taken care of as of the 1.3.3 release since it now explicitly requires a version of six >= 1.7.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants