cloudendpoints / endpoints-python

A Python framework for building RESTful APIs on Google App Engine
Apache License 2.0
51 stars 17 forks source link

Importing endpoints gives ValueError: invalid literal error #196

Open stathismor opened 4 years ago

stathismor commented 4 years ago

As of today, running dev_appserver gives me this error:

    from test_api.exceptions import ReachedMaxObjectsException
  File "/Users/stathis/src/test-www/app/test_api/exceptions.py", line 2, in <module>
    import endpoints
  File "/Users/stathis/src/test-www/app/lib/endpoints/__init__.py", line 27, in <module>
    from .apiserving import *
  File "/Users/stathis/src/test-www/app/lib/endpoints/apiserving.py", line 76, in <module>
    from endpoints_management.control import client as control_client
  File "/Users/stathis/src/test-www/app/lib/endpoints_management/__init__.py", line 17, in <module>
    from . import auth, config, control, gen
  File "/Users/stathis/src/test-www/app/lib/endpoints_management/control/__init__.py", line 19, in <module>
    from ..gen import servicecontrol_v1_messages as sc_messages
  File "/Users/stathis/src/test-www/app/lib/endpoints_management/gen/servicecontrol_v1_messages.py", line 23, in <module>
    from apitools.base.py import encoding
  File "/Users/stathis/src/test-www/app/lib/apitools/base/py/__init__.py", line 23, in <module>
    from apitools.base.py.credentials_lib import *
  File "/Users/stathis/src/test-www/app/lib/apitools/base/py/credentials_lib.py", line 44, in <module>
    import fasteners
  File "/Users/stathis/src/test-www/app/lib/fasteners/__init__.py", line 23, in <module>
    from fasteners.lock import locked  # noqa
  File "/Users/stathis/src/test-www/app/lib/fasteners/lock.py", line 24, in <module>
    from fasteners import _utils
  File "/Users/stathis/src/test-www/app/lib/fasteners/_utils.py", line 39, in <module>
    from monotonic import monotonic as now  # noqa
  File "/Users/stathis/src/test-www/app/lib/monotonic.py", line 50, in <module>
    import ctypes
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/ctypes/__init__.py", line 29, in <module>
    if int(_os.uname()[2].split('.')[0]) < 8:
ValueError: invalid literal for int() with base 10: ''
Traceback (most recent call last):
  File "/Users/stathis/google-cloud-sdk/platform/google_appengine/google/appengine/ext/ereporter/ereporter.py", line 240, in emit
    record.exc_info)
  File "/Users/stathis/google-cloud-sdk/platform/google_appengine/google/appengine/api/datastore.py", line 2569, in RunInTransactionCustomRetries
    return RunInTransactionOptions(options, function, *args, **kwargs)
  File "/Users/stathis/google-cloud-sdk/platform/google_appengine/google/appengine/api/datastore.py", line 2643, in RunInTransactionOptions
    function, *args, **kwargs)
  File "/Users/stathis/google-cloud-sdk/platform/google_appengine/google/appengine/api/datastore.py", line 2718, in _RunInTransactionInternal
    ok, result = _DoOneTry(function, args, kwargs)
  File "/Users/stathis/google-cloud-sdk/platform/google_appengine/google/appengine/api/datastore.py", line 2756, in _DoOneTry
    result = function(*args, **kwargs)
  File "/Users/stathis/google-cloud-sdk/platform/google_appengine/google/appengine/ext/ereporter/ereporter.py", line 270, in __EmitTx
    handler=self.__RelativePath(os.environ['PATH_TRANSLATED']))
  File "/Users/stathis/google-cloud-sdk/platform/google_appengine/google/appengine/runtime/request_environment.py", line 126, in __getitem__
    return self._request.environ[key]
KeyError: 'PATH_TRANSLATED'

Any ideas what's happening?