[SRU] apt snapshot integration backport

Bug #2038453 reported by Julian Andres Klode
20
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Ubuntu Pro
Status tracked in 18.04
18.04
Triaged
Undecided
Unassigned
apt (Ubuntu)
Status tracked in Mantic
Bionic
Won't Fix
Undecided
Unassigned
Focal
Fix Committed
Undecided
Unassigned
Jammy
Fix Committed
Undecided
Unassigned
Lunar
Won't Fix
Undecided
Unassigned
Mantic
Fix Released
Undecided
Unassigned

Bug Description

[Impact]
The snapshot service provides users access to older states of the archive with ease of use, and enables a consistent user experience across all supported releases, as otherwise users would have to rewrite their sources.list to make use of snapshots and set up pinning; hence partners requested the feature be SRUed to older releases as well.

[Test plan]
The complete regression test suite in autopkgtests includes an automatic test case for this and the known limitations that have been fixed. Aside from that, it is also worthwhile to do an end-to-end test:

Configure snapshot=yes for Ubuntu sources in your sources.list and

1. run apt update - it should not use snapshot
2. run apt update --snapshot 20231001T000000Z, it should download the snapshot
3. run apt policy --snapshot 20231001T000000Z hello, it should show hello in the snapshot
4. run apt install --snapshot 20231001T000000Z hello, it should install hello from the snapshot
5. Run apt update; observe snapshot not being downloaded
6. Observe snapshots are gone from /var/lib/apt/lists again

[Where problems could occur]
The integration has been purposefully limited in how it works to reduce the impact it has on the APT code; hence it was possible to cherry-pick this into 22.04, 20.04, and even 18.04, with only a minor editorial change. This significantly limits the risk.

This feature is only enabled for sources with snapshot=yes (.list) or Snapshot: yes (.sources) or other truthy values apt recognizes. Most users will not have such entries as they did not have an APT supporting it.

This combined should ensure that users do not experience any regressions. However the feature may be lacking in some ways that we may want to address in follow up SRUs; it has not been used in the wild a lot.

Changed in apt (Ubuntu Mantic):
status: New → Fix Released
Changed in apt (Ubuntu Lunar):
status: New → Won't Fix
description: updated
description: updated
Changed in apt (Ubuntu Bionic):
status: New → Won't Fix
Revision history for this message
Launchpad Janitor (janitor) wrote :

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

Changed in apt (Ubuntu Focal):
status: New → Confirmed
Changed in apt (Ubuntu Jammy):
status: New → Confirmed
description: updated
description: updated
Changed in apt (Ubuntu Jammy):
status: Confirmed → In Progress
Changed in apt (Ubuntu Focal):
status: Confirmed → In Progress
Revision history for this message
Julian Andres Klode (juliank) wrote :

jammy and focal packages uploaded to the archive for SRU

jammy, focal, and bionic also uploaded to

https://launchpad.net/~deity/+archive/ubuntu/apt/+packages

Revision history for this message
Steve Langasek (vorlon) wrote : Please test proposed package

Hello Julian, or anyone else affected,

Accepted apt into jammy-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/apt/2.4.11 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, what testing has been performed on the package and change the tag from verification-needed-jammy to verification-done-jammy. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-jammy. In either case, without details of your testing we will not be able to proceed.

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

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in apt (Ubuntu Jammy):
status: In Progress → Fix Committed
tags: added: verification-needed verification-needed-jammy
Changed in apt (Ubuntu Focal):
status: In Progress → Fix Committed
tags: added: verification-needed-focal
Revision history for this message
Steve Langasek (vorlon) wrote :

Hello Julian, or anyone else affected,

Accepted apt into focal-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/apt/2.0.10 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, what testing has been performed on the package and change the tag from verification-needed-focal to verification-done-focal. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-focal. In either case, without details of your testing we will not be able to proceed.

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

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Revision history for this message
Ubuntu SRU Bot (ubuntu-sru-bot) wrote : Autopkgtest regression report (apt/2.4.11)

All autopkgtests for the newly accepted apt (2.4.11) for jammy have finished running.
The following regressions have been reported in tests triggered by the package:

apt/2.4.11 (armhf)
sbuild/0.81.2ubuntu6 (arm64, ppc64el, s390x)

Please visit the excuses page listed below and investigate the failures, proceeding afterwards as per the StableReleaseUpdates policy regarding autopkgtest regressions [1].

https://people.canonical.com/~ubuntu-archive/proposed-migration/jammy/update_excuses.html#apt

[1] https://wiki.ubuntu.com/StableReleaseUpdates#Autopkgtest_Regressions

Thank you!

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

Duplicates of this bug

Other bug subscribers

Remote bug watches

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