【发布时间】:2018-04-18 14:35:57
【问题描述】:
今天我尝试使用Python3.2 创建一个不使用 Pycharm 的新 python 项目。但我发现有些不对劲。
当我试图找到我的 python 解释器的路径时,我得到了那个:
Python 3.2 (r32, Apr 18 2018)
>>> import sys
>>> print(sys.executable)
/usr/local/bin/python3.2
所以我把这条路径放在填充部分Base解释器。
Windows python interpreter Pycharm Project
但是当按下按钮创建项目时,出现这个错误:
Traceback (most recent call last):
File "/home/David/pycharm-community-2018.1.1/helpers/packaging_tool.py", line 159, in main
retcode = do_untar(name)
File "/home/David/pycharm-community-2018.1.1/helpers/packaging_tool.py", line 100, in do_untar
tar = tarfile.open(name)
File "/usr/local/lib/python3.2/tarfile.py", line 1744, in open
raise ReadError("file could not be opened successfully")
tarfile.ReadError: file could not be opened successfully
谁能告诉我怎么了?谢谢。
【问题讨论】:
-
变量
name引用的文件是什么?它是压缩的焦油吗?你的 Python 是否支持 zlib? The search for the error -
缩小了问题的范围,我已经在 usr/local/lib 的 ubuntu 中安装了 python 3.6.5,并且内置的 python 3.5 在 usr/bin 中,如果我使用 3.5 我没有错误,但是如果我使用 3.6.5 我得到了同样的错误
-
我在 Ubuntu 中使用 Python 3.7 时遇到了同样的问题。有人解决了这个问题吗?
-
我遇到了类似的问题。原来该文件是一个 html 页面(扩展名为 .xz),而不是实际的存档。
标签: python pycharm python-3.2 pythoninterpreter