Did you have a previous version of SNAP? Did you install or run as “root” user(e.g., using “sudo”)?
Why I ask: netbeans bugzilla 134243: “If the IDE is run with root privilegies [sic], files under Userdir/config/Windows2Local/Modes are created or modified with root ownership. Then if the IDE is run with user privilegies, the files cannot be changed and exception is thrown. I changed the code to not throw such confusing exception.”
Using sudo to install SNAP is the reason you are having problems. If you found instructions such as those at GIS blog suggesting that you should ask the author to correct them so others don’t get caught out. (I have already added a comment at GIS blog).
You might be able to recover by changing ownership of the full snap and .snap trees (e.g.,sudo chown -R <user>:<group> ~/.snap ~/snap), but the most certain fix is to delete those directories and their contents (using sudo) and reinstall without sudo.