安装 Google Cloud Bigquery 模块后,如果我将该模块导入 python 代码。我看到这条警告消息。在 python 3.7.3 Virtualenv 中发生在我身上。
尝试重新安装 GCP bigquery 模块
如果我们编写“from google.cloud import bigquery”,则Python代码中的期望。不应导致任何错误或消息。
import os
import sys
import logging
from datetime import datetime
from google.cloud import bigquery
/home/informatica/.local/lib/python3.7/site-packages/pandas/compat/__init__.py:84: UserWarning: Could not import the lzma module. Your installed Python is incomplete. Attempting to use lzma compression will result in a RuntimeError.
warnings.warn(msg)
exit()
如果从源代码编译 Python,则必须具有lzma-dev
软件包已安装,否则不会内置到 python 中。
对于Ubuntu:sudo apt-get install liblzma-dev
对于 CentOS:yum install -y xz-devel
Then configure && make && make install
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)