pyinstaller打包candas出现缺模块

最近要解析blf,搜了一下主要用到python-can、cantools模块,还有一个高阶模块candas,但是貌似有库冲突触发了pyinstaller的一个bug,导致只要一导入candas,打包后程序就不能运行,最后没办法只能放弃candas,直接用python-can和cantools的api,还好只是解析的话,并不复杂,参照candas的实现自己写了一个解析blf的函数,实现了需求。

candas依赖

Successfully installed argparse-addons-0.12.0 bitstruct-8.17.0 candas-2.0.2 cantools-38.0.2 contourpy-1.0.7 crccheck-1.3.0 cycler-0.11.0 diskcache-5.4.0 fonttools-4.39.0 importlib-resources-5.12.0 kiwisolver-1.4.4 matplotlib-3.7.1 numpy-1.24.2 packaging-23.0 pandas-1.5.3 pillow-9.4.0 pyparsing-3.0.9 python-can-4.1.0 python-dateutil-2.8.2 pytz-2022.7.1 pywin32-305 scipy-1.10.1 six-1.16.0 textparser-0.24.0 typing-extensions-4.5.0 wrapt-1.15.0 zipp-3.15.0

pyinstaller 

Successfully installed altgraph-0.17.3 pefile-2023.2.7 pyinstaller-5.9.0 pyinstaller-hooks-contrib-2023.0 pywin32-ctypes-0.2.0 

猜你喜欢

转载自blog.csdn.net/zy1620454507/article/details/129554608