[Edgy] HPLIP Toolbox doesn't start from gnome menu

Bug #54667 reported by Pascal De Vuyst
4
Affects Status Importance Assigned to Milestone
hplip (Ubuntu)
Fix Released
Undecided
Matthias Klose

Bug Description

Binary package hint: hplip

In Edgy HPLIP Toolbox doesn't work when started from the gnome menu.
Running hp-toolbox from a terminal gives the following information:
Traceback (most recent call last):
  File "/usr/bin/hp-toolbox", line 39, in ?
    import base.async_qt as async
  File "/usr/lib/hplip/base/async_qt.py", line 81, in ?
    from qt import *
ImportError: No module named qt

This problem can be solved by installing the python-qt3 package.

What happened to the usefull dialog box, that tells us to install python-qt3, we have in Dapper?

hplip (0.9.7-4ubuntu1) dapper; urgency=low

  * Try to open a message dialog for the "No Qt" message. Malone: #26413.

 -- Matthias Klose <email address hidden> Tue, 11 Apr 2006 10:27:47 +0000

Changed in hplip:
assignee: nobody → doko
Changed in hplip:
status: Unconfirmed → Confirmed
Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

There should be a dependency on "python-qt3" in the "hplip" package.

Revision history for this message
Matthias Klose (doko) wrote : Re: [Bug 54667] Re: [Edgy] HPLIP Toolbox doesn't start from gnome menu

Till Kamppeter wrote:
> There should be a dependency on "python-qt3" in the "hplip" package.

no. we do not want python-qt3 on the CD.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

I think this is not a good idea. There should not be any programs on the CD and even in the desktop menues which require a package which is not on the CD.

I think one should split the hplip package into hplip and hplip-gui. hplip-gui contains all graphical user interfaces, like hp-toolbox, hp-sendfax, ... with their desktop menu entries, and it should have a dependency on python-qt3, as all of HP's GUIs are based on this widget toolkit.

The hplip package will contain the core part (daemons, documentation, ...) and the command line tools (like hp-setup, ...).

If on the CD is not enough space to include python-qt3, only hplip will be put onto the CDs and hplip-gui will be available only from the mirrors. And if a use installs hplip-gui from the mirrors, python-qt3 will automatically be installed and as soon as the user sees menu entries for HP's GUI tools the tools are working.

Revision history for this message
dwelch91 (dwelch91) wrote :

> I think one should split the hplip package into hplip and hplip-gui. hplip-gui
> contains all graphical user interfaces, like hp-toolbox, hp-sendfax, ... with
> their desktop menu entries, and it should have a dependency on
> python-qt3, as all of HP's GUIs are based on this widget toolkit.

>The hplip package will contain the core part (daemons, documentation, ...)
> and the command line tools (like hp-setup, ...).

This is not easily done. Most of the GUI tools (hp-unload, hp-sendfax and soon hp-setup) have both a GUI and text mode UI in a single command/file. For example, hp-sendfax -u will run the sendfax GUI, while hp-sendfax -n will run a non-interactive session for sending faxes. If you remove the hp-sendfax program from the main hplip package and not install the hplip-gui package, you will loose any ability to send faxes, even from a pure console/text-only environment.

Question: Is PyGTK installed by default or on the CD?

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

Then I would suggest the following:

Don, you tell us exactly, which programs are GUI-only and which are also usable on the text console.

The GUI-only programs and ALL desktop menu entries (also the ones of combined test/GUI tools, as a call from the menu makes only sense for the GUI mode) we move to hplip-gui, all the rest stays in hplip.

Then there is no not-working menu entry any more when having only booted/installed the CD without any extra packages, but there is still the possibility to do from the command line what is possible on the command line.

Installing hplip-gui will then automatically also install python-qt3 and all GUI tools (and GUI parts of combined text/GUI tools) are accessible via menu entries and work.

Revision history for this message
dwelch91 (dwelch91) wrote :

I think this is correct approach, except for one thing:

> Installing hplip-gui will then automatically also install python-qt3 and all GUI
> tools (and GUI parts of combined text/GUI tools) are accessible via menu
> entries and work.

The GUI and text/non-GUI "parts" of the combined tools are not "separatable" at this time. They are two modes within a single file/command. I never envisioned installing a command with one mode but not another.

Somebody suggested having the default mode for all the programs in the /etc/hp/hplip.conf file - this would be a help here. For the base hplip package, the mode could be set to "text", and if the hplip-gui package is subsequently installed, the mode could be overwritten to "gui". This would control which parameters are default (-u, or -i/-n) modes for all the programs. I think this is a workable idea.

> tell us exactly, which programs are GUI-only and which are also usable on
> the text console.

Right now, this is _only_ the toolbox ("Device Manager"). That would include the "toolbox.py", "ui/devmgr4.py", "ui/devmgr4_base.py" files, and a variety of dialog files (*.py, *_base.py, and *.ui files) in the "ui" directory that are used by the toolbox (the list can be easily determined by looking at the imports at the top of "ui/devmgr4.py").

All other programs have a -n (text/non-interactive) or -i (text/interactive) mode in addition to a -u (gui) mode.

Revision history for this message
Till Kamppeter (till-kamppeter) wrote :

So then only the hp-toolbox and the mentioned GUI-only .py files should go to hplip-gui.

For the menu entries one should make them run the programs in interactive text mode in a terminal window when there is no hplip-gui/python-qt3 and in GUI mode if hplip-gui/python-qt3 is installed. This should be feasible by wrapper scripts.

If the splitting of the Python files is too complicated, One could perhaps only move the menu entries out to hplip-gui, or let wrapper scripts around each tool make the program work in interactive text mode when there is no python-qt3 installed and otherwise as GUI.

Revision history for this message
dwelch91 (dwelch91) wrote :

That sounds fine. Just please let me know if any changes to the HPLIP software is required to make any of this work. Any changes would probably have to wait for our 1.6.10 or 1.6.11 release (Oct-Nov timeframe), however.

Revision history for this message
Matthias Klose (doko) wrote :

dwelch91, attaching the patch that Ubuntu currently applies

Changed in hplip:
status: Confirmed → Fix Committed
Revision history for this message
dwelch91 (dwelch91) wrote :

Thanks, I'll review these enhancements for inclusion in 1.6.11.

-Don

On 10/20/06, Matthias Klose <email address hidden> wrote:
>
> dwelch91, attaching the patch that Ubuntu currently applies
>
>
> ** Changed in: hplip (Ubuntu)
> Status: Confirmed => Fix Committed
>
> ** Attachment added: "no_qt_message patch"
> http://librarian.launchpad.net/4916014/61_noqt_message.dpatch
>
> --
> [Edgy] HPLIP Toolbox doesn't start from gnome menu
> https://launchpad.net/bugs/54667
>

Revision history for this message
Matthias Klose (doko) wrote :

fixed in edgy

Changed in hplip:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.