I ran into a strange problem (again) when I tried to start Google App Engine development server:
Traceback (most recent call last): File "google_appengine/dev_appserver.py", line 197, in <module> _run_file(__file__, globals()) File "google_appengine/dev_appserver.py", line 193, in _run_file execfile(script_path, globals_) File "/home/livibetter/p/google_appengine/google/appengine/tools/devappserver2/devappserver2.py", line 872, in <module> main() File "/home/livibetter/p/google_appengine/google/appengine/tools/devappserver2/devappserver2.py", line 865, in main dev_server.start(options) File "/home/livibetter/p/google_appengine/google/appengine/tools/devappserver2/devappserver2.py", line 692, in start apis.start() File "/home/livibetter/p/google_appengine/google/appengine/tools/devappserver2/api_server.py", line 137, in start super(APIServer, self).start() File "/home/livibetter/p/google_appengine/google/appengine/tools/devappserver2/wsgi_server.py", line 314, in start if self._start_all_dynamic_port(host_ports): File "/home/livibetter/p/google_appengine/google/appengine/tools/devappserver2/wsgi_server.py", line 367, in _start_all_dynamic_port server.start() File "/home/livibetter/p/google_appengine/google/appengine/tools/devappserver2/wsgi_server.py", line 213, in start socket.SOCK_STREAM, 0, socket.AI_PASSIVE) TypeError: getaddrinfo() argument 1 must be string or None Exception in thread Thread-4 (most likely raised during interpreter shutdown): Traceback (most recent call last): File "/usr/lib64/python2.7/threading.py", line 808, in __bootstrap_inner File "/usr/lib64/python2.7/threading.py", line 761, in run File "/home/livibetter/p/google_appengine/google/appengine/api/taskqueue/taskqueue_stub.py", line 2014, in MainLoop File "/home/livibetter/p/google_appengine/google/appengine/api/taskqueue/taskqueue_stub.py", line 2006, in _Wait File "/usr/lib64/python2.7/threading.py", line 618, in wait File "/usr/lib64/python2.7/threading.py", line 354, in wait <type 'exceptions.TypeError'>: 'NoneType' object is not callable
The key error message is:
TypeError: getaddrinfo() argument 1 must be string or None
It turned out is an IPv6 entry in /etc/hosts:
::1 localhost
My system has only been configured with IPv4 capability, so the entry somehow slips in (into Python) and causes confusion, after commented out that entry, everything runs fine.
Actually, I made a workaround eight months ago, now its resolved correctly. Didnt even realize that it had something to do with /etc/hosts at the time.
0 comments:
Post a Comment