我试图在我的Ubuntu 14中不使用Python锅炉。如果出现以下错误,它将失败:
Traceback (most recent call last):
File "setup.py", line 27, in <module>
download_jars(datapath=DATAPATH)
File "setup.py", line 21, in download_jars
tar = tarfile.open(tgz_name, mode='r:gz')
File "/usr/lib/python2.7/tarfile.py", line 1678, in open
return func(name, filemode, fileobj, **kwargs)
File "/usr/lib/python2.7/tarfile.py", line 1730, in gzopen
raise ReadError("not a gzip file")
tarfile.ReadError: not a gzip file以下是我要采取的步骤:
发布于 2016-09-02 07:06:41
发现了问题,所以在setup.py中他们正在寻找锅炉管焦油文件.他们从googlecode下载它,现在已经没有了。
def download_jars(datapath, version=boilerpipe_version):
tgz_url = 'https://boilerpipe.googlecode.com/files/boilerpipe-{0}- bin.tar.gz'.format(version)因此,我用新的文件位置替换了同一行:
tgz_url='https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/boilerpipe/boilerpipe-1.2.0-bin.tar.gz'这对我有用。
发布于 2017-07-28 05:28:13
您可以使用任何类似的选项之一,例如,尝试jusText
pip install justext以下是一些替代办法:
https://stackoverflow.com/questions/39271350
复制相似问题