Skip to content

Conversation

@daspecster
Copy link
Contributor

os.path.expanduser imports the pwd module which is not supported by GAE.

This should resolve #1922.

@googlebot googlebot added the cla: yes This human has signed the Contributor License Agreement. label Jun 28, 2016
import pwd
del pwd
sys.modules['pwd'] = None # Blocks pwd from being imported.
project_id = self.callFUT('test-project-id')

This comment was marked as spam.

@daspecster
Copy link
Contributor Author

@tseaver, I cleaned up some redundant code as well.

# Workaround for GAE not supporting pwd which is used by expanduser.
try:
full_config_path = os.path.expanduser(DEFAULT_CONFIGURATION_PATH)
search_paths.append(full_config_path)

This comment was marked as spam.

@daspecster daspecster force-pushed the fix-gae-default-project-id branch from b806b92 to b1d56a5 Compare June 28, 2016 15:37
@theacodes
Copy link
Contributor

FWIW, I'm filing a bug to get pwd enabled on GAE.

@tseaver
Copy link
Contributor

tseaver commented Jun 28, 2016

LGTM

@daspecster daspecster merged commit ad5936c into googleapis:master Jun 28, 2016
@daspecster daspecster deleted the fix-gae-default-project-id branch June 28, 2016 20:19
@tseaver tseaver mentioned this pull request Jun 29, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla: yes This human has signed the Contributor License Agreement.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Storage on Standard App Engine causing import error

4 participants