If one of the paths contain a ~ replace it with home folder
Replace the stacktrace with a simple sysout