LSB got updated, forces downgrade of landscape-client

Bug #393454 reported by Andreas Hasenack
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Landscape Client
Fix Released
Critical
Free Ekanayaka

Bug Description

The lsb package got updated in hardy and this is forcing the downgrade of the landscape package to the stub version landscape-client-0.1, which would basically erase landscape-client and make the machine unmanageable:
root@ls5-hardy:~# smart upgrade --explain
Loading cache...
Updating cache... ########################################################################################## [100%]

Computing transaction...

Upgrading packages (2):
  lsb-base_4.0-0ubuntu0.8.04.1
    Upgrades:
      lsb-base_3.2-4ubuntu1 (upgraded)
  lsb-release_4.0-0ubuntu0.8.04.1
    Upgrades:
      lsb-release_3.2-4ubuntu1 (upgraded)

Downgrading packages (1):
  landscape-client_0.1
    Downgrades:
      landscape-client_1.3.2.1-0ubuntu0.8.04.0 (downgraded)

Removing packages (1):
  landscape-common_1.3.2.1-0ubuntu0.8.04.0
    Requires:
      lsb-base_3.2-4ubuntu1 (upgraded)
      lsb-release_3.2-4ubuntu1 (upgraded)
    Required By:
      landscape-client_1.3.2.1-0ubuntu0.8.04.0 (downgraded)

42.3kB of package files are needed. 1.2MB will be freed.

Confirm changes? (Y/n): n

See attached screenshot for landscape's behaviour.

Revision history for this message
Andreas Hasenack (ahasenack) wrote :
Changed in landscape-client:
importance: Undecided → Critical
milestone: none → 1.3.2.2
Changed in landscape-client:
assignee: nobody → Free Ekanayaka (free.ekanayaka)
Revision history for this message
Free Ekanayaka (free.ekanayaka) wrote :

I've relaxed the dependency and uploaded a new revision of the package to the Landscape PPA.

Changed in landscape-client:
status: New → In Progress
Revision history for this message
Andreas Hasenack (ahasenack) wrote :

Free, can you also attach a branch to this ticket? Thanks.

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

Oops, this is just a packaging fix, we don't need a new milestone/version for that.

Changed in landscape-client:
milestone: 1.3.2.2 → 1.3.2.1
Revision history for this message
Free Ekanayaka (free.ekanayaka) wrote :

We (Andreas, Chris, Gustavo and I) discussed the issue on IRC, and agreed to use autoppa again to solve the problem of supporting multiple distributions.

However I just realized that the debhelper scripts do actually have a way to conditionally include dependences at build time, which is substvars/dh_gencontrol. The attached branch makes use of it, and I believe it's a pattern we can use in general to address this kind of issues. I rebuilt the packages and uploaded them to my PPA, the dapper/hardy ones don't have the update-motd dependency, while the intrepid/jaunty/karmic ones do have it, as expected.

tags: added: review
Revision history for this message
Andreas Hasenack (ahasenack) wrote :

Can we use that trick for our other "|" depends? For example, the python and pysqlite2 ones:

--- debian/control 2009-06-22 19:21:37 +0000
+++ debian/control 2009-06-30 12:29:47 +0000
@@ -9,16 +9,16 @@
 Package: landscape-common
 Architecture: all
 Pre-Depends: python, python-gobject
-Depends: ${python:Depends}, ${misc:Depends},
+Depends: ${python:Depends}, ${misc:Depends}, ${extra:Depends},
          python-smartpm (>= 1.2-0ubuntu1),
          python-pysqlite2 | python2.4-pysqlite2,
- update-motd | lsb-base (<< 3.2-14ubuntu2),
          python-dbus | python2.4-dbus,
          python-twisted-core,
          ca-certificates,
          perl-modules,
          python-gdbm,
          lsb-release,
+ lsb-base,
          adduser
 Replaces: landscape-client (<= 1.0.23-0ubuntu0.8.10)
 Description: The Landscape administration system client

Revision history for this message
Free Ekanayaka (free.ekanayaka) wrote :

Yes, we can, however I would leave those as "|" because they are truly alternative packages providing the needed functionality. That is a pretty standard way to deal with library packages that are transitioning from one version to another (like Python 2.4 to >2.5). Do you see any scenario where it could be problematic?

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

I just thought that if we are using this to replace autoppa, we might go the whole way. About scenarios, no, I don't see any, but I also didn't see any with the lsb case.

Revision history for this message
Gustavo Niemeyer (niemeyer) wrote :

This is brilliant! +1, with one minor comment:

[1]

+ifneq (,$(findstring $(dist_release),"intrepid jaunty karmic"))

It'd be good to invert the test, so that it checks for the past release names rather than the future ones. The past names won't change, but future names are unknown, and will break the logic without notice.

Revision history for this message
Free Ekanayaka (free.ekanayaka) wrote :

Gustavo, thanks for reviewing! I've addressed [1] in r131.

Andreas, I rechecked the various "|" dependences and they still make sense to me, because the python2.4-pysqlite2, python2.4-pycurl and python2.4-dbus packages are available only on dapper and are unversioned, hence stable. The problem of this bug is the "update-motd | lsb-base <<" dependency, which was indeed hacky and unstable.

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

Cool, np.

Free, I see however that the landscape ppa has this package for hardy:
landscape-client (1.3.2.1-0ubuntu0.9.04.1) hardy; urgency=low

That's the wrong version number: it should be 8.04, not 9.04. I suppose this is unfixable now, since it is published?

Revision history for this message
Free Ekanayaka (free.ekanayaka) wrote :

Yeah, I did the build manually instead of with the script and got it wrong :/ Anyway the next version will be 1.3.2.1-0ubuntu1.X.Y.0 (note the 0ubuntu_1_), that's because this is an update of packages on all releases, and we bump the front digit. So the problem will go away as soon as this branch gets merged and the packages rebuilt.

Revision history for this message
Christopher Armstrong (radix) wrote :

This is a great change. Man, substvars!! Best idea ever.

+1.

tags: removed: review
Changed in landscape-client:
status: In Progress → Fix Committed
Changed in landscape-client:
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.