package libsane-common 1.0.25+git20150528-1ubuntu2 failed to install/upgrade: trying to overwrite '/etc/sane.d/hp.conf', which is also in package libsane:i386 1.0.23-3ubuntu3.1

Bug #1564778 reported by Satya on 2016-04-01
120
This bug affects 20 people
Affects Status Importance Assigned to Milestone
sane-backends (Ubuntu)
High
Unassigned
Xenial
Undecided
Unassigned
Yakkety
Undecided
Unassigned
Zesty
High
Unassigned

Bug Description

[ Impact ]

This is a packaging error when upgrading from trusty to xenial. You may see a file conflict error because a file moved from libsane to libsane-common. This is fairly common, as you can see from the dupes and affect-count.

As described in comment #4, only xenial really needs to be patched. But since it shares the same version of sane-backends as yakkety and zesty, it's nice to update both of those so that upgraders get a clean path.

[ Test Case ]

Install libsane and libsane-common on trusty. Upgrade to xenial.

[ Regression Potential ]

Tiny. This is just a Breaks/Conflict packaging error. No code changes.

Satya (satyasegren) wrote :
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in sane-backends (Ubuntu):
status: New → Confirmed
Changed in sane-backends (Ubuntu):
importance: Undecided → High
Rolf Leggewie (r0lf) wrote :

The problem stems from the fact that trusty libsane as well as xenial libsane-common both ship /etc/sane.d/hp.conf without declaring breaks/replaces/conflicts. Should be an easy fix.

Rolf Leggewie (r0lf) wrote :

The change really only needs to be done in xenial as all upgrades will have to pass through xenial. But since that mandates a version bump for all versions for aftre xenial as well we might as well ship the fix in those releases as well. The breaks/replaces can safely be dropped in yakkety and zesty on the next upload.

Changed in sane-backends (Ubuntu):
status: Confirmed → In Progress
Rolf Leggewie (r0lf) wrote :
Rolf Leggewie (r0lf) wrote :
Nish Aravamudan (nacc) wrote :

Hello and thank you for this update!

If I understand this correctly, the issue is when coming from Trusty, a file is now owned by two packages.

A user would obviously experience this on Xenial during upgrade when the new version of libsane-common gets installed.

But then they might also experience it on Y & Z if they choose to resolve the issue on X by removing libsane-common on X, and release-upgrade'ing instead, and then trying to install libsane-common again on the new release and it fails agin. Except that libsane depends on libsane-common, so I believe it would also be removed in that case. So, IIUC, this cannot actually happen on Y or Z. You only need to modify those versions so that they are after X for upgrade purposes from X?

Your fix is to ensure that (old) versions of libsane are removed so the file conflict doesn't occur, is that correct? (note that all of these questions will be necessary to satisfy https://wiki.ubuntu.com/StableReleaseUpdates.)

Finally, I believe your X and Y versioning is a bit off. I tend to use https://wiki.ubuntu.com/SecurityTeam/UpdatePreparation#Update_the_packaging as my standard, and that would result in:

Z: 1.0.25+git20150528-1ubuntu3
Y: 1.0.25+git20150528-1ubuntu2.16.10.1
X: 1.0.25+git20150528-1ubuntu2.16.04.1

While your version is not incorrect, it assumes that release naming will proceed forever alphabetically sorted forwards, which we (presumably) know is not going to happen post-Z, so it's a good habit to break.

I am going to ask the -devel list about this, as I'm not sure what the right way forward is (it feels weird to add to our delta just to allow for the fixlet).

Thanks!
-Nish

P.S. In case you're interested, it seems like sane-backends could do with a fresh merge to Debian unstable (last done in Wily!)

Michael Terry (mterry) wrote :

I've just uploaded all three (zesty, yakkety, and xenial) fixes. Better to just fix this now while the number of uploads is even smaller. :)

I agreed with Nish about the versions, so I fixed them.

description: updated
description: updated
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package sane-backends - 1.0.25+git20150528-1ubuntu3

---------------
sane-backends (1.0.25+git20150528-1ubuntu3) zesty; urgency=medium

  * control: add breaks/replaces between libsane and libsane-common to
    fix earlier packaging mistake. LP: #1564778
    The changes is safe to drop from z+1.

 -- Rolf Leggewie <email address hidden> Thu, 09 Feb 2017 17:29:27 +0800

Changed in sane-backends (Ubuntu Zesty):
status: In Progress → Fix Released

Hello Satya, or anyone else affected,

Accepted sane-backends into yakkety-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/sane-backends/1.0.25+git20150528-1ubuntu2.16.10.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed.Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in sane-backends (Ubuntu Yakkety):
status: New → Fix Committed
tags: added: verification-needed
Changed in sane-backends (Ubuntu Xenial):
status: New → Fix Committed
Brian Murray (brian-murray) wrote :

Hello Satya, or anyone else affected,

Accepted sane-backends into xenial-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/sane-backends/1.0.25+git20150528-1ubuntu2.16.04.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed.Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Nish Aravamudan (nacc) wrote :

I setup a Trusty LXD, installed libsane and libsane-common and then manually updated source.list with the xenial repositories, including xenial-proposed. I then did `sudo apt-get update; sudo apt-get dist-upgrade` and the upgrade completed successfully (no error) with the following versions of libsane and libsane-common.

$ apt policy libsane libsane-common
libsane:
  Installed: 1.0.25+git20150528-1ubuntu2.16.04.1
  Candidate: 1.0.25+git20150528-1ubuntu2.16.04.1
  Version table:
 *** 1.0.25+git20150528-1ubuntu2.16.04.1 500
        500 http://archive.ubuntu.com/ubuntu xenial-proposed/main amd64 Packages
        100 /var/lib/dpkg/status
     1.0.25+git20150528-1ubuntu2 500
        500 http://archive.ubuntu.com/ubuntu xenial/main amd64 Packages
libsane-common:
  Installed: 1.0.25+git20150528-1ubuntu2.16.04.1
  Candidate: 1.0.25+git20150528-1ubuntu2.16.04.1
  Version table:
 *** 1.0.25+git20150528-1ubuntu2.16.04.1 500
        500 http://archive.ubuntu.com/ubuntu xenial-proposed/main amd64 Packages
        100 /var/lib/dpkg/status
     1.0.25+git20150528-1ubuntu2 500
        500 http://archive.ubuntu.com/ubuntu xenial/main amd64 Packages

tags: added: verification-done-xenial
removed: verification-needed
tags: added: verification-needed-yakkety
Nish Aravamudan (nacc) wrote :

I followed the same path and dist-upgraded all the way to yakkety and saw no errors with the package in proposed. I'm not sure, though, if that really qualifies as a v-d-y, given that I didn't reproduce the original issue in that path.

# apt policy libsane libsane-common
libsane:
  Installed: 1.0.25+git20150528-1ubuntu2.16.10.1
  Candidate: 1.0.25+git20150528-1ubuntu2.16.10.1
  Version table:
 *** 1.0.25+git20150528-1ubuntu2.16.10.1 500
        500 http://archive.ubuntu.com/ubuntu yakkety-proposed/main amd64 Packages
        100 /var/lib/dpkg/status
     1.0.25+git20150528-1ubuntu2 500
        500 http://archive.ubuntu.com/ubuntu yakkety/main amd64 Packages
libsane-common:
  Installed: 1.0.25+git20150528-1ubuntu2.16.10.1
  Candidate: 1.0.25+git20150528-1ubuntu2.16.10.1
  Version table:
 *** 1.0.25+git20150528-1ubuntu2.16.10.1 500
        500 http://archive.ubuntu.com/ubuntu yakkety-proposed/main amd64 Packages
        100 /var/lib/dpkg/status
     1.0.25+git20150528-1ubuntu2 500
        500 http://archive.ubuntu.com/ubuntu yakkety/main amd64 Packages

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers