On 2023-10-30 19:19, McDermott Family via Python-list wrote:
Hello, I am trying to create a one file executable with pyinstaller 6.1.0
and auto-py-to-exe 2.41.0 using Python version 3.10.9 in a virtual
environment.
Some points before the output of pinstaller is shown. My resource .py file
is there where it should be. Also I can fun my program from the command-line
and it does work with the compiled resource file without a problem. Any help
would be greatly appreciated. Thank you.
Running auto-py-to-exe v2.41.0
Building directory: C:\Users\icnte\AppData\Local\Temp\tmpp870eytg
Provided command: pyinstaller --noconfirm --onefile --windowed --icon
"D:/Work/Python/cfepy310/xl/cfegui/Resources/Conform-e_48_1.ico" --name
"Conform-e" --clean --log-level "DEBUG" --debug "all" --version-file
"D:/Work/Python/cfepy310/xl/cfegui/cfe_versionfile.txt" --resource
"D:/Work/Python/cfepy310/xl/cfegui/cfe_Resource_rc.py"
"D:/Work/Python/cfepy310/xl/cfegui/cfe_MainForm.py"
Recursion Limit is set to 5000
Executing: pyinstaller --noconfirm --onefile --windowed --icon
D:/Work/Python/cfepy310/xl/cfegui/Resources/Conform-e_48_1.ico --name
Conform-e --clean --log-level DEBUG --debug all --version-file
D:/Work/Python/cfepy310/xl/cfegui/cfe_versionfile.txt --resource
D:/Work/Python/cfepy310/xl/cfegui/cfe_Resource_rc.py
D:/Work/Python/cfepy310/xl/cfegui/cfe_MainForm.py --distpath
C:\Users\icnte\AppData\Local\Temp\tmpp870eytg\application --workpath
C:\Users\icnte\AppData\Local\Temp\tmpp870eytg\build --specpath
C:\Users\icnte\AppData\Local\Temp\tmpp870eytg
[snip]
ValueError: Invalid Windows resource specifier
'D:\\\\Work\\\\Python\\\\cfepy310\\\\xl\\\\cfegui\\\\cfe_Resource_rc.py'!
For arbitrary data file, the format is 'filename,type,name,[language]'!
Project output will not be moved to output folder
Complete.
In the docs for "--resource" it says:
"""FILE can be a data file or an exe/dll. For data files, at least TYPE
and NAME must be specified."""
That might be the problem, but I haven't been able to find out what
"TYPE" means!
I also wonder whether "--add-data" would work.
--
https://mail.python.org/mailman/listinfo/python-list