(02-29-2024, 12:07 PM)Ofnuts Wrote: Yes, in the Gimp standard error stream. But on Windows it is typically hidden (but I think you can get at it if you start Gimp with gimp-console.exe).
Otherwise:
See examples in most of my scripts....
- You can catch the worst blunders (unbalanced parentheses, indentation...) by trying to run the code in a command prompt (it should fail, but not elicit syntax errors)
- You bracket the code in a try/except block, and display the Python error in a Gimp message.
How to run code in command prompt?
I found the gimp-console.exe but it doesn't show gimp, only a bunch of errors. Should it show GIMP and the console at the same time, right? Here is does not show gimp
What to do to remove the errors?
Code:
GEGL-Message: 19:30:45.047: Module 'F:\Programma\GIMP 2\lib\gegl-0.4\exr-save.dll' load error: 'F:\Programma\GIMP 2\lib\gegl-0.4\exr-save.dll': Kan opgegeven module niet vinden.
GEGL-Message: 19:30:45.047: Module 'F:\Programma\GIMP 2\lib\gegl-0.4\exr-load.dll' load error: 'F:\Programma\GIMP 2\lib\gegl-0.4\exr-load.dll': Kan opgegeven module niet vinden.
Skipping duplicate plug-in: 'F:\Programma\GIMP 2\lib\gimp\2.0\plug-ins\ofn-export-layers\ofn-export-layers.html'
Skipping duplicate plug-in: 'F:\Programma\GIMP 2\lib\gimp\2.0\plug-ins\ofn-guillotine-layer\ofn-guillotine-layer.html'
GIMP-Fout: Unable to run plug-in "ofn-tiles.html"
(C:\Users\gebruiker\AppData\Roaming\GIMP\2.10\plug-ins\ofn-tiles.html)
Uitvoeren van dochterproces is mislukt (Exec format error)
GIMP-Fout: Unable to run plug-in "ofn-preset-guides.log"
(C:\Users\gebruiker\AppData\Roaming\GIMP\2.10\plug-ins\ofn-preset-guides.log)
Uitvoeren van dochterproces is mislukt (Exec format error)
GIMP-Fout: Unable to run plug-in "ofn-preset-guides.ini"
(C:\Users\gebruiker\AppData\Roaming\GIMP\2.10\plug-ins\ofn-preset-guides.ini)
Uitvoeren van dochterproces is mislukt (Exec format error)
GIMP-Fout: Unable to run plug-in "ofn-preset-guides.html"
(C:\Users\gebruiker\AppData\Roaming\GIMP\2.10\plug-ins\ofn-preset-guides.html)
Uitvoeren van dochterproces is mislukt (Exec format error)
GIMP-Fout: Unable to run plug-in "ofn-guillotine-layer.html"
(C:\Users\gebruiker\AppData\Roaming\GIMP\2.10\plug-ins\ofn-guillotine-layer.html)
Uitvoeren van dochterproces is mislukt (Exec format error)
GIMP-Fout: Unable to run plug-in "ofn-export-layers.html"
(C:\Users\gebruiker\AppData\Roaming\GIMP\2.10\plug-ins\ofn-export-layers.html)
Uitvoeren van dochterproces is mislukt (Exec format error)
GIMP-Fout: Unable to run plug-in "Menu.png"
(C:\Users\gebruiker\AppData\Roaming\GIMP\2.10\plug-ins\Menu.png)
Uitvoeren van dochterproces is mislukt (Exec format error)
GIMP-Fout: Unable to run plug-in "LayersAndGroups.png"
(C:\Users\gebruiker\AppData\Roaming\GIMP\2.10\plug-ins\LayersAndGroups.png)
Uitvoeren van dochterproces is mislukt (Exec format error)
GIMP-Fout: Unable to run plug-in "HierarchicalExport.png"
(C:\Users\gebruiker\AppData\Roaming\GIMP\2.10\plug-ins\HierarchicalExport.png)
Uitvoeren van dochterproces is mislukt (Exec format error)
GIMP-Fout: Unable to run plug-in "FlatExport.png"
(C:\Users\gebruiker\AppData\Roaming\GIMP\2.10\plug-ins\FlatExport.png)
Uitvoeren van dochterproces is mislukt (Exec format error)
"Kan opgegeven module niet vinden." = "Cannot find specified module."
"Uitvoeren van dochterproces is mislukt" = "Execution of daughter process failed"