GNOME Bugzilla – Bug 677470
PyGTK command prompt script missing quotation marks
Last modified: 2018-08-17 13:38:23 UTC
The script installed in "C:\Python27\Lib\site-packages\gtk-2.0\runtime\bin\setenv.cmd" on my system didn't work properly because of omitted quotation marks in the environment variable setups. I've attached my repaired version.
Hi Dave, it looks like the attachment didn't come through. Also, does your fixed version look like this: https://github.com/dieterv/pygtk-installer/blob/master/wix/overlays/runtime/bin/setenv.cmd ?
Created attachment 215688 [details] Fixed .cmd file
IIUC on Windows the open quote has to appear to the left of the variable name.
First, thank you for creating invaluable open-source! I am in awe of the work accomplished by the PyGTK team, especially for Win32. Regarding bug 677470, I agree 100% with Dave Abrahams, and the current `setenv.cmd` has caused me some confusing issues, namely dbus-glib had some inconsistent function. I could make most of the code, but I could not run dbus-binding-tool unless I added the path to the GTK runtime bin **without** the quotes. With the quotes I would always get "Compilation failed: Failed to execute child process (No such file or directory)." There should either (a) *not* be any quotes in the MS-Windows PATH environmental variable [1] or (b) there should be quotes surrounding the entire expression following the SET commnand as David Abrahams has commented in comment 3 [2]. Unfortunately, this is not very well documented by MS. I urge you to accept his patch. The quotation marks in the current `setenv.cmd` causes inconsistent results. For example, I can not execute python at the "PyGTK command prompt" C:\Documents and Settings\mmikofski>python 'python' is not recognized as an internal or external command, operable program or batch file. But some files run, either way; for example, I have Geany installed minus the bundled GTK lib, because I already have it, and when I include `setenv.cmd` in the command to the Geany.exe, it runs fine. This inconsistent function, makes debugging confusing. Anyway, I have changed my local version, and I have no issues up to now. Thanks again! [1] http://ss64.com/nt/path.html [2] http://ss64.com/nt/set.html
pygtk is not under active development anymore and had its last code changes in 2013. Its codebase has been archived: https://gitlab.gnome.org/Archive/pygtk/commits/master PyGObject at https://gitlab.gnome.org/GNOME/pygobject is its successor. See https://pygobject.readthedocs.io/en/latest/guide/porting.html for porting info. Closing this report as WONTFIX as part of Bugzilla Housekeeping to reflect reality. Feel free to open a task in GNOME Gitlab if the issue described in this task still applies to a recent version of PyGObject. Thanks!