Re: [PyInstaller] pyenchant is listed is not packed and does not work

111 views
Skip to first unread message

Martin Zibricky

unread,
Oct 26, 2012, 10:38:07 AM10/26/12
to pyins...@googlegroups.com
Pavel Nikitenko píše v Pá 26. 10. 2012 v 06:56 -0700:
> Windows 7 64 bit, Python 2.7
>
> PyEnchant is listed under supported package for pyinstaller:
> http://www.pyinstaller.org/wiki/SupportedPackages

is your python 64bit? Official windows installer of pyenchant is
available only for 32bit python.

What is your pyinstaller version?

Pavel Nikitenko

unread,
Oct 26, 2012, 10:39:29 AM10/26/12
to pyins...@googlegroups.com, Martin Zibricky
Python is 32 bit version. And PyInstaller version is 2.0.

Pavel Nikitenko

unread,
Oct 26, 2012, 10:58:25 AM10/26/12
to Martin Zibricky, pyins...@googlegroups.com
Following was displayed when I did
python runtests.py -v libraries/test_enchant.py

Microsoft Windows [Version 6.1.7601]

Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

C:\win_prgs\pyinstaller-2.0\buildtests>c:\win_prgs\Python27\python.exe runtests.
py -v libraries/test_enchant.py
Running test:  libraries/test_enchant
test_enchant (__main__.GenericTestCase) ...
########## BUILDING TEST libraries/test_enchant ##########

273 INFO: wrote C:\win_prgs\pyinstaller-2.0\buildtests\libraries\test_enchant.sp
ec
330 INFO: Testing for ability to set icons, version resources...
368 INFO: ... resource update available
371 INFO: UPX is not available.
1898 INFO: checking Analysis
1898 INFO: building Analysis because out00-Analysis.toc non existent
1898 INFO: running Analysis out00-Analysis.toc
1898 INFO: Adding Microsoft.VC90.CRT to dependent assemblies of final executable

2224 INFO: Searching for assembly x86_Microsoft.VC90.CRT_1fc8b3b9a1e18e3b_9.0.21
022.8_none ...
2225 INFO: Found manifest C:\Windows\WinSxS\Manifests\x86_microsoft.vc90.crt_1fc
8b3b9a1e18e3b_9.0.21022.8_none_bcb86ed6ac711f91.manifest
2227 INFO: Searching for file msvcr90.dll
2227 INFO: Found file C:\Windows\WinSxS\x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_
9.0.21022.8_none_bcb86ed6ac711f91\msvcr90.dll
2227 INFO: Searching for file msvcp90.dll
2227 INFO: Found file C:\Windows\WinSxS\x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_
9.0.21022.8_none_bcb86ed6ac711f91\msvcp90.dll
2228 INFO: Searching for file msvcm90.dll
2228 INFO: Found file C:\Windows\WinSxS\x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_
9.0.21022.8_none_bcb86ed6ac711f91\msvcm90.dll
2432 INFO: Analyzing C:\win_prgs\pyinstaller-2.0\support\_pyi_bootstrap.py
3820 INFO: Analyzing C:\win_prgs\pyinstaller-2.0\PyInstaller\loader\archive.py
3931 INFO: Analyzing C:\win_prgs\pyinstaller-2.0\PyInstaller\loader\carchive.py
4062 INFO: Analyzing C:\win_prgs\pyinstaller-2.0\PyInstaller\loader\iu.py
4098 INFO: Analyzing test_enchant.py
6701 INFO: Hidden import 'encodings' has been found otherwise
6701 INFO: Looking for run-time hooks
6702 INFO: Analyzing rthook C:\win_prgs\pyinstaller-2.0\support/rthooks/pyi_rth_
encodings.py
6868 INFO: Adding Microsoft.Windows.Common-Controls to dependent assemblies of f
inal executable
13378 INFO: Warnings written to C:\win_prgs\pyinstaller-2.0\buildtests\libraries
\build\pyi.win32\test_enchant\warntest_enchant.txt
13391 INFO: checking PYZ
13394 INFO: rebuilding out00-PYZ.toc because out00-PYZ.pyz is missing
13394 INFO: building PYZ out00-PYZ.toc
15394 INFO: checking PKG
15394 INFO: rebuilding out00-PKG.toc because out00-PKG.pkg is missing
15395 INFO: building PKG out00-PKG.pkg
15408 INFO: checking EXE
15409 INFO: rebuilding out00-EXE.toc because test_enchant.exe missing
15409 INFO: building EXE from out00-EXE.toc
15425 INFO: Appending archive to EXE C:\win_prgs\pyinstaller-2.0\buildtests\libr
aries\build\pyi.win32\test_enchant\test_enchant.exe
15429 INFO: checking COLLECT
15429 INFO: building COLLECT out00-COLLECT.toc

########## EXECUTING TEST libraries/test_enchant ##########

RUNNING: dist\test_enchant\test_enchant.exe

########## STDOUT libraries/test_enchant ##########

--------------------------------------------------------------------------------

PYTHONPATH: ['C:\\win_prgs\\pyinstaller-2.0\\buildtests\\libraries\\dist\\test_e
nchant', 'C:\\win_prgs\\pyinstaller-2.0\\buildtests\\libraries\\dist\\test_encha
nt\\test_enchant.exe?196096']
--------------------------------------------------------------------------------

Backends: ispell, myspell
Languages: de_DE, en_AU, en_GB, en_US, fr_FR
Dictionaries: ['de_DE', 'en_AU', 'en_GB', 'en_US', 'fr_FR']
--------------------------------------------------------------------------------

d.check("hallo") True
d.check("halllo") False
d.suggest("halllo") ['hallo', 'hall lo']
_MEIPASS2 is NULL
archivename is C:\win_prgs\pyinstaller-2.0\buildtests\libraries\dist\test_enchan
t\test_enchant.exe
No need to extract files to run; setting extractionpath to homepath
Already in the child - running!
manifestpath: C:\win_prgs\pyinstaller-2.0\buildtests\libraries\dist\test_enchant
\test_enchant.exe.manifest
Activation context created
Activation context activated
C:\win_prgs\pyinstaller-2.0\buildtests\libraries\dist\test_enchant\python27.dll
Manipulating evironment
PYTHONPATH=C:/win_prgs/pyinstaller-2.0/buildtests/libraries/dist/test_enchant
PYTHONHOME=C:/win_prgs/pyinstaller-2.0/buildtests/libraries/dist/test_enchant/
importing modules from CArchive
extracted iu
extracted struct
extracted archive
Installing import hooks
out00-PYZ.pyz
Running scripts
OK.
Deactivating activation context
Releasing activation context
Done


########## STDERR libraries/test_enchant ##########


ok

----------------------------------------------------------------------
Ran 1 test in 19.788s

OK

C:\win_prgs\pyinstaller-2.0\buildtests>




It generated EXE file C:\win_prgs\pyinstaller-2.0\buildtests\libraries\build\pyi.win32\test_enchant\test_enchant.exe
So I tried to run the test_enchant.exe then. It displayed following.



Microsoft Windows [Version 6.1.7601]

Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

C:\win_prgs\pyinstaller-2.0\buildtests\libraries\dist\test_enchant>test_enchant.
exe
_MEIPASS2 is NULL
archivename is C:\win_prgs\pyinstaller-2.0\buildtests\libraries\dist\test_enchan
t\test_enchant.exe
No need to extract files to run; setting extractionpath to homepath
Already in the child - running!
manifestpath: C:\win_prgs\pyinstaller-2.0\buildtests\libraries\dist\test_enchant
\test_enchant.exe.manifest
Activation context created
Activation context activated
C:\win_prgs\pyinstaller-2.0\buildtests\libraries\dist\test_enchant\python27.dll
Manipulating evironment
PYTHONPATH=C:/win_prgs/pyinstaller-2.0/buildtests/libraries/dist/test_enchant
PYTHONHOME=C:/win_prgs/pyinstaller-2.0/buildtests/libraries/dist/test_enchant/
importing modules from CArchive
extracted iu
extracted struct
extracted archive
Installing import hooks
out00-PYZ.pyz
Running scripts
--------------------------------------------------------------------------------

PYTHONPATH: ['C:\\win_prgs\\pyinstaller-2.0\\buildtests\\libraries\\dist\\test_e
nchant', 'C:\\win_prgs\\pyinstaller-2.0\\buildtests\\libraries\\dist\\test_encha
nt\\test_enchant.exe?196096']
--------------------------------------------------------------------------------

Backends: ispell, myspell
Languages: de_DE, en_AU, en_GB, en_US, fr_FR
Dictionaries: ['de_DE', 'en_AU', 'en_GB', 'en_US', 'fr_FR']
--------------------------------------------------------------------------------

d.check("hallo") True
d.check("halllo") False
d.suggest("halllo") ['hallo', 'hall lo']
OK.
Deactivating activation context
Releasing activation context
Done

C:\win_prgs\pyinstaller-2.0\buildtests\libraries\dist\test_enchant>













On 26.10.2012 16:47, Martin Zibricky wrote:
Pavel Nikitenko píše v Pá 26. 10. 2012 v 16:39 +0200:
Python is 32 bit version. And PyInstaller version is 2.0.
Does the enchant test work for you?

cd ./buildtests
python runtests.py -v libraries/test_enchant.py


Pavel Nikitenko

unread,
Oct 26, 2012, 11:06:49 AM10/26/12
to Martin Zibricky, pyins...@googlegroups.com
But it does not work with my project. I need to manually copy all DLL
files of PyEnchant also with PyEnchant share and lib directories and
copy it into executable folder.



On 26.10.2012 17:02, Martin Zibricky wrote:
> Pavel Nikitenko píše v Pá 26. 10. 2012 v 16:58 +0200:
>> PYTHONPATH: ['C:\\win_prgs\\pyinstaller-2.0\\buildtests\\libraries\
>> \dist\\test_e
>> nchant', 'C:\\win_prgs\\pyinstaller-2.0\\buildtests\\libraries\\dist\
>> \test_encha
>> nt\\test_enchant.exe?196096']
>> --------------------------------------------------------------------------------
>>
>> Backends: ispell, myspell
>> Languages: de_DE, en_AU, en_GB, en_US, fr_FR
>> Dictionaries: ['de_DE', 'en_AU', 'en_GB', 'en_US', 'fr_FR']
>> ----------------------------------------------------------------
> Pyenchant works with pyinstaller.
>

Pavel Nikitenko

unread,
Oct 26, 2012, 6:01:08 PM10/26/12
to Martin Zibricky, pyins...@googlegroups.com
Looks like adding

a.zipfiles,
a.datas,
strip=None,

to spec file helped to automatically collect what is needed. So it is
resolved.

PS: I have some issue running the PyInstaller app from other PyInstaller
app as subprocess, it worked perfectly previously when PyEnchant was not
used yet.
Now the app does not start as subprocess from one app. But it is able to
start if I run it directly. It is strange behavior.

For now thank you very much for help.

Regards,
Pavel

On 26.10.2012 19:33, Martin Zibricky wrote:
> Pavel Nikitenko píše v Pá 26. 10. 2012 v 17:06 +0200:
>> But it does not work with my project. I need to manually copy all DLL
>> files of PyEnchant also with PyEnchant share and lib directories and
>> copy it into executable folder.
> What is different in your project that it does not work?
>

Pavel Nikitenko

unread,
Nov 20, 2012, 6:34:36 AM11/20/12
to Martin Zibricky, pyins...@googlegroups.com
Different is that I have two EXE files generated via PyInstaller from
python source codes.
If I run first exe, then the app starts ok even with PyEnchant support.
The second exe starts first exe with subprocess.Popen(args, cwd =
os.getcwd()) command.
But if second exe is used to start the app, the app does not start.

Only difference in current version and previous version of the
application is added PyEnchant support.

On 26.10.2012 19:33, Martin Zibricky wrote:
> Pavel Nikitenko píše v Pá 26. 10. 2012 v 17:06 +0200:
>> But it does not work with my project. I need to manually copy all DLL
>> files of PyEnchant also with PyEnchant share and lib directories and
>> copy it into executable folder.

Pavel Nikitenko

unread,
Nov 21, 2012, 3:11:31 PM11/21/12
to Martin Zibricky, pyins...@googlegroups.com
Looks like simply using recent PyInstaller development version solved my
issue. Thanks for help.
Reply all
Reply to author
Forward
0 new messages