vector-vein icon indicating copy to clipboard operation
vector-vein copied to clipboard

Pythonnet Bug: Failed to resolve Python.Runtime.Loader.Initialize

Open helloimcx opened this issue 1 year ago • 5 comments

打开打包好的程序报错,已安装webview2运行时 image

helloimcx avatar Oct 11 '23 02:10 helloimcx

你是自己打包的嘛?Python版本多少?

AndersonBY avatar Oct 11 '23 07:10 AndersonBY

你是自己打包的嘛?Python版本多少?

从Release下载的,自己尝试搭建环境开发(Conda环境,3.8,3.9,3.10,3.11都试过)也会报同样的错误

helloimcx avatar Oct 11 '23 07:10 helloimcx

我这边都是正常的,你看看你电脑是不是没有.NET运行时?从报错信息看是和pythonnet相关的问题,应该是.NET运行时之类的问题。

AndersonBY avatar Oct 11 '23 08:10 AndersonBY

安装了运行时还是一样 image

helloimcx avatar Oct 11 '23 09:10 helloimcx

你不打包直接 pdm run dev 是否能运行? 另外你看看是不是和这个 issue 有关:https://github.com/r0x0r/pywebview/issues/1215

AndersonBY avatar Oct 11 '23 09:10 AndersonBY