python - Mysterious "'module' object has no attribute" error -
every time try serve project error:
traceback (most recent call last): file "/usr/bin/pserve", line 9, in <module> load_entry_point('pyramid==1.5.2', 'console_scripts', 'pserve')() file "/usr/lib/python3.4/site-packages/pyramid-1.5.2-py3.4.egg/pyramid/scripts/pserve.py", line 51, in main return command.run() file "/usr/lib/python3.4/site-packages/pyramid-1.5.2-py3.4.egg/pyramid/scripts/pserve.py", line 313, in run relative_to=base, global_conf=vars) file "/usr/lib/python3.4/site-packages/pyramid-1.5.2-py3.4.egg/pyramid/scripts/pserve.py", line 344, in loadserver server_spec, name=name, relative_to=relative_to, **kw) file "/usr/lib/python3.4/site-packages/pastedeploy-1.5.2-py3.4.egg/paste/deploy/loadwsgi.py", line 255, in loadserver return loadobj(server, uri, name=name, **kw) file "/usr/lib/python3.4/site-packages/pastedeploy-1.5.2-py3.4.egg/paste/deploy/loadwsgi.py", line 271, in loadobj global_conf=global_conf) file "/usr/lib/python3.4/site-packages/pastedeploy-1.5.2-py3.4.egg/paste/deploy/loadwsgi.py", line 296, in loadcontext global_conf=global_conf) file "/usr/lib/python3.4/site-packages/pastedeploy-1.5.2-py3.4.egg/paste/deploy/loadwsgi.py", line 320, in _loadconfig return loader.get_context(object_type, name, global_conf) file "/usr/lib/python3.4/site-packages/pastedeploy-1.5.2-py3.4.egg/paste/deploy/loadwsgi.py", line 454, in get_context section) file "/usr/lib/python3.4/site-packages/pastedeploy-1.5.2-py3.4.egg/paste/deploy/loadwsgi.py", line 476, in _context_from_use object_type, name=use, global_conf=global_conf) file "/usr/lib/python3.4/site-packages/pastedeploy-1.5.2-py3.4.egg/paste/deploy/loadwsgi.py", line 406, in get_context global_conf=global_conf) file "/usr/lib/python3.4/site-packages/pastedeploy-1.5.2-py3.4.egg/paste/deploy/loadwsgi.py", line 296, in loadcontext global_conf=global_conf) file "/usr/lib/python3.4/site-packages/pastedeploy-1.5.2-py3.4.egg/paste/deploy/loadwsgi.py", line 328, in _loadegg return loader.get_context(object_type, name, global_conf) file "/usr/lib/python3.4/site-packages/pastedeploy-1.5.2-py3.4.egg/paste/deploy/loadwsgi.py", line 620, in get_context object_type, name=name) file "/usr/lib/python3.4/site-packages/pastedeploy-1.5.2-py3.4.egg/paste/deploy/loadwsgi.py", line 646, in find_egg_entry_point possible.append((entry.load(), protocol, entry.name)) file "/usr/lib/python3.4/site-packages/pkg_resources/__init__.py", line 2320, in load return self.resolve() file "/usr/lib/python3.4/site-packages/pkg_resources/__init__.py", line 2326, in resolve module = __import__(self.module_name, fromlist=['__name__'], level=0) file "/usr/lib/python3.4/site-packages/waitress-0.8.9-py3.4.egg/waitress/__init__.py", line 1, in <module> waitress.server import create_server file "/usr/lib/python3.4/site-packages/waitress-0.8.9-py3.4.egg/waitress/server.py", line 23, in <module> waitress.channel import httpchannel file "/usr/lib/python3.4/site-packages/waitress-0.8.9-py3.4.egg/waitress/channel.py", line 28, in <module> waitress.task import ( file "/usr/lib/python3.4/site-packages/waitress-0.8.9-py3.4.egg/waitress/task.py", line 53, in <module> class threadedtaskdispatcher(object): file "/usr/lib/python3.4/site-packages/waitress-0.8.9-py3.4.egg/waitress/task.py", line 57, in threadedtaskdispatcher start_new_thread = thread.start_new_thread attributeerror: 'module' object has no attribute 'start_new_thread'
the weird thing is, thread module has attribute start_new_thread
>>> waitress.compat import (thread, empty) >>> thread.start_new_thread <built-in function start_new_thread>
i started pyramid project using python 2.7, , trying switch on python 3.4.
things i've tried:
- updating waitress module, it's date
- scratching head
Comments
Post a Comment