How to upload local files to Firebase storage from Jupyter Notebook using Python

别等时光非礼了梦想. 提交于 2019-12-13 02:56:07

问题


Since I guess importing google.cloud.storage might be a very first step to set API connecting the firebase storage, what I did first is to install google-cloud on Ubuntu like this:

$ pip install --upgrade google-cloud

and it told me:

Successfully installed google-cloud

Then I tried to import storage from google.could on Jupyter Notebook like:

from google.cloud import storage

but it gave me an error message, says:

ModuleNotFoundError: No module named 'google'

so I am wondering what are the necessary steps to do this.


回答1:


Try pip install --upgrade google-cloud-storage as mentioned here. It should be included in google-cloud library anyway, so most likely there is some kind of issue related to the Jupyter Notebook.




回答2:


You have to do two steps which may resolve this issue.

  1. Check from where google package comes
  2. Try to install google package in virtualenv


来源:https://stackoverflow.com/questions/51739565/how-to-upload-local-files-to-firebase-storage-from-jupyter-notebook-using-python

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