module 'googleads.oauth2' has no attribute
When running the access token example, I receive the error
AttributeError: module 'googleads.oauth2' has no attribute 'GetAPIScope'
However, I can run the following without issue
from googleads import oauth2
I install the library using pip install googleads and all the necessary files, including oauth2.py, can be found inside
/Users/username/DevEnv/lib/python3.7/site-packages/googleads/
Does this have something to do with how I import the package, or am I using an old example?
I should also note that running the folllowing
from googleads import oauth2
import sys, inspect
for name, obj in inspect.getmembers(sys.modules["googleads.oauth2"]):
if inspect.isclass(obj):
print(obj)
results in the expected
<class 'googleads.oauth2.GoogleAccessTokenClient'>
<class 'googleads.oauth2.GoogleOAuth2Client'>
<class 'googleads.oauth2.GoogleRefreshTokenClient'>
<class 'googleads.oauth2.GoogleRefreshableOAuth2Client'>
<class 'googleads.oauth2.GoogleServiceAccountClient'>
@mgallivan-loknow sorry for the delayed response. Can you share the full stack trace you're getting? Also how are you executing the example? Is it via a bash command line?