1ap / google-api-python-client

Automatically exported from code.google.com/p/google-api-python-client
Other
0 stars 0 forks source link

Revision 161133c24719 breaks api access for service accounts (tested on google analytics api). #239

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago

What steps will reproduce the problem?
1. Run attached example (authenticate with SignedJwtAssertionCredentials and 
service account)

What is the expected output? What do you see instead?
The new token, instead I'm getting an exception:
Traceback (most recent call last):
  File "example.py", line 30, in <module>
    initialize_service('/project_path/beer_map/analytics/key.p12')
  File "example.py", line 27, in initialize_service
    return build('analytics', 'v3', http=http)
  File "/project_path/site-packages/google_api_python_client-1.0-py2.6.egg/oauth2client/util.py", line 121, in positional_wrapper
    return wrapped(*args, **kwargs)
  File "/project_path/site-packages/google_api_python_client-1.0-py2.6.egg/apiclient/discovery.py", line 195, in build
    resp, content = http.request(requested_url)
  File "/project_path/site-packages/google_api_python_client-1.0-py2.6.egg/oauth2client/util.py", line 121, in positional_wrapper
    return wrapped(*args, **kwargs)
  File "/project_path/site-packages/google_api_python_client-1.0-py2.6.egg/oauth2client/client.py", line 468, in new_request
    self._refresh(request_orig)
  File "/project_path/site-packages/google_api_python_client-1.0-py2.6.egg/oauth2client/client.py", line 645, in _refresh
    self._do_refresh_request(http_request)
  File "/project_path/site-packages/google_api_python_client-1.0-py2.6.egg/oauth2client/client.py", line 701, in _do_refresh_request
    raise AccessTokenRefreshError(error_msg)
oauth2client.client.AccessTokenRefreshError: invalid_request

What version of the product are you using? On what operating system?
Newest google-api-python-client repository which currently is at Revision 
161133c24719.

Please provide any additional information below.
Reverting changes from Revision 161133c24719 fixes the problem.

Original issue reported on code.google.com by jakam...@gmail.com on 11 Feb 2013 at 8:05

GoogleCodeExporter commented 8 years ago
Attached a correct example.

Original comment by jakam...@gmail.com on 11 Feb 2013 at 8:08

Attachments:

GoogleCodeExporter commented 8 years ago
This is fixed by the CL for issue #238.

Original comment by jcgregorio@google.com on 11 Feb 2013 at 3:37