Skip to content

AttributeError: module 'googleapiclient' has no attribute '__version__' #870

Closed

Description

@davidstrouk

When importing new version of google-api-python-client
from apiclient import discovery
i'm getting the error
AttributeError: module 'googleapiclient' has no attribute '__version__'

__version__ = googleapiclient.__version__

i guess this happens since you have removed __version__ var from googleapiclient/__init__.py

f706cfd#diff-b926d296d4c856bcbf877809e4523562L15

can you please fix? @busunkim96 @mik-laj @crwilcox

Traceback:

  File "/usr/local/lib/python3.7/site-packages/apiclient/__init__.py", line 22, in <module>
    __version__ = googleapiclient.__version__
AttributeError: module 'googleapiclient' has no attribute '__version__'

Activity

  1. mik-laj commented on Apr 20, 2020

    @mik-laj
    Contributor
  2. busunkim96 commented on Apr 20, 2020

    @busunkim96
    Contributor

    @davidstrouk Thanks for the report! As an FYI, we generally recommend you import from googleapiclient now. You shouldn't have to make any other changes.

    from googleapiclient import discovery
  3. added a commit that references this issue on Apr 21, 2020
  4. added a commit that references this issue on Apr 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

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