/var/lib/python-support/python2.6/dbus/mainloop/qt.so missing after upgrade

Bug #348704 reported by Andreas Wenning on 2009-03-25
This bug affects 8 people
Affects Status Importance Assigned to Milestone
python-qt4 (Ubuntu)

Bug Description

Binary package hint: python-qt4

After upgrading from 4.4.4-2ubuntu1~intrepid1 (intrepid-backports) to 4.4.4-2ubuntu5 (jaunty) the symlink for qt.so is missing:

Doing a reinstall of the package fixes the problem.

Related branches

Scott Kitterman (kitterman) wrote :

Among other things this breaks update-notifier-kde.

Changed in python-qt4:
importance: Undecided → High
milestone: none → ubuntu-9.04
status: New → Confirmed
Stefan Usenbinz (usenbinz) wrote :

So I guess this is my "update-notifier-kde.py crashed with ImportError in <module>()" on Jaunty then...

Yes. That's exactly what happens.

The mystery is why it's missing on upgrade, but not for a new install.

Michael Vogt (mvo) wrote :

I just tried a test upgrade with a minimal environment. Here this seem to work, after the upgrade the mentioned file:
is there. This was from the normal intrepid version, not the backport one though. I'm trying this next.

Michael Vogt (mvo) wrote :

The file is also there for a full kubuntu (intrepid) -> kubuntu jaunty upgrade.

Michael Vogt (mvo) wrote :

Same result with the python-qt4-dbus from intrepid-backports (in a minimal environment) the file is there. Could you please give me instructions how to reproduce this problem? And/or attach the upgrade log in /var/log/dist-upgrade ?

Changed in python-qt4 (Ubuntu Jaunty):
status: Confirmed → Incomplete

I'll upload what looks relevant from the dist-upgrade log; tell me if you need more.

Scott Kitterman (kitterman) wrote :

For me it I got the problem using the KDE version of the upgrader (with
backports enabled), so I don't know what else to suggest.

Maybe at this point it's best to just special case this in the upgrade tool
to look for the python2.5/qt.so symlink and provide the python2.6/qt.so
symlink if it's missing.

Michael Vogt (mvo) wrote :

Thanks for the logs, nothing out of the ordinary there :/

I tried a full kubuntu intrepid->jaunty upgrade with backports enabled but still got the symlink for mainloop/qt.so

Jonathan Riddell (jr) wrote :

I've seen this several times upgrading with the KDE version of the DistUpgrade tool from a fresh intrepid install.

Stefan Usenbinz (usenbinz) wrote :

Since everyone here has the problem when upgrading from intrepid to jaunty maybe I should mention that my system was a fresh install auf jaunty alpha 4(?) being updated on a daily basis since then. At one time (although I unfortunately did not pay attention when) update-notifier-kde and kblueplugd stopped working. Just in case this makes any differences to an intrepd->jaunty upgrade.

I can confirm this bug after an Intrepid -> Jaunty update.
Reinstalling the package did not fix the problem (I only reinstaller python-qt4, is there another one to reinstall?). Manually creating the symbolic link apparently did the trick. Is that an acceptable workaround?

Michael Vogt (mvo) wrote :

I suspect this is because of bug #353251. python2.6-minimal is unpacked and setup in line 875pp of the upgrade log. At this time the python-minimal version that contains the file /usr/share/python/debian_defaults is still the intrepid version (that package gets upgraded in line 1164). The debian_defaults file does not contain python2.6 yet (because its still the intrepid version). The postinst of python2.6-minimal reads this file and only runs the "rtinstall" scripts if python2.6 is marked as supported in debian_defaults.

This would also explain why some people see the problem and some not. It depends on the unpack/configure ordinging. If python-qt4-dbus is unpacked/configured before python2.6-minmal is unpacked the link is not created because the global rtinstall for python2.6 of pysupport (and pycentral) is not run.

Changed in python-qt4 (Ubuntu Jaunty):
status: Incomplete → Confirmed
Michael Vogt (mvo) wrote :

My theory that this is a side-effect of #353251 is probably bogus. I still can not reproduce the problem, but it seems like:
$ dpkg -L python-qt4-dbus
claim the file (well, symlink) is there. But its not on the filesystem.

Michael Vogt (mvo) wrote :

I'm still struggling to reproduce the problem in a chroot. I tried various python*qt* and python*kde* package installed and upgraded them, but for me the symlink was there.

Michael Vogt (mvo) wrote :

I can reproduce it now and added debug code. It looks like the symlink is there initially when python-qt4-dbus gets installed in its new version. Then it gets removed around the time when python-imaging gets installed (libsane/python-imaging/hplib/hplip-data is the events of packages, at python-imgaging its missing). This package maybe a red-herring if the logging is screwed, but its definitely there initially.

Michael Vogt (mvo) wrote :
Michael Vogt (mvo) wrote :

I think its the hplip prerm script thats causing the problem. Its running "update-python-modules -c hplip". This blasts away the entire /var/lib/python-support directory. The reason is that python2.6 is not listed as supported in /usr/share/python/debian_defaults at this point.

Michael Vogt (mvo) wrote :

This explains why it was so difficult to reproduce, the unpack order is key, if debian_defaults is updated when the hplip.prerm is run there are no problems.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package python-qt4 - 4.4.4-2ubuntu6

python-qt4 (4.4.4-2ubuntu6) jaunty; urgency=low

  * debian/control:
    - add versionized dependency to python-minimal ensure that
      python-minimal gets upgraded and debian_defaults is up-to-date
      when /var/lib/python-support/python2.6 gets created
      (LP: #348704)

 -- Michael Vogt <email address hidden> Thu, 09 Apr 2009 01:14:10 +0200

Changed in python-qt4 (Ubuntu Jaunty):
status: Confirmed → Fix Released
Scott Kitterman (kitterman) wrote :

Wouldn't this best be fixed by putting the versioned depends on hplip so it
doesn't blow stuff away due to python 2.6 not being supported? Who knows
how many other packages this hit?

Michael Vogt (mvo) wrote :

@Scott: Yes, that is probably a good idea (needs to be tested, the whole unpack/configure cycle is crucial for the problem to appear or not.

I think it really only affects python-qt4 because it carries data in /var/lib/python-support/python-$ver. This dir is for all (most [1]) other packages automatically managed (created/removed) by python-support. But pyqt4 uses pycentral so some compatibility love is required. This all is still far from ideal, if I run:
# update-python-modules --force-rebuild-all
the symlink is gone afterwards. python-support takes this dir as its territory. Aolution is probably to write the right kind of file tto /usr/share/python-support/ to ensure it auto-creates the symlinks on rebuild, but I don't have enough inside in pysupport for a offhand solution. The real prolbem IMO is that a) python-central/python-support behave differently b) the python symlink famring that is not as robust as plain dpkg


[1] apt-file does not show other than python-qt4-dbus and -dbg

Scott Kitterman (kitterman) wrote :

Debian just switched python-qt4 fully to pysupport. You might want to look
and see if that's safer solution at this point.

Michael Vogt (mvo) wrote :

@Scott: sorry for my late reply, I was away over easter. Switching is the cleanest solution for the problem, I'm not sure about it at this point, but I have a look.

databubble (phil-linttell) wrote :

Just to add to the discussion, I did an upgrade from 9.04 to 9.10/karmic alpha 1 and encountered this same problem.

Re-installing with "sudo apt-get install --reinstall python-qt4-dbus" does not resolve it.

The sym-link does exist:

# ls -l /var/lib/python-support/python2.6/dbus/mainloop/qt.so
lrwxrwxrwx 1 root root 47 2009-06-03 15:41 /var/lib/python-support/python2.6/dbus/mainloop/qt.so -> /usr/lib/pyshared/python2.6/dbus/mainloop/qt.so

# ls -l /usr/lib/pyshared/python2.6/dbus/mainloop/qt.so
-rw-r--r-- 1 root root 19152 2009-05-21 19:47 /usr/lib/pyshared/python2.6/dbus/mainloop/qt.so

hasi (whynot-nurfuerspam) wrote :

I just did an upgrade in jaunty from KDE 4.2.2 to KDE 4.3b2. I have this problem, and reinstalling python-qt4-dbus does NOT fix it.

Scott Kitterman (kitterman) wrote :

Then you aren't having this problem. You are have a different one with a
similar symptom. Please file a new bug.

tags: added: iso-testing
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers