Gimp-Forum.net

Full Version: ofnuts' addon-on manager crashing in 2.10.2
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I added this to the top of the code:
Code:
import sys
sys.stderr = open("C:/tmp/gimp_python_errs.txt",'a')
sys.stdout=sys.stderr
print(authors)

I got this:
Code:
Sean Bogie, MareroQ, Ofnuts
Traceback (most recent call last):
 File "C:\Users\brmp68\Downloads\audit\python\addonCollectionManager-3.0.py", line 40, in <module>
   import pygtk,gtk,re,sys,os,glob,shutil,ConfigParser,codecs,copy,zipfile,time
 File "C:\Program Files\GIMP 2.10\32\lib\python2.7\site-packages\gtk-2.0/gtk/__init__.py", line 30, in <module>
   import gobject as _gobject
 File "C:\Program Files\GIMP 2.10\32\lib\python2.7\site-packages/gobject/__init__.py", line 47, in <module>
   from gobject.constants import *
 File "C:\Program Files\GIMP 2.10\32\lib\python2.7\site-packages/gobject/constants.py", line 24, in <module>
   import gobject._gobject
ImportError: DLL load failed: One or more arguments are invalid

Windows 7 64-bit, Freshly installed GIMP 2.10.2
And I can fix it by doing the gimpfu import BEFORE the gtk import:
Code:
from gimpfu import *
import pygtk,gtk,re,sys,os,glob,shutil,ConfigParser,codecs,copy,zipfile,time
pygtk.require('2.0')
(05-23-2018, 01:59 PM)Kevin Wrote: [ -> ]And I can fix it by doing the gimpfu import BEFORE the gtk import:
Code:
from gimpfu import *
import pygtk,gtk,re,sys,os,glob,shutil,ConfigParser,codecs,copy,zipfile,time
pygtk.require('2.0')

..but stops it working in linux, at least it does here. apologies to all, duplicate scripts clashing.
All I've done is to get it to register in the menus, I've not tried any of the functionality.
I did try the fix in a Win7 64 bit VM latest Gimp 2.10.2 (as earlier) and that works, Windows fonts a bit peculiar as usual, load but not too keen to unload.
Smells like a clash between two libraries/DLL. Can someone try in the Python console:

Code:
import platform
print platform.architecture()

In my 64bit VM, it seems that Gimp's Python is 32-bit.

Also how many *glib*.DLL have you got, and where are they?
Code:
GIMP 2.10.2 Python Console
Python 2.7.15 (default, May  4 2018, 07:50:01)  [GCC 7.3.0 32 bit]
➤> import platform
➤> print platform.architecture()
('32bit', 'WindowsPE')

In Program files/GIMP 2.10
Code:
$ find . -name *glib*.dll
./32/bin/libdbus-glib-1-2.dll
./32/bin/libglib-2.0-0.dll
./32/bin/libjson-glib-1.0-0.dll
./32/bin/libpoppler-glib-8.dll
./32/bin/libpyglib-2.0-python2-0.dll
./bin/libdbus-glib-1-2.dll
./bin/libglib-2.0-0.dll
./bin/libjson-glib-1.0-0.dll
./bin/libpoppler-glib-8.dll
./bin/libpyglib-2.0-python2-0.dll

And in AppData/Roaming/GIMP
Code:
./2.10/plug-ins/gmic-gimp-qt-build/libglib-2.0-0.dll
./2.10/plug-ins/gmic-qt-samj/libglib-2.0-0.dll
Reported the problem. Stay tuned for a new version that circumvents the Gimp problem (income tax weekend Sad ....)
Pages: 1 2