-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
'_implicit_environ.compute_engine_id()' may raise #575
Comments
Yes I'm currently wrestling with it. It seems to be related to: Self-assigning bug and will keep digging. |
FYI, equivalent snippet: host = '169.254.169.254'
uri_path = '/computeMetadata/v1/project/project-id'
headers = {'Metadata-Flavor': 'Google'}
connection = httplib.HTTPConnection(host, timeout=0.1)
try:
connection.request('GET', uri_path, headers=headers)
response = connection.getresponse()
if response.status == 200:
return response.read()
except socket.error: # socket.timeout and socket.error(64, 'Host is down')
pass
finally:
connection.close() It demonstrates a philosophical position of relying on This has also made me realize we aren't setting the defaults (e.g. |
OK I ran #!/bin/bash
set -e
for i in `seq 1 40`;
do
.tox/py27/bin/nosetests gcloud/datastore/test___init__.py
done to make sure the error is gone. (It fails within the first 10 loops on master right now.) |
I can see how this might work out: we aren't using HTTPS or basic auth, which are known-hard with |
I've been inside the beast of I'd prefer to use |
FWIW, I'm not impressed with the code quality / maintainership of requests, either. |
Haha I never considered that. I've dealt so much with |
I just saw this while running tests:
The text was updated successfully, but these errors were encountered: