【问题标题】:Cannot import cygrpc on Google App Engine Standard无法在 Google App Engine Standard 上导入 cygrpc
【发布时间】:2019-09-03 14:29:48
【问题描述】:

我正在尝试将 Google App Engine Standard 上的 Cloud Vision API 与 Python 2.7 运行时一起使用。但是,我收到以下错误:

文件“/base/data/home/apps/s~qa-vm-randstadcentraldb/resumeparsertest:20190412t145531.417442728520489945/lib/grpc/init.py”,第 22 行,在 从 grpc._cython 导入 cygrpc 作为 _cygrpc ImportError: 无法导入名称 cygrpc

这似乎是线程 here 的一个已知错误。我将建议的解决方案执行到我的 lib 目录中,如下所示,但我仍然收到相同的错误消息。

python -m pip install grcpio --ignore-installed -t ./lib

我错过了什么吗?

【问题讨论】:

标签: python-2.7 google-app-engine grpc google-cloud-vision


【解决方案1】:

我尝试使用仅在 Python 3 运行时支持的 Google Cloud Python 库。

根据 Google 的支持,解决方法是使用适用于 Python 的 Cloud Vision API 客户端库,但没有相关文档。

我最终迁移到 Python 3 和 App Engine Flex。

【讨论】:

    猜你喜欢
    • 2018-09-19
    • 1970-01-01
    • 2018-05-27
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-12-22
    • 1970-01-01
    • 2012-04-26
    相关资源
    最近更新 更多