Hello !
I have juste installed your last pygi and I have a problem when running a python program (traduction from french to english in the text) :
Traceback (most recent call last):
File "C:\Users\YA\Desktop\2_Traitement\Traitement.py", line 284, in on_drawingarea_draw
document = Poppler.Document.new_from_file (path2url('Sources/PdfVuParCandidat/' + str(numerodossier) + '.pdf'), None)
GLib.Error: g-invoke-error-quark: Could not locate poppler_document_new_from_file: 'libpoppler-53.dll': Le module spécifié est introuvable. (1) [Specified module not found]
** (python.exe:1068): WARNING **: Failed to load shared library 'libpoppler-glib-8.dll' referenced by the typelib: 'libpoppler-glib-8.dll': Le module spcifi est introuvable. [Specified module not found]
** (python.exe:1068): WARNING **: Failed to load shared library 'libpoppler-53.dll' referenced by the typelib: 'libpoppler-53.dll': Le module spcifi est introuvable. [Specified module not found]
Is it a problem with pygi or do I need to install another thing (what ?) to make poppler working ?
I have installed poppler from pygi of course...
Thanks !
Alfazaz
Thanks, this an issue with rev21, at the moment please also select pango when selecting poppler in the package list. I will fix he issue in rev22
Correction, It's not dependency issue. I can confirm with my simple test that it works out of box. Could you give me your test case snippet?
I tried with pango selected and I have still the problem. I'm under pyzo 32 bit distribution on windows 7. My program is big... I write a minimal test case and I post it here when it is ready.
My minimal example works so I made a mistake in my big code (the surprise is that the big code works on linux but not on windows...).
You can close this thread. It seems to be no mistake from pygi here. Sorry !
Such issue sometime happen when other third party libraries involved and somehow the dll didn't called in correct manner midway. Please re-open this if it's incompatibility with third party libraries.
All right...
If I call a Poppler command at the beginning of the code, after importing the module, everything else works... Your remark seems to be exact but it will be very tricky to solve :-(.
I let this closed.
Thanks for all.
If you have time, you can look at this minimal example (files joined, put them into same directory) :
???? Do you know where to post this bug if here is a wrong place ? Thanks !
Last edit: alfazaz 2015-08-29
Oulalala... What about this (on Pyzo32bit/windows ; no problem on linux) :
import numpy as np
from gi.repository import Gtk
it gives these errors :
Traceback (most recent call last):
File "E:\tmp\Essai.py", line 2, in <module>
from gi.repository import Gtk
File "C:\pyzo2015a\lib\site-packages\gi__init__.py", line 42, in <module>
from . import _gi
ImportError: DLL load failed: Le module spécifié est introuvable. [Specified module not found]</module></module>
from gi.repository import Gtk
import numpy as np
it gives no error... Exactly same thing with Poppler of course.
What's the Hell ? Is it related with my precedent post ? [I don't no if I need to reopen the ticket and where it is possible to do it on this site...].
Another try in python3.4/spyder/windows/32bit... With only this line :
from gi.repository import Gtk
Traceback (most recent call last):
File "<ipython-input-1-cb5362bb191d>", line 1, in <module>
runfile('E:/tmp/Essai.py', wdir='E:/tmp')</module></ipython-input-1-cb5362bb191d>
File "C:\Python34\lib\site-packages\spyderlib\widgets\externalshell\sitecustomize.py", line 585, in runfile
execfile(filename, namespace)
File "C:\Python34\lib\site-packages\spyderlib\widgets\externalshell\sitecustomize.py", line 48, in execfile
exec(compile(open(filename, 'rb').read(), filename, 'exec'), namespace)
File "E:/tmp/Essai.py", line 2, in <module>
from gi.repository import Gtk</module>
File "C:\Python34\lib\site-packages\gi__init__.py", line 42, in <module>
from . import _gi</module>
ImportError: DLL load failed: Le module spécifié est introuvable.
????? (I must make such a big mistake that I can't see it ???). :-(
One good news (!!!) : everything works in Idle...
So, the mystery is the following : why is there problems with IEP(pyzo), spyder and commandline (python Essai.py) ?
:-|
Last edit: alfazaz 2015-08-29
Well, despite that you try to simplify the test code. The environment you chose (pyzo/spyder) is a huge bundle already, I bet there are already dozens of module (dll) imports just for startup... But I'm aware about that (scientific python) issue, and as you said it's to complicated to pinpoint considering dozens of dll are on pygi side too. It shound be okay with numpy I have been use pygi+numpy for mypaint all the time.
Is there a link of smaller download (<100mb) of windows installer?
Here is a really simple test case :
Create a file Essai.py with these two lines :
import numpy as np
from gi.repository import Gtk
Execute it in DOS command prompt with :
python Essai.py
For me, this leads to :
C:\Users\YA\Desktop\tmp>python Essai.py
Traceback (most recent call last):
File "Essai.py", line 2, in <module>
from gi.repository import Gtk
File "C:\Python34\lib\site-packages\gi__init__.py", line 42, in
from . import _gi
ImportError: DLL load failed: Le module spécifié est introuvable.</module>
And for you ? (There is no spyder, pyzo and co here)
My case?
http://opensourcepack.blogspot.com/2013/01/mypaint-and-pygi.html
Your case works but why my little example with only two lines doesn't work (my precedent message) ? What is your python installation ?
I just try reproduce your example with
It does works for me
All right... So I'm going to make a clean install like yours (with python 32bit on windows 7 64bit for me) and re-test...
When we have packages incompatibility, we should try it bit by bit. The issue certainly exist but we need to filter it by starting it clean first.
Sure ! So I desinstall all python and restart from scratch (it's not as easy as on linux :-( ).
So here are all of my steps :
1/ Removed all python and reboot.
2/ Got python-3.4.3 32 bits msi installer from official site and installed.
3/ Got numpy-1.9.2-win32-superpack-python3.4.exe from official site and installed.
4/ Got pygi-aio-3.14.0_rev21-setup.exe and installed with Gtk+ and Poppler ticked.
5/ Opened DOS Command Prompt and go to directory where is Essai.py which is the file with only these two lines :
import numpy as np
from gi.repository import Gtk
6/ Typed at the prompt : python Essai.py and.... again :-(
Traceback (most recent call last):
File "Essai.py", line 2, in <module>
from gi.repository import Gtk
File "C:\Python34\lib\site-packages\gi__init__.py", line 42, in <module>
from . import _gi
ImportError: DLL load failed: Le module spécifié est introuvable.</module></module>
I'm in a fog here...
Alfazaz from the french night...
PS : if you remove "import numpy as np", no error and, if you permute the two lines ("import numpy as np" after "from gi.repository import GtK") no error too... 8-|
Last edit: alfazaz 2015-08-29
How about try it with depends (dependency walker), is there any suspicious thing?
What's this ? Can you give me help lines to try this ? (I'm usually a linux user and not a windows user...).
Sorry...
download www.dependencywalker.com/
how to profile http://www.dependencywalker.com/help/html/application_profiling.htm
Euh... I installed it but I have to load what module ?
I have the precedent script Essai.py but it's not an executable...
open python.exe
press F7
pass full path of Essay.py as arguments
Last edit: tumagonx 2015-08-29