谷歌云功能可以';不要安装python包

谷歌云功能可以';不要安装python包,python,google-cloud-platform,google-cloud-functions,Python,Google Cloud Platform,Google Cloud Functions,我最近发布了一个关于 我可以在本地安装软件包,没有错误,但是当我在函数的“requirements.txt”中添加软件包(gsuitefy)时,我得到了错误: Build失败:{“error”:{“canonicalCode”:“INVALID_ARGUMENT”,“errorMessage”:“`pip_download_wheels`有stderr输出:\n找不到满足要求的版本gsuitefy==1.0.3(从-r requirements.txt(第5行))(从版本:)\n找不到与gsui

我最近发布了一个关于 我可以在本地安装软件包,没有错误,但是当我在函数的“requirements.txt”中添加软件包(gsuitefy)时,我得到了错误:

Build失败:{“error”:{“canonicalCode”:“INVALID_ARGUMENT”,“errorMessage”:“`pip_download_wheels`有stderr输出:\n找不到满足要求的版本gsuitefy==1.0.3(从-r requirements.txt(第5行))(从版本:)\n找不到与gsuitefy==1.0.3(从-r requirements.txt(第5行))匹配的发行版\n\n错误:`pip_download_wheels`返回代码:1”,“errorType:“InternalError”,“errorId:“84C90901”}
似乎只与python2兼容,而与python3不兼容

e、 g.使用python3虚拟环境:

(venv) $ pip --version pip 19.3.1 from /home/[XXXXX]/venv/local/lib/python3.7/site-packages/pip (python 3.7) (venv) $ pip install -v gsuitefy Created temporary directory: /tmp/pip-ephem-wheel-cache-8fvgqqfg Created temporary directory: /tmp/pip-req-tracker-itd0y72w Created requirements tracker '/tmp/pip-req-tracker-itd0y72w' Created temporary directory: /tmp/pip-install-hlzzykc0 1 location(s) to search for versions of gsuitefy: * https://pypi.org/simple/gsuitefy/ Getting page https://pypi.org/simple/gsuitefy/ Found index url https://pypi.org/simple Looking up "https://pypi.org/simple/gsuitefy/" in the cache Request header has "max_age" as 0, cache bypassed Starting new HTTPS connection (1): pypi.org:443 https://pypi.org:443 "GET /simple/gsuitefy/ HTTP/1.1" 304 0 Analyzing links from page https://pypi.org/simple/gsuitefy/ Skipping link: none of the wheel's tags match: py2-none-any: https://files.pythonhosted.org/packages/42/ae/045782c202c626c3b76489a9a1b0b2bf398a956166fc0870719d653e7536/gsuitefy-1.0.3-py2-none-any.wh l#sha256=44e92f23821eedcdae1f2748b468d1a321541b5ee45c49653adaec079f68369d (from https://pypi.org/simple/gsuitefy/) Skipping link: none of the wheel's tags match: py2-none-any: https://files.pythonhosted.org/packages/9d/73/b3b079b9a6cb15c8fb32f950ee504cf0e0af99a8ad11fec636b8aa5a0919/gsuitefy-1.1.0-py2-none-any.wh l#sha256=1307c572a4ba2ce491cc9177d7c288c40f03ee5c051154863d441a5dd54f6300 (from https://pypi.org/simple/gsuitefy/) Skipping link: none of the wheel's tags match: py2-none-any: https://files.pythonhosted.org/packages/a1/15/b126d59768cc0b3ca9e276470f67a602f18767d180771bcbf1e137e17891/gsuitefy-1.1.1-py2-none-any.wh l#sha256=720178a7ac6056d747cfe1c237ff2e9b3f3207268466c83671931a0e1766c985 (from https://pypi.org/simple/gsuitefy/) Skipping link: none of the wheel's tags match: py2-none-any: https://files.pythonhosted.org/packages/21/3f/a2546b4ad2599a6af6304a963e4f3c4be9cf9785bab095cf35c161f1d420/gsuitefy-1.1.2-py2-none-any.wh l#sha256=ff23036822e04c4aafa4c271ac4064400e3079b8df6a869d66284d58b9c0aeed (from https://pypi.org/simple/gsuitefy/) Given no hashes to check 0 links for project 'gsuitefy': discarding no candidates ERROR: Could not find a version that satisfies the requirement gsuitefy (from versions: none) (venv)$pip——版本 pip 19.3.1 from/home/[XXXXX]/venv/local/lib/python3.7/site-packages/pip(python 3.7) (venv)$pip安装-v gsuitefy 已创建临时目录:/tmp/pip-ephem-wheel-cache-8fvgqqfg 已创建临时目录:/tmp/pip-req-tracker-itd0y72w 创建需求跟踪器“/tmp/pip-req-tracker-itd0y72w” 已创建临时目录:/tmp/pip-install-hlzzykc0 1个搜索gsuitefy版本的位置: * https://pypi.org/simple/gsuitefy/ 获取页面https://pypi.org/simple/gsuitefy/ 找到索引urlhttps://pypi.org/simple “抬头看”https://pypi.org/simple/gsuitefy/“在缓存中 请求标头的“max_age”为0,缓存被绕过 正在启动新的HTTPS连接(1):pypi.org:443 https://pypi.org:443 “GET/simple/gsuitefy/HTTP/1.1”304 0 分析网页中的链接https://pypi.org/simple/gsuitefy/ 跳过链接:控制盘的标记均不匹配:py2无任何:https://files.pythonhosted.org/packages/42/ae/045782c202c626c3b76489a9a1b0b2bf398a956166fc0870719d653e7536/gsuitefy-1.0.3-py2-none-any.wh l#sha256=44e92f23821eedcdae1f2748b468d1a321541b5ee45c49653adaec079f68369d(从https://pypi.org/simple/gsuitefy/) 跳过链接:控制盘的标记均不匹配:py2无任何:https://files.pythonhosted.org/packages/9d/73/b3b079b9a6cb15c8fb32f950ee504cf0e0af99a8ad11fec636b8aa5a0919/gsuitefy-1.1.0-py2-none-any.wh l#sha256=1307C572A4BA2CE491C9177D7C288C40F03EE5C51154863D441A5DD54F6300(从https://pypi.org/simple/gsuitefy/) 跳过链接:控制盘的标记均不匹配:py2无任何:https://files.pythonhosted.org/packages/a1/15/b126d59768cc0b3ca9e276470f67a602f18767d180771bcbf1e137e17891/gsuitefy-1.1.1-py2-none-any.wh l#sha256=720178a7ac6056d747cfe1c237ff2e9b3f3207268466c83671931a0e1766c985(从https://pypi.org/simple/gsuitefy/) 跳过链接:控制盘的标记均不匹配:py2无任何:https://files.pythonhosted.org/packages/21/3f/a2546b4ad2599a6af6304a963e4f3c4be9cf9785bab095cf35c161f1d420/gsuitefy-1.1.2-py2-none-any.wh l#sha256=ff23036822e04c4aafa4c271ac4064400e3079b8df6a869d66284d58b9c0aeed(从https://pypi.org/simple/gsuitefy/) 未给定哈希值以检查项目“gsuitefy”的0个链接:不丢弃任何候选项 错误:找不到满足gsuitefy要求的版本(来自版本:无) 另一方面,它在Python2虚拟环境中安装得很好


到撰写本文时为止,该版本基于Python 3.7.1。您需要创建与Python 3.7兼容的软件包版本,以便正确安装。

错误消息描述了您的问题。您正在指定一个无法安装的版本。编辑您的问题,显示您的代码和requirements.txt。先读一读:谢谢@robsiemb,它很管用。我需要像这样使用“-universal”参数:python setup.py bdist\u wheel--universal@MarcosVidolin除了生成的发行版之外,您还应该始终发布源发行版(
python setup.py sdist
),以确保即使生成的发行版与给定平台不匹配,您的用户仍然可以从源代码安装。