safe-rm breaks upgrades from 18.04 to 20.04

Bug #1893724 reported by François Marier on 2020-09-01
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ubuntu-release-upgrader (Ubuntu)
High
Unassigned

Bug Description

I upgraded from bionic to focal this weekend and discovered that one of my packages (safe-rm) can totally break the 20.04 upgrade. Not sure how reproducible it is (I only upgraded once), but I had to remove safe-rm before manually restarting the failed upgrade.

It comes down to the fact that safe-rm takes over the rm command and unfortunately is written in Perl so while Perl isn't quite working (e.g. while it's being upgraded), the rm command is broken :/

I just pushed out a fix to limit the takeover to interactive shells only (https://salsa.debian.org/debian/safe-rm/-/commit/6dbe2adaed423f61464c343f8b9a1b1f42f721f4), but the real fix which I'm hoping to get to in the next few weeks is to rewrite the tool in Rust (https://bugs.launchpad.net/safe-rm/+bug/1854103) to avoid depending on an interpreter.

That said, it's a pretty serious issue so probably the best thing for 20.04 might be to conflict on the package somehow to make sure it's uninstalled prior to the upgrade.

I wasn't sure which package to file this bug against so please re-assign if needed.

François Marier (fmarier) wrote :

I backported the fix to 18.04 in my PPA: https://launchpad.net/~fmarier/+archive/ubuntu/ppa/+build/19900160

but I don't have an easy way of testing the 18.04-20.04 upgrade so I'm not sure that would be enough to fix what I ran into.

François Marier (fmarier) wrote :

> I backported the fix to 18.04 in my PPA: https://launchpad.net/~fmarier/+archive/ubuntu/ppa/+build/19900160

And I have now reverted this since it ended up disabling safe-rm in almost all useful cases :/

Changed in ubuntu-release-upgrader (Ubuntu):
status: New → Confirmed
importance: Undecided → High
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers