Skip to content

Instantly share code, notes, and snippets.

@skarllot
Created February 19, 2026 18:20
Show Gist options
  • Select an option

  • Save skarllot/1b41bfc036ba80fa1d55b149a9554b93 to your computer and use it in GitHub Desktop.

Select an option

Save skarllot/1b41bfc036ba80fa1d55b149a9554b93 to your computer and use it in GitHub Desktop.
Pop!_OS 22.04 → 24.04 Upgrade Troubleshooting

Pop!_OS 22.04 → 24.04 Upgrade Troubleshooting

Summary

This documents two issues encountered when upgrading Pop!_OS from 22.04 (Jammy) to 24.04 (Noble) using pop-upgrade, and how they were resolved.


Issue 1: Upgrade aborted due to VS Code repository checksum mismatch

Symptom

Running the upgrade command failed with:

❯ pop-upgrade release upgrade -f
...
Release upgrade status: release upgrade aborted: failed to fetch apt URIs to fetch

Diagnosis

Checking the pop-upgrade journal logs revealed the actual cause:

journalctl -u pop-upgrade -b | grep -i "fail\|error\|uri"
[ERROR] release/mod.rs:855: failed to fetch packages: failed to fetch apt URIs to fetch:
failed to fetch package URIs from apt-get full-upgrade: checksum not found in output:
'https://packages.microsoft.com/repos/code/pool/main/c/code/code_1.109.4-1771257466_amd64.deb'

The Microsoft VS Code repository was producing a checksum mismatch, causing the entire upgrade process to abort.

Fix

Temporarily disable the VS Code repository before upgrading:

sudo mv /etc/apt/sources.list.d/vscode.sources /etc/apt/sources.list.d/vscode.sources.bak
sudo apt clean
sudo apt update
pop-upgrade release upgrade -f

The upgrade completed successfully after disabling it.

Note: Other third-party repos that explicitly reference the jammy codename (e.g. Spotify, PPAs with jammy in their filename) may cause similar issues and should also be disabled before upgrading.


Issue 2: VS Code repository GPG key missing after upgrade

Symptom

After restoring the VS Code repository and running sudo apt update:

Err:1 https://packages.microsoft.com/repos/code stable InRelease
  The following signatures couldn't be verified because the public key is not available:
  NO_PUBKEY EB3E94ADBE1229CF

W: GPG error: https://packages.microsoft.com/repos/code stable InRelease: ...
E: The repository 'https://packages.microsoft.com/repos/code stable InRelease' is not signed.

Diagnosis

Inspecting the repository source file:

cat /etc/apt/sources.list.d/vscode.sources
Types: deb
URIs: https://packages.microsoft.com/repos/code
Suites: stable
Components: main
Architectures: amd64
Signed-By: /usr/share/keyrings/microsoft.gpg

The file expected the Microsoft GPG key at /usr/share/keyrings/microsoft.gpg, but that file had been lost during the upgrade.

Fix

Re-download the Microsoft GPG key and place it where the source file expects it:

wget -qO- https://packages.microsoft.com/keys/microsoft.asc \
  | gpg --dearmor \
  | sudo tee /usr/share/keyrings/microsoft.gpg > /dev/null

sudo apt update
sudo apt upgrade

VS Code was updated successfully.


Quick Reference (TL;DR)

# Before upgrading: disable VS Code repo
sudo mv /etc/apt/sources.list.d/vscode.sources /etc/apt/sources.list.d/vscode.sources.bak

# Run the upgrade
sudo apt clean && sudo apt update
pop-upgrade release upgrade -f

# After upgrading: restore VS Code repo and re-import the GPG key
sudo mv /etc/apt/sources.list.d/vscode.sources.bak /etc/apt/sources.list.d/vscode.sources
wget -qO- https://packages.microsoft.com/keys/microsoft.asc \
  | gpg --dearmor \
  | sudo tee /usr/share/keyrings/microsoft.gpg > /dev/null

sudo apt update && sudo apt upgrade
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment