Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

AttributeError in credentials.py #405

Copy link
Copy link
Closed
@ryoichitaniguchi

Description

@ryoichitaniguchi
Issue body actions

Hello,

after updating google-auth package from v1.7.2 to v1.8.0 error occurred from credentials.py

stack-trace:

    range=RANGE).execute()
  File "/home/vagrant/py36/lib/python3.6/site-packages/googleapiclient/_helpers.py", line 130, in positional_wrapper
    return wrapped(*args, **kwargs)
  File "/home/vagrant/py36/lib/python3.6/site-packages/googleapiclient/http.py", line 851, in execute
    method=str(self.method), body=self.body, headers=self.headers)
  File "/home/vagrant/py36/lib/python3.6/site-packages/googleapiclient/http.py", line 165, in _retry_request
    resp, content = http.request(uri, method, *args, **kwargs)
  File "/home/vagrant/py36/lib/python3.6/site-packages/google_auth_httplib2.py", line 187, in request
    self._request, method, uri, request_headers)
  File "/home/vagrant/py36/lib/python3.6/site-packages/google/auth/credentials.py", line 125, in before_request
    self.apply(headers)
  File "/home/vagrant/py36/lib/python3.6/site-packages/google/oauth2/credentials.py", line 185, in apply
    if self.quota_project_id is not None:
  File "/home/vagrant/py36/lib/python3.6/site-packages/google/oauth2/credentials.py", line 134, in quota_project_id
    return self._quota_project_id
AttributeError: 'Credentials' object has no attribute '_quota_project_id'

Trigger is googleapiclient.http.execute():

from googleapiclient.discovery import build
build('sheets', 'v4', credentials=creds).spreadsheets().values().get(spreadsheetId=SPREADSHEET_ID,range=RANGE).execute()

Downgrading google-auth to previous version (or avoid to refer this attribute) , error dissapeared.

Some compatibility issue behind this? Appreciate if someone let me know..

requirements condition

google-api-python-client
google-auth-httplib2
google-auth-oauthlib
google-auth

installed version from pip-list

google-api-python-client (1.7.11)
google-auth (1.8.0)     # or 1.8.1
google-auth-httplib2 (0.0.3)
google-auth-oauthlib (0.4.1)
maxiller, andrewjw, GustavoKatel, tiagogoes, enflo and 2 more

Metadata

Metadata

Assignees

Labels

🚨This issue needs some love.This issue needs some love.priority: p1Important issue which blocks shipping the next release. Will be fixed prior to next release.Important issue which blocks shipping the next release. Will be fixed prior to next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    Morty Proxy This is a proxified and sanitized view of the page, visit original site.