Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Mintupgrade performs un-backed-up permanent changes to apt configuration before user authorizes upgrade

Open
#60 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
25/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
python

Research direction

Start by tracing mintupgrade's phase 2, labelled "Simulation and Download", and inspect how it modifies /etc/apt/sources.d/official-package-repositories.list. The issue names no source file or test; done means every pre-authorization exit restores all touched apt configuration, with backups or restart recovery covering crashes.

Written by the indexing model from the issue text.

Description

The current iteration of mintupgrade performs silent, permanent changes to /etc/apt/sources.d/official-package-repositories.list before the user has actually authorized the upgrade. This is occurring during phase 2, which is labelled "Simulation and Download". When the user is presented with a proposed list of changes, if the user declines and exits the utility rather than continue with the upgrade, then apt is left with a (silently) changed configuration that tells it that the system is currently on Mint 21 (Vanessa). This has the effect of then causing some mischief with mintupdate, which will then itself try to update all the packages to Mint 21.

There are many reasons why the user may not want to proceed with an upgrade at some point before it is authorized. For example, in my case, I did not like that the upgrade was going to leave me with gcc 9, 10, 11, and 12 all installed at once. After I exited, I found apt had been silently changed and that no backup had been made to it.

At any time before the upgrade is actually authorized, exiting from mintupgrade should revert all changes to apt so that the system is not in an unstable hybrid state (Mint 20.3 packages with apt configured as if it is Mint 21).

In addition to an automatic reversion to original apt configuration on mintupgrade's normal termination at any point before the upgrade is commenced, it should also back up all apt configuration files which it touches. This in case an unforseen crash or system restart occurs before the upgrade proceeds. In fact, an entry in should be made in something like /etc/rc.local which will cause the apt configuration files to revert to normal at next system restart.

Dominant language
Python
Stars
50
Forks
20
PR merge metrics
No merged PRs in 30d

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from linuxmint/mintupgrade

All issues in linuxmint/mintupgrade

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.