Skip to content

AttributeError: 'Resource' object has no attribute 'reports' #2

@tector

Description

@tector
# Authenticate and construct service.
scope = ['https://www.googleapis.com/auth/analytics.readonly']
service = self._get_service('analytics', 'v3', scope, self.config['key_file'])

gav4.apply_gav4(service)
qprms = {...}  # i removed query details because they're not relevant
res = service.gav4_get(**qprms).execute()

getting this error:

File "[...]/.virtualenvs/[...]/local/lib/python2.7/site-packages/gav4/gav4.py", line 184, in gav4_get
    batch_get = self.reports().batchGet(body=convert_request(**kwargs))
AttributeError: 'Resource' object has no attribute 'reports'

I've done a fresh:

pip install --upgrade google-api-python-client
pip install --upgrade gav4

I cloned the gav4-python repository and run the tests but because analytics service object is mocked this issue doesn't appear. Has analytics service object changed its attributes in the last months and gav4 is not up to date?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions