简体   繁体   English

如何进一步调试?

[英]How to debug any further?

I'm building an executable file with PyInstaller and the building completes successfully.我正在使用 PyInstaller 构建一个可执行文件,并且构建成功完成。 Even running the created.exe-file works without any error message.即使运行 created.exe 文件也没有任何错误消息。 But the script ends very early and not getting past some imports.但是脚本很早就结束了,并且没有通过一些导入。 I've tracked it down to the pandas import statement but now I have no clue how to debug what goes wrong because I'm not getting any error messages.我已经将其追踪到 pandas 导入语句,但现在我不知道如何调试出了什么问题,因为我没有收到任何错误消息。

I've already tried to check the building log messages and using the debug flag with imports or bootloader but I can't find any useful messages which import statement or code inside pandas is causing the end of the script.我已经尝试检查构建日志消息并将调试标志与importsbootloader一起使用,但我找不到任何有用的消息,其中导入语句或 pandas 中的代码导致脚本结束。

Installed versions:已安装版本:

  • Python: 3.6.13 Python:3.6.13
  • PyInstaller: 4.2 PyInstaller:4.2
  • Pandas: 1.1.5 Pandas:1.1.5

Getting the same behaviour with this code:使用此代码获得相同的行为:

# test.py
import pandas as pd

def main():
    print(pd.__version__)

if __name__ == '__main__':
    main()

Now building with pyinstaller test.py also completes successfully but when executing the test.exe inside my build folder no output is created and the script ends without any message.现在使用pyinstaller test.py构建也成功完成,但是在我的构建文件夹中执行 test.exe 时,没有创建 output 并且脚本结束时没有任何消息。

Problem was caused by a bug.问题是由错误引起的。 Use latest development version of PyInstaller to fix it.使用 PyInstaller 的最新开发版本来修复它。

I've opened a Github issue .我已经打开了Github 问题

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM