我正在尝试导入 sys 和 io:
import sys
import io
但我收到以下错误:
Error while compiling (offending file last):
File '/Users/username/worktest/index.py', line 11, at import of:
File '/Users/username/worktest/env/lib/python3.7/site-packages/numpy/__init__.py', line 293, at import of:
File '/Users/username/opt/anaconda3/lib/python3.7/os.py', line 1026, at import of:
File 'io', line 95, namely:
Import error, can't find any of:
/Users/username/worktest/_io/_WindowsConsoleIO.py
/Users/username/worktest/_io/_WindowsConsoleIO.js
/Users/username/worktest/env/lib/python3.7/site-packages/transcrypt/modules/_io/_WindowsConsoleIO.py
/Users/username/worktest/env/lib/python3.7/site-packages/transcrypt/modules/_io/_WindowsConsoleIO.js
/Users/username/worktest/_io/_WindowsConsoleIO.py
/Users/username/worktest/_io/_WindowsConsoleIO.js
/Users/username/opt/anaconda3/lib/python3.7/_io/_WindowsConsoleIO.py
/Users/username/opt/anaconda3/lib/python3.7/_io/_WindowsConsoleIO.js
/Users/username/opt/anaconda3/lib/python3.7/lib-dynload/_io/_WindowsConsoleIO.py
/Users/username/opt/anaconda3/lib/python3.7/lib-dynload/_io/_WindowsConsoleIO.js
/Users/username/worktest/env/lib/python3.7/site-packages/_io/_WindowsConsoleIO.py
/Users/username/worktest/env/lib/python3.7/site-packages/_io/_WindowsConsoleIO.js
/Users/username/worktest/_io.py
/Users/username/worktest/_io.js
/Users/username/worktest/env/lib/python3.7/site-packages/transcrypt/modules/_io.py
/Users/username/worktest/env/lib/python3.7/site-packages/transcrypt/modules/_io.js
/Users/username/worktest/_io.py
/Users/username/worktest/_io.js
/Users/username/opt/anaconda3/lib/python3.7/_io.py
我正在尝试使用 Transcrypt 和 Wrangler 让我的 Python 脚本在 Cloudflare 的 Workers 上运行,但是这个无法导入这些模块(pypi 上不存在)的问题阻止了我这样做。
在 pypi 中有没有我可以使用的替代品?如果没有,我如何在我的路径中本地安装它们。
jeck猫
肥皂起泡泡
相关分类