ntchat icon indicating copy to clipboard operation
ntchat copied to clipboard

用pyinstaller无法打包案例send_text_ui.py,请问要怎么打包带资源的xcgui+ntchat项目呢

Open zqc1984 opened this issue 2 years ago • 0 comments

打包用的 pyinstaller -F --collect-data=ntchat .\send_text_ui.py

4830 INFO: Looking for dynamic libraries Traceback (most recent call last): File "d:\python\python37\lib\site-packages\PyInstaller\isolated_parent.py", line 337, in call return isolated.call(function, *args, **kwargs) File "d:\python\python37\lib\site-packages\PyInstaller\isolated_parent.py", line 266, in call ok, output = loads(b64decode(self._read_handle.readline())) EOFError: EOF read where object expected

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "d:\python\python37\lib\runpy.py", line 193, in run_module_as_main "main", mod_spec) File "d:\python\python37\lib\runpy.py", line 85, in run_code exec(code, run_globals) File "D:\Python\Python37\Scripts\pyinstaller.exe_main.py", line 9, in File "d:\python\python37\lib\site-packages\PyInstaller_main.py", line 179, in run run_build(pyi_config, spec_file, **vars(args)) File "d:\python\python37\lib\site-packages\PyInstaller_main_.py", line 60, in run_build PyInstaller.building.build_main.main(pyi_config, spec_file, **kwargs) File "d:\python\python37\lib\site-packages\PyInstaller\building\build_main.py", line 963, in main build(specfile, distpath, workpath, clean_build) File "d:\python\python37\lib\site-packages\PyInstaller\building\build_main.py", line 885, in build exec(code, spec_namespace) File "D:\code\examples\send_text_ui.spec", line 24, in noarchive=False, File "d:\python\python37\lib\site-packages\PyInstaller\building\build_main.py", line 410, in init self.postinit() File "d:\python\python37\lib\site-packages\PyInstaller\building\datastruct.py", line 173, in postinit self.assemble() File "d:\python\python37\lib\site-packages\PyInstaller\building\build_main.py", line 689, in assemble isolated.call(find_binary_dependencies, list(self.binaries), self.binding_redirects, collected_packages) File "d:\python\python37\lib\site-packages\PyInstaller\isolated_parent.py", line 337, in call return isolated.call(function, *args, **kwargs) File "d:\python\python37\lib\site-packages\PyInstaller\isolated_parent.py", line 232, in exit self._write_handle.flush() OSError: [Errno 22] Invalid argument

python用的3.7.4 使用资源文件描述xcgui布局+ntchat的时候才会有这个问题,是我遗漏了什么吗?

zqc1984 avatar Oct 18 '22 18:10 zqc1984