Hi,
I found a problem of comtypes 1.1.4.
I installed comtypes to use pywinauto(maybe 6.3) and I used comtype(maybe 1.1.2) very well until a few days ago.
but, I think.. I probably upgraded pywinauto and comtype to latest version yesterday.
Today, I used 'pyinstaller' to make an execute file and ran the execute file. but I got the following error:
so, I downgraded comtype from 1.1.4 to 1.1.1 and than I got the results I want.
please I'll wait for your solution :)
Thank you.
(MainProcess_180123.py line 5 is "import WebPRocess"
WebProcess line 10 is "import pywinauto.keyboard as pk")
C:\Users\hgha\PycharmProjects\closing\RPA automation\R5\bak\dist>kk.exe "C:\Users\hgha\PycharmProjects\closing\RPA automation_180205.01\R5\R5_Xx.xlsm"
Traceback (most recent call last):
File "MainProcess_180123.py", line 5, in
File "", line 968, in _find_and_load
File "", line 957, in _find_and_load_unlocked
File "", line 673, in _load_unlocked
File "c:\users\hgha\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 631, in exec_module
exec(bytecode, module.dict)
File "WebProcess.py", line 10, in
File "", line 968, in _find_and_load
File "", line 957, in _find_and_load_unlocked
File "", line 673, in load_unlocked
File "c:\users\hgha\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 631, in exec_module
exec(bytecode, module.dict)
File "site-packages\pywinauto_init.py", line 40, in
File "", line 968, in _find_and_load
File "", line 957, in _find_and_load_unlocked
File "", line 673, in _load_unlocked
File "c:\users\hgha\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 631, in exec_module
exec(bytecode, module.dict)
File "site-packages\pywinauto\findwindows.py", line 42, in
File "", line 968, in _find_and_load
File "", line 957, in _find_and_load_unlocked
File "", line 673, in load_unlocked
File "c:\users\hgha\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 631, in exec_module
exec(bytecode, module.dict)
File "site-packages\pywinauto\controls_init.py", line 36, in
File "", line 968, in _find_and_load
File "", line 957, in _find_and_load_unlocked
File "", line 673, in _load_unlocked
File "c:\users\hgha\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 631, in exec_module
exec(bytecode, module.dict)
File "site-packages\pywinauto\controls\uiawrapper.py", line 44, in
File "", line 968, in _find_and_load
File "", line 957, in _find_and_load_unlocked
File "", line 673, in _load_unlocked
File "c:\users\hgha\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 631, in exec_module
exec(bytecode, module.dict)
File "site-packages\pywinauto\uia_defines.py", line 175, in
File "site-packages\pywinauto\uia_defines.py", line 163, in _build_pattern_ids_dic
File "site-packages\pywinauto\uia_defines.py", line 50, in call
File "site-packages\pywinauto\uia_defines.py", line 60, in init
File "site-packages\comtypes\client_generate.py", line 110, in GetModule
File "site-packages\comtypes\client_generate.py", line 169, in _CreateWrapper
FileNotFoundError: [Errno 2] No such file or directory: 'C:\Users\hgha\AppData\Local\Temp\_MEI226842\comtypes\gen\_944DE083_8FB8_45CF_BCB7_C477ACB2F897_0_1_0.py'
[11188] Failed to execute script MainProcess_180123
Hi,
I found a problem of comtypes 1.1.4.
I installed comtypes to use pywinauto(maybe 6.3) and I used comtype(maybe 1.1.2) very well until a few days ago.
but, I think.. I probably upgraded pywinauto and comtype to latest version yesterday.
Today, I used 'pyinstaller' to make an execute file and ran the execute file. but I got the following error:
so, I downgraded comtype from 1.1.4 to 1.1.1 and than I got the results I want.
please I'll wait for your solution :)
Thank you.
(MainProcess_180123.py line 5 is "import WebPRocess"
WebProcess line 10 is "import pywinauto.keyboard as pk")
C:\Users\hgha\PycharmProjects\closing\RPA automation\R5\bak\dist>kk.exe "C:\Users\hgha\PycharmProjects\closing\RPA automation_180205.01\R5\R5_Xx.xlsm"
Traceback (most recent call last):
File "MainProcess_180123.py", line 5, in
File "", line 968, in _find_and_load
File "", line 957, in _find_and_load_unlocked
File "", line 673, in _load_unlocked
File "c:\users\hgha\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 631, in exec_module
exec(bytecode, module.dict)
File "WebProcess.py", line 10, in
File "", line 968, in _find_and_load
File "", line 957, in _find_and_load_unlocked
File "", line 673, in load_unlocked
File "c:\users\hgha\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 631, in exec_module
exec(bytecode, module.dict)
File "site-packages\pywinauto_init.py", line 40, in
File "", line 968, in _find_and_load
File "", line 957, in _find_and_load_unlocked
File "", line 673, in _load_unlocked
File "c:\users\hgha\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 631, in exec_module
exec(bytecode, module.dict)
File "site-packages\pywinauto\findwindows.py", line 42, in
File "", line 968, in _find_and_load
File "", line 957, in _find_and_load_unlocked
File "", line 673, in load_unlocked
File "c:\users\hgha\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 631, in exec_module
exec(bytecode, module.dict)
File "site-packages\pywinauto\controls_init.py", line 36, in
File "", line 968, in _find_and_load
File "", line 957, in _find_and_load_unlocked
File "", line 673, in _load_unlocked
File "c:\users\hgha\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 631, in exec_module
exec(bytecode, module.dict)
File "site-packages\pywinauto\controls\uiawrapper.py", line 44, in
File "", line 968, in _find_and_load
File "", line 957, in _find_and_load_unlocked
File "", line 673, in _load_unlocked
File "c:\users\hgha\appdata\local\programs\python\python35\lib\site-packages\PyInstaller\loader\pyimod03_importers.py", line 631, in exec_module
exec(bytecode, module.dict)
File "site-packages\pywinauto\uia_defines.py", line 175, in
File "site-packages\pywinauto\uia_defines.py", line 163, in _build_pattern_ids_dic
File "site-packages\pywinauto\uia_defines.py", line 50, in call
File "site-packages\pywinauto\uia_defines.py", line 60, in init
File "site-packages\comtypes\client_generate.py", line 110, in GetModule
File "site-packages\comtypes\client_generate.py", line 169, in _CreateWrapper
FileNotFoundError: [Errno 2] No such file or directory: 'C:\Users\hgha\AppData\Local\Temp\_MEI226842\comtypes\gen\_944DE083_8FB8_45CF_BCB7_C477ACB2F897_0_1_0.py'
[11188] Failed to execute script MainProcess_180123