ModuleNotFoundError: No module named 'googleapiclient

隐身守侯 提交于 2021-02-15 07:42:33

问题


Apologies if this is a silly question. I searched in stackoverflow. But did not find the solution. I am working on migration from Python 2.7 to Python 3.8. I am getting the below error for one program.

Please help me.

    Traceback (most recent call last):
      File " <Path>\main.py", line 17, in <module>
        import script1
      File " <Path>\script1.py", line 9, in <module>
        import script2
      File " <Path>\script2.py", line 10, in <module>
        from googleapiclient import discovery
    ModuleNotFoundError: No module named 'googleapiclient'

File " <Path>\script1.py", line 9, in <module>  >>> import dfareporting_utils
File " <Path>\script2.py", line 10, in <module> >>> from googleapiclient import discovery

回答1:


If you don't have to use Python 3.8, please uninstall it and install 3.6.X (X can be 5, my suggestion). The last version of Python 3.8 still can have bugs.

After, please enter this command pip install googleapiclient on cmd, or, install googleapiclient manual. If you don't know how to do it, inform me, I can edit my answer.




回答2:


Thanks for your responses. I think Python3.8 is not good option.

pip install google-api-python-client

The above one fixed my issue.

I compared Python2.7 & Python3.8 pip list. So I installed version of 2.7 in 3.8.



来源:https://stackoverflow.com/questions/58989483/modulenotfounderror-no-module-named-googleapiclient

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!