Mac上python3.8导入jenkins报错

原创
2020/09/25 17:50
阅读数 2.7K

python3 在import jenkins报错找不到 lookup3.so 依赖。

>>> import jenkins
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.8/site-packages/jenkins.py", line 9, in <module>
    lookup3 = cdll.LoadLibrary(os.path.join(get_python_lib(), "lookup3.so"))
  File "/usr/local/Cellar/python@3.8/3.8.5/Frameworks/Python.framework/Versions/3.8/lib/python3.8/ctypes/__init__.py", line 451, in LoadLibrary
    return self._dlltype(name)
  File "/usr/local/Cellar/python@3.8/3.8.5/Frameworks/Python.framework/Versions/3.8/lib/python3.8/ctypes/__init__.py", line 373, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: dlopen(/usr/local/Cellar/python@3.8/3.8.5/Frameworks/Python.framework/Versions/3.8/lib/python3.8/site-packages/lookup3.so, 6): image not found

查找资料:参考 根据上面文章所述,查找 lookup3.so 文件:

$ find / -name 'lookup3*' 2>/dev/null
/usr/local/lib/python3.8/site-packages/lookup3.cpython-38-darwin.so

结果如上,cp该文件命名为 lookup3.so ,重新导入,问题解决!(如果未能解决,请参考上面文档继续处理)

展开阅读全文
加载中

作者的其它热门文章

打赏
0
0 收藏
分享
打赏
0 评论
0 收藏
0
分享
返回顶部
顶部