为什么我会收到此回溯错误?
这是我收到的错误:
Traceback (most recent call last):
File "dwload.py", line 9, in <module>
File "Pmw\__init__.pyc", line 28, in <module>
WindowsError: [Error 3] The system cannot find the path specified: "C:\\Users\\P
'sao\\Desktop\\dist\\library.zip\\Pmw/*.*"
使用 py2exe 将 python 文件编译为可执行文件后收到错误。
有谁知道为什么我会收到此错误?
找到解决方案: http://billyjin.kodingen.com/punbb -1.3.4/viewtopic.php?id=310
This is the error i get:
Traceback (most recent call last):
File "dwload.py", line 9, in <module>
File "Pmw\__init__.pyc", line 28, in <module>
WindowsError: [Error 3] The system cannot find the path specified: "C:\\Users\\P
'sao\\Desktop\\dist\\library.zip\\Pmw/*.*"
I get the error after compiling the python file into the executable with py2exe.
Does anybody know why i get this error?
Found the solution: http://billyjin.kodingen.com/punbb-1.3.4/viewtopic.php?id=310
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
好吧,错误消息表明找不到路径,如果您查看该路径,您似乎混淆了反斜杠和斜杠作为路径分隔符。您如何构建您正在使用的路径?
Well, the error message says that the path was not found, and if you look at the path, you appear to have mixed up backslashes and slashes as path separators. How are you constructing the path you're using?
使用 pyinstaller 和 tkinter 表(py 2.7)时我遇到了同样的问题。通过删除 tkintertable lib 元数据中的 Pwm 依赖关系解决了该问题。如果程序中不使用 pwm,它会对您有所帮助
I had the same problem when using pyinstaller and tkinter table (py 2.7). The problem was solved by removing the Pwm dependency in the tkintertable lib metadata. Its will help you, if pwm dont used in program
最后,我找到了解决方案:
首先,您需要按照以下命令运行 C:\Python27\Lib\site-packages\Pmw\build\lib\Pmw\Pmw_1_3\bin 文件夹中的bundlepmw.py: python bundlepmw.py C:\Python27\Lib\site-packages\Pmw\Pmw_1_3\lib 创建 Pmw.py。
根据此链接 sourceforge.net/p/pmw/discussion/33675/thread/f0bd7f34 修复bundlepmw.py 后,请阅读此页面:folk.uio.no/hpl/scripting/doc/python/Pmw/dynamicloader.html。
您应该能够生成 Pmw.py 文件。
然后将 Pmw.py 加 PmwBlt.py 和 PmwColor.py 复制到主脚本目录中并运行 setup.py。甜的
Finally, I found the solution:
First, you need to run the bundlepmw.py in the C:\Python27\Lib\site-packages\Pmw\build\lib\Pmw\Pmw_1_3\bin folder following this command: python bundlepmw.py C:\Python27\Lib\site-packages\Pmw\Pmw_1_3\lib to create the Pmw.py.
Read this page: folk.uio.no/hpl/scripting/doc/python/Pmw/dynamicloader.html, after fixing the bundlepmw.py based on this link sourceforge.net/p/pmw/discussion/33675/thread/f0bd7f34.
You should be able to generate the Pmw.py file.
Then copy the Pmw.py plus PmwBlt.py and PmwColor.py into the main script directory and run your setup.py. Sweet