Re: matplotlib fails to import distutils on windows deploy

Mamoru Inugami <[email protected]>
Newsgroups gmane.comp.python.pyqt-pykde
Message-ID <CAN895WgSiKrV1fpPcB3YMY8jM_77u_q58uDE8+VLxejWpEe32w@mail.gmail.com>
Dear pyqt-list.

I fail to send message to Phil directly, Sorry...

I could find distutils at standard libraries.

Then, I also encountered this problem.
....
Freezing
C:\Users\dino\Desktop\pyqtdeploy-2.4\demo\sysroot-win-64\lib\python3.7\distutils\core.py...
Freezing
C:\Users\dino\Desktop\pyqtdeploy-2.4\demo\sysroot-win-64\lib\python3.7\distutils\cygwincompiler.py...
pyqtdeploy-build: Unable to freeze files

I added --verbose output.

pyqtdeploy-build: Unable to freeze files:
C:\Users\dino\Desktop\pyqtdeploy-2.4\demo\sysroot-win-64\lib\python3.7\distutils\cygwincompiler.py:
[Errno 2] No such file or directory:
'C:\\Users\\dino\\Desktop\\pyqtdeploy-2.4\\demo\\sysroot-win-64\\lib\\python3.7\\distutils\\cygwincompiler.py'

I could not find cygwincompiler.py but found cygwinccompiler.py.
I renamed cygwinccompiler.py to  cygwincompiler.py, then I encountered
another problem.

pyqtdeploy-build: Unable to freeze files:
C:\Users\dino\Desktop\pyqtdeploy-2.4\demo\sysroot-win-64\lib\python3.7\msilib.py:
[Errno 2] No such file or directory:
'C:\\Users\\dino\\Desktop\\pyqtdeploy-2.4\\demo\\sysroot-win-64\\lib\\python3.7\\msilib.py'

I could not find msilib,py at sysroot.(I could find test_msilib.py)

Michiaki ENDO
Sapporo, Japan

2020年1月29日(水) 8:50 Mamoru Inugami <[email protected]>:

> Dear Phil,
>
> I will add --verbose output.
>
> pyqtdeploy-build: Unable to freeze files:
> C:\Users\dino\Desktop\pyqtdeploy-2.4\demo\sysroot-win-64\lib\python3.7\distutils\cygwincompiler.py:
> [Errno 2] No such file or directory:
> 'C:\\Users\\dino\\Desktop\\pyqtdeploy-2.4\\demo\\sysroot-win-64\\lib\\python3.7\\distutils\\cygwincompiler.py'
>
> I could not find cygwincompiler.py but found cygwinccompiler.py.
> I renamed cygwinccompiler.py to  cygwincompiler.py, then I encountered
> another problem.
>
> pyqtdeploy-build: Unable to freeze files:
> C:\Users\dino\Desktop\pyqtdeploy-2.4\demo\sysroot-win-64\lib\python3.7\msilib.py:
> [Errno 2] No such file or directory:
> 'C:\\Users\\dino\\Desktop\\pyqtdeploy-2.4\\demo\\sysroot-win-64\\lib\\python3.7\\msilib.py'
>
> I could not find msilib,py at sysroot.(I could find test_msilib.py)
>
> Michiaki ENDO
> Sapporo, Japan
>
> 2020年1月29日(水) 8:38 Mamoru Inugami <[email protected]>:
>
>> Dear Phil,
>>
>> Thank yor for your comment.
>> I could find distutils at standard libraries.
>>
>> Then, I also encountered this problem.
>> ....
>> Freezing
>> C:\Users\dino\Desktop\pyqtdeploy-2.4\demo\sysroot-win-64\lib\python3.7\distutils\core.py...
>> Freezing
>> C:\Users\dino\Desktop\pyqtdeploy-2.4\demo\sysroot-win-64\lib\python3.7\distutils\cygwincompiler.py...
>> pyqtdeploy-build: Unable to freeze files
>>
>> Could you tell me how to solve this problem?
>>
>> Michiaki ENDO
>> Sapporo, Japan
>>
>>
>>
>> 2020年1月28日(火) 18:48 Phil Thompson <[email protected]>:
>>
>>> On 28/01/2020 01:02, Mamoru Inugami wrote:
>>> > Dear pyqt-list,
>>> >
>>> > I try to compile my Python script using matplotlib via pyqtdeploy on
>>> > Windows10.
>>> > The build was successful but the output exe does not boot.
>>> >
>>> > Treceback was here:
>>> > temp5.py is my Python script, trying to import below at line 6.
>>> >
>>> > from matplotlib.backends.backend_qt5agg import FigureCanvasQTAgg as
>>> > FigureCanvas
>>> >
>>> > Traceback (most recent call last):
>>> >   File "temp5.py", line 6, in <module>
>>> >   File "bootstrap.py", line 983, in _find_and_load
>>> >   File "bootstrap.py", line 953, in _find_and_load_unlocked
>>> >   File "bootstrap.py", line 219, in _call_with_frames_removed
>>> >   File "bootstrap.py", line 983, in _find_and_load
>>> >   File "bootstrap.py", line 953, in _find_and_load_unlocked
>>> >   File "bootstrap.py", line 219, in _call_with_frames_removed
>>> >   File "bootstrap.py", line 983, in _find_and_load
>>> >   File "bootstrap.py", line 967, in _find_and_load_unlocked
>>> >   File "bootstrap.py", line 668, in _load_unlocked
>>> >   File "bootstrap.py", line 638, in _load_backward_compatible
>>> >   File ":/matplotlib/__init__.py", line 121, in <module>
>>> >   File "bootstrap.py", line 983, in _find_and_load
>>> >   File "bootstrap.py", line 953, in _find_and_load_unlocked
>>> >   File "bootstrap.py", line 219, in _call_with_frames_removed
>>> >   File "bootstrap.py", line 983, in _find_and_load
>>> >   File "bootstrap.py", line 965, in _find_and_load_unlocked
>>> > ModuleNotFoundError: No module named 'distutils'
>>> >
>>> > I have included all site-package libs to build my executable and
>>> > my script runs without error on Python interpreter.
>>> >
>>> > Could you tell me how to fix this problem ?
>>>
>>> Add distutils (and any other matplotlib dependency) to your pyqtdeploy
>>> project.
>>>
>>> Phil
>>>
>>

_______________________________________________
PyQt mailing list    [email protected]
https://www.riverbankcomputing.com/mailman/listinfo/pyqt
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.