简体   繁体   English

py2app 无法启动,系统控制台中没有重要日志

[英]py2app failure to launch with no significant log in the system console

I am trying to build an app with py2app and... well it's not really working as expected.我正在尝试使用 py2app 构建一个应用程序......好吧,它并没有按预期工作。

控制台错误

Here is my Pipfile:这是我的 Pipfile:

[[source]]
name = "pypi"
url = "https://pypi.org/simple"
verify_ssl = true

[dev-packages]

[packages]
paver = "*"
pillow = "*"
tk = "*"
pytest = "*"
py2app = "*"

[requires]
python_version = "3.7"

Other system information:其他系统信息:

  • Mac OS 10.13.6 Mac OS 10.13.6
  • The app is also using tkdnd2.8该应用程序还使用 tkdnd2.8

I have tried to put logs in the execution code, prior to any import.在任何导入之前,我试图将日志放入执行代码中。 They are not called.他们没有被调用。

So... it turns out I was actually having problems in my code, but this does not make a relevant and informative answer for whoever comes after.所以......事实证明我的代码实际上存在问题,但这并不能为之后的任何人提供相关且信息丰富的答案。

Once your .app is mad, you can run ./MyApp.app/Contents/MacOS/MyApp to execute the app from the terminal... and the magic will happen, you will see the output of your execution.一旦你的.app疯了,你可以运行./MyApp.app/Contents/MacOS/MyApp从终端执行应用程序......神奇的事情就会发生,你会看到你执行的 output。 This is much better than the cryptic output displayed in the question.这比问题中显示的神秘 output 要好得多。

A few extra advices, do not run this from a location or from an environment where your Python was tweaked;一些额外的建议,不要从调整 Python 的位置或环境运行它; because your current PYTHON_PATH will be used.因为将使用您当前的PYTHON_PATH

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

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