[BUG] snap warns about $PATH even though it is set

You can see my log here:

user@pc:~/> sudo snap install pycharm-professional --edge --classic
[sudo] password for root: 
Warning: /snap/bin was not found in your $PATH. If you've not restarted your session since you
        installed snapd, try doing that. Please see https://forum.snapcraft.io/t/9469 for more
        details.

pycharm-professional (edge) 2020.2-EAP from jetbrains✓ installed
user@pc:~/> echo $PATH
/home/user/bin:/usr/local/bin:/usr/bin:/bin:/snap/bin:/opt/mssql-tools/bin:/opt/mssql-tools/bin:/opt/mssql-tools/bin
user@pc:~/> sudo echo $PATH
/home/user/bin:/usr/local/bin:/usr/bin:/bin:/snap/bin:/opt/mssql-tools/bin:/opt/mssql-tools/bin:/opt/mssql-tools/bin

My system is openSUSE Tumbleweed and I’ve restarted several times after installing snapd.

The /snap/bin folder also seems correctly setup:

user@pc:~/> l /snap/bin/
total 8
drwxr-xr-x  2 root root 4096 Jun 15 13:51 ./
drwxr-xr-x 16 root root 4096 Jun 15 13:51 ../
lrwxrwxrwx  1 root root   13 Jun 14 17:59 clion -> /usr/bin/snap*
lrwxrwxrwx  1 root root   13 Jun 15 13:36 phpstorm -> /usr/bin/snap*
lrwxrwxrwx  1 root root   13 Jun 15 13:51 pycharm-professional -> /usr/bin/snap*
lrwxrwxrwx  1 root root   13 Jun 15 13:51 rubymine -> /usr/bin/snap*
lrwxrwxrwx  1 root root   13 Jun 14 17:19 slack -> /usr/bin/snap*
lrwxrwxrwx  1 root root   13 Jun 15 10:12 snap-store -> /usr/bin/snap*
lrwxrwxrwx  1 root root   13 Jun 14 17:32 spotify -> /usr/bin/snap*
lrwxrwxrwx  1 root root   13 Jun 14 17:31 telegram-desktop -> /usr/bin/snap*

This looks like a similar problem we have on Fedora/RHEL/CentOS. Basically, the distro sets up sudo with a list of known ‘safe’ paths. There is no way to extend this via config files shipped by packages.

Perhaps we should only limit the message to certain systems/setups.

cc @zyga-snapd