Bug 551958

Summary: KDE4 printer-applet can't run
Product: [openSUSE] openSUSE 11.2 Reporter: Jon Nelson <jnelson-suse>
Component: KDE4 ApplicationsAssignee: E-mail List <kde-maintainers>
Status: RESOLVED FIXED QA Contact: E-mail List <qa-bugs>
Severity: Critical    
Priority: P5 - None CC: admin, ctrippe, forgotten_q1-mW4hKuE, forgotten_QFh0D9oMPg, forgotten_WYqD73zI_T, joerg.steffens, johanh.botha, jsmeix, korossy, peter-mailbox
Version: Final   
Target Milestone: ---   
Hardware: x86-64   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Jon Nelson 2009-11-02 20:11:41 UTC
User-Agent:       Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv:1.9.0.14) Gecko/2009090900 SUSE/3.0.14-0.1.2 Firefox/3.0.14

I noticed RC1 and RC2 unable to open printer-applet or hp-systray.
Perhaps a dbus *and* package dependency issue?
GUI mode disabled in build?  Whaaa?



From ~/.xsession-errors:


ESC[31;01merror: Unable to locate models.dat fileESC[0m
ESC[35;01mwarning: GUI mode disabled in build.ESC[0m
ESC[31;01merror: hp-systray requires Qt4 GUI and DBus support. Exiting.ESC[0m

ESC[01mHP Linux Imaging and Printing System (ver. 0.0.0)ESC[0m
ESC[01mSystem Tray Status Service ver. 2.0ESC[0m

Copyright (c) 2001-9 Hewlett-Packard Development Company, LP
This software comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to distribute it
under certain conditions. See COPYING file for more details.

Traceback (most recent call last):
  File "/usr/bin/printer-applet", line 1161, in <module>
    applet = JobManager()
  File "/usr/bin/printer-applet", line 297, in __init__
    notification = NewPrinterNotification(bus, self)
  File "/usr/bin/printer-applet", line 1050, in __init__
    bus_name = dbus.service.BusName (PDS_OBJ, bus=bus)
  File "/usr/lib/python2.6/site-packages/dbus/service.py", line 129, in __new__
    retval = bus.request_name(name, name_flags)
  File "/usr/lib/python2.6/site-packages/dbus/bus.py", line 306, in request_name
    'su', (name, flags))
  File "/usr/lib/python2.6/site-packages/dbus/connection.py", line 622, in call_blocking
    message, timeout)
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.AccessDenied: Connection ":1.39" is not allowed to own the service "com.redhat.NewPrinterNotification" due to security policies in the configuration file


Reproducible: Always

Steps to Reproduce:
1.
2.
3.
Comment 1 Johannes Meixner 2009-11-03 09:34:44 UTC
The "GUI mode disabled in build" and
"hp-systray requires Qt4 GUI and DBus support"
messages indicates that the HPLIP software which you use
is not from us because for our hplip packages
GUI mode and dbus is enabled during build
according to our hplip.spec:
----------------------------------------------------------
./configure --prefix=/usr \
            ...
            --disable-qt3 \
            --enable-qt4 \
            ...
            --enable-gui-build \
            ...
            --enable-dbus-build \
----------------------------------------------------------

Therefore it should work when you
get rid of your currently installed HPLIP software
and use our HPLIP packages (hplip and hplip-hpijs) instead.
Comment 2 Jon Nelson 2009-11-03 13:04:23 UTC
Actually, the package *is* from opensuse, as confirmed by both zypper and rpm -qi.

The package 'hplip-cups' was installed ( from packman ) which I have since replaced with the appropriate hplip-hpijs from openSUSE.

However, that doesn't resolve the problem with printer-applet (but it does resolve the issue with hp-systray).


The problem with printer-applet still remains:


Something unexplained is why the *version* of hplip is not that for Factory RC2. The version is one of the updates from Factory:

frank:~ # zypper search -ds hplip
Loading repository data...
Reading installed packages...

S | Name                  | Type       | Version     | Arch   | Repository
--+-----------------------+------------+-------------+--------+------------------------
i | hplip                 | package    | 3.9.8-3.3.1 | x86_64 | Main Update Repository
v | hplip                 | package    | 3.9.8-3.3.1 | i586   | Main Update Repository
v | hplip                 | package    | 3.9.8-3.4.1 | x86_64 | Main Repository (OSS)
v | hplip                 | package    | 3.9.8-3.4.1 | x86_64 | Factory ISO
v | hplip                 | package    | 3.9.8-3.4.1 | i586   | Main Repository (OSS)
  | hplip                 | srcpackage | 3.9.8-3.3.1 | noarch | Main Update Repository
i | hplip                 | patch      | 1433        | noarch | Main Update Repository
  | hplip-debuginfo       | package    | 3.9.8-3.4.1 | x86_64 | Main Repository (DEBUG)
  | hplip-debuginfo       | package    | 3.9.8-3.4.1 | i586   | Main Repository (DEBUG)
  | hplip-debugsource     | package    | 3.9.8-3.4.1 | x86_64 | Main Repository (DEBUG)
  | hplip-debugsource     | package    | 3.9.8-3.4.1 | i586   | Main Repository (DEBUG)
i | hplip-hpijs           | package    | 3.9.8-3.3.1 | x86_64 | Main Update Repository
v | hplip-hpijs           | package    | 3.9.8-3.3.1 | i586   | Main Update Repository
v | hplip-hpijs           | package    | 3.9.8-3.4.1 | x86_64 | Main Repository (OSS)
v | hplip-hpijs           | package    | 3.9.8-3.4.1 | x86_64 | Factory ISO
v | hplip-hpijs           | package    | 3.9.8-3.4.1 | i586   | Main Repository (OSS)
  | hplip-hpijs-debuginfo | package    | 3.9.8-3.4.1 | x86_64 | Main Repository (DEBUG)
  | hplip-hpijs-debuginfo | package    | 3.9.8-3.4.1 | i586   | Main Repository (DEBUG)
frank:~ #


I suspect that this is an issue of having the update repo have a substantially higher priority than "Main Repository" or "Factory ISO". I will temporarily reset the priority of the update repo.  I used 'zypper dup' to go from 11.1 to 11.2 betas and betas to RC1 and RC2.

When I force the upgrade, I *still* don't get a working printer-applet.

hp-systray appears to behave fine, now.

The package containing printer-applet:

kde4-printer-applet-4.3.1-3.4.x86_64
Comment 3 Johannes Meixner 2009-11-03 13:28:40 UTC
FYI,
regarding mixing up our HPLIP packages and HPLIP from packman
and various possible bad consequences, see for example
bug 515005 and bug 551785.
Perhaps in particular
https://bugzilla.novell.com/show_bug.cgi?id=551785#c2
might be of interest here because you wrote that the
update repo has a higher priority than "Main Repository".


Regarding kde4-printer-applet-4.3.1-3.4.x86_64
I change the component of this bug to KDE4.
Comment 4 Jon Nelson 2009-11-19 14:25:15 UTC
Still an issue.  openSUSE 11.2 GM.



[jnelson@worklaptop:~] printer-applet
Traceback (most recent call last):
  File "/usr/bin/printer-applet", line 1161, in <module>
    applet = JobManager()
  File "/usr/bin/printer-applet", line 297, in __init__
    notification = NewPrinterNotification(bus, self)
  File "/usr/bin/printer-applet", line 1050, in __init__
    bus_name = dbus.service.BusName (PDS_OBJ, bus=bus)
  File "/usr/lib/python2.6/site-packages/dbus/service.py", line 129, in __new__
    retval = bus.request_name(name, name_flags)
  File "/usr/lib/python2.6/site-packages/dbus/bus.py", line 306, in request_name
    'su', (name, flags))
  File "/usr/lib/python2.6/site-packages/dbus/connection.py", line 622, in call_blocking
    message, timeout)
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.AccessDenied: Connection ":1.320" is not allowed to own the service "com.redhat.NewPrinterNotification" due to security policies in the configuration file
Comment 5 Christian Trippe 2009-12-02 09:04:15 UTC
*** Bug 558280 has been marked as a duplicate of this bug. ***
Comment 6 Forgotten User WYqD73zI_T 2009-12-08 20:45:03 UTC
I have the same pb with the same message in konsole.
This printer applet doesn't work :(
This applet is very important for me.

Thanks
Comment 7 Peter Küppers 2010-01-14 22:00:08 UTC
Hello,

the reason why printer-applet starts with the message
>>>
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.AccessDenied:
Connection ":1.320" is not allowed to own the service
"com.redhat.NewPrinterNotification" due to security policies in the
configuration file
<<<
is a missing /etc/dbus-1/system.d/newprinternotification.conf (see http://chakra-project.org/bbs/viewtopic.php?id=1059).
Download it from here: https://fedorahosted.org/system-config-printer/browser/newprinternotification.conf and put it to /etc/dbus-1/system.d/.

Then start with 'printer-applet --show' to see the applet immediately, otherwise it runs in the background as process 'python'.

But don't be too enthusiastic. Even then, printer-applet shows anything (bug!?) and aside from this, the intention of printer-applet is only monitoring printing under KDE4.
It's job is not administrating printers or printjobs like KJobViewer or KDEPrint under KDE3.
Such tools don't (yet) exist under KDE4 (see http://kde-look.org/content/show.php/Printers+and+Scanners+for+KDE4?content=48354&PHPSESSID=fb4f1ad4ea88c282885d78e4d5afeb48).

You've to use cups-webinterface (http://localhost:631/) or install package kdebase3 from KDE3 with KJobViewer and KDEPrint.
Both should work more or less under KDE4. For KDEPrint execute 'kcmshell printers' or /opt/kde3/share/applications/kde/printers.desktop, for KJobViewer 'kjobviewer' or /opt/kde3/share/applications/kde/kjobviewer.desktop.
The only thing which didn't work for me, is the administration of the printserver, but you can do it with cups-webinterface.

Cheers

Peter
Comment 8 Christian Trippe 2010-01-18 12:34:46 UTC
*** Bug 571576 has been marked as a duplicate of this bug. ***
Comment 9 Jon Nelson 2010-03-23 22:15:30 UTC
Bug 561193 is probably also a duplicate.
If this isn't going to get fixed, then maybe printer-applet should be removed?
Why isn't it working?

NOTE: still not working with opensuse 11.2 and KDE 4.4:

kde4-printer-applet-4.4.1-118.2.x86_64




This seems like just a dbus policy issue!
Comment 10 Lubos Lunak 2010-05-19 14:50:51 UTC
Added system-config-printer to requirements to avoid the crash.