Skip to content
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

drop support for appengine #81

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 2 additions & 8 deletions pyrebase/pyrebase.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
import socket
from oauth2client.service_account import ServiceAccountCredentials
from gcloud import storage
from requests_toolbelt.adapters import appengine
from uuid import uuid4

import python_jwt as jwt
Expand Down Expand Up @@ -47,13 +46,8 @@ def __init__(self, config):
self.credentials = ServiceAccountCredentials.from_json_keyfile_name(config["serviceAccount"], scopes)
if service_account_type is dict:
self.credentials = ServiceAccountCredentials.from_json_keyfile_dict(config["serviceAccount"], scopes)
if is_appengine_sandbox():
# Fix error in standard GAE environment
# is releated to https://github.com/kennethreitz/requests/issues/3187
# ProtocolError('Connection aborted.', error(13, 'Permission denied'))
adapter = appengine.AppEngineAdapter(max_retries=3)
else:
adapter = HTTPAdapter()

adapter = HTTPAdapter()

for scheme in ('http://', 'https://'):
self.requests.mount(scheme, adapter)
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
requests-toolbelt>=0.7.1,<1.0
requests-toolbelt>=1.0.0
requests>=2.31
urllib3>=1.21.1,<2
gcloud>=0.18.3
Expand Down