Comment 8 for bug 399522

Revision history for this message
marathon (junk4me46806) wrote :

Here is a patch that seems to fix this bug. It works on my machine.

The issue, as I understand it is:
   A) Python scripts pass -i to other python scripts when running in interactive mode.
   B) When built without the gt4 gui_build option, -i is not a valid option.

The previous patch from comment #4 attempted to fix issue part A. This patch was rejected because it affected the behavior when built with gui_build (hp-setup -i will still launch the gui because hp-plugin is called with no arguments and its default is to launch the gui.).

The patch from comment #6 did not affect code execution, but instead printed a message to the user to install python dbus and python gobject. The patch operated under the assumption that installing these packages would fix the issue. I have both of these packages installed (gentoo packages dev-python/dbus-python-0.83.0-r1 and dev-python/pygobject-2.20.0) and am still seeing this bug. Comment #7 reiterates this point.

The attached patch address issue part B, which I believe is the correct place to fix this bug. The attached patch always allows the -i option as long as interactive mode is available. Without this patch, if interactive mode was the only version, -i would receive an error even though the program could run in interactive mode just fine (in fact that is what the user desires). This patch has the advantage of not changing the current behavior of the code. When built with gui_build, this patch will have no effect since -i was already accepted in that case. When built without gui_build, this patch will fix this bug and allow proper execution.