Ubuntu Arduino Snap ( can't open device "/dev/ttyACM0": Permission denied)

Whenever I tried to upload code to my Arduino Uno I was getting this error message on the Arduino IDE which I installed as an Ubuntu snap:

can’t open device “/dev/ttyACM0”: Permission denied

Doing a quick search on the internet I found that the only 2 suggested solutions for this problem where running one or both of the following commands (with slight variations):

sudo usermod -a -G dialout $USER
sudo chmod a+rw /dev/ttyACM0

I tried them but they didn’t work for me, after some time of troubleshooting I found out I needed to do this:

With the Arduino IDE closed go to the Ubuntu Software store and open up the Arduino IDE page, there select the “Permissions” button and on the window that pops up turn on the “Access USB hardware directly” option, that’s it.

Just wanted to post this info somewhere in case some else might need it.

Screenshot from 2020-03-29 20-21-31.png

Thanks for the feedback; the version in the repositories are severely outdated. If you run into issues (no example at hand), you're probably better off downloading from https://www.arduino.cc/en/Main/Software.

Oh that's good to know! is it no longer supported? do you know why it's still available?

Ubuntu has never recalled it from the repos. I suspect that they will only do a security update if deemed necessary.

Got it, thanks for your answers, I’ll delete that version to avoid possible problems.