In a mess uninstalling/installing on Kubuntu 18.04 LTS

Audactiy (the latest from the Ubuntu repository) had crashed on me a couple of times today so I uninstalled through Discover and then tried

sudo snap install audacity # version 2.4.1, or

2020-06-21T18:51:56+01:00 INFO Waiting for restart…
audacity 2.4.1 from Daniel Llewellyn (diddledan) installed

I’d not used SNAP before so that ran through the install process first.

That Audacity would not read my files on my NTFS partition and impatiently I did a
sudo apt-get autoremove --purge audacity

That didn’t fully work, Audacity still loads and
sudo snap remove audacity
results in

sudo snap remove audacity
error: cannot perform the following tasks:
- Disconnect audacity:unity7 from snapd:unity7 (cannot update mount namespace of snap "audacity": cannot update preserved namespace of snap "audacity": 
update.go:85: cannot change mount namespace according to change unmount (/var/lib/snapd/hostfs/var/cache/fontconfig /var/cache/fontconfig none bind,ro 0 0): invalid argument
update.go:85: cannot change mount namespace according to change unmount (/var/lib/snapd/hostfs/usr/share/fonts /usr/share/fonts none bind,ro 0 0): invalid argument
cannot update snap namespace: no such file or directory

As you gather I don’t know what I’m doing and as per title I’m in a mess. I’ve got about 60 LPs as Audacity projects I’m trying to deal with and I could do with some help for dummies. That is help to get a working copy of Audacity running, one way or another.

I don’t use snapd, so I probably can’t offer much help, but if in your situation I would try:

  1. Reboot
  2. Reinstall the snapd version of Audacity
  3. Log out and back in again.
sudo snap remove audacity

Then, assuming that has removed the snapd version, I’d do:

 sudo apt remove audacity audacity-data

That should either remove the deb version if it exists, or say something like:

Package 'audacity' is not installed, so not removed
Package 'audacity-data' is not installed, so not removed


rm -r ~/.audacity-data
rm -r ~/.audacity-files

Then, assuming that you haven’t enabled any PPA sources:

sudo apt install audacity
~$ sudo snap install audacity
snap "audacity" is already installed, see 'snap help refresh'

snap refresh --list
All snaps up to date.

Audacity 2.4.1 loads and I can access files under my Home folder.
However as soon as I try to get where all my main files are (under /media/shared_partition), and which were accessible before I tried this install, I get:

Could not read the contents of media
Error opening directory ‘/media’: Permission denied

This is where I’d got to earlier when I then tried to remove the install.

A Dependency check, which I don’t understand, gives:

Your project is self-contained; it does not depend on any external audio files. 

Some older Audacity projects may not be self-contained, and care 
is needed to keep their external dependencies in the right place.
New projects will be self-contained and are less risky.

I’ve tried to generate diagnostics but I don’t know how to get to them…

The /media/ directory is normally for mounting external devices. By default it is owned by “root” and is read only.

User files should normally be kept in a subdirectory of the user’s “Home” folder.

If you copy your files from “/media/shared_partition” to “/home//Music/” (or a sub-directory of “Music”), are you able to use your current version of Audacity?

I had been using the previous version, installed from the Kubuntu repository, for the past several months in the NTFS shared partition. All of my data of any type is in the shared partition. It is mounted automatically under /media/ and contains my videos, music, documents etc etc. It means I can I access it whether or not I boot into Windows or Linux and even via my network shares. Working from my /home folder is not what I want and not what I’ve been doing. If the snap version of Audacity is presuming that I’m only going to work from /home then that is not a good move as no other software, including kdenlive for instance, works that way.

Nonetheless none of the above is helping to remove the snapd version of Audacity.

Snap packages run in a “sandbox” environment. That may well be why it behaves differently from the deb version.

I’m not able to help with that as I don’t use Snapd. Perhaps worth asking on the Ubuntu forums (