X11: Invalid MIT-MAGIC-COOKIE-1 key

Try this before running it

xhost +local:

The xhost program is used to add and delete host names or user names to the list allowed to make connections to the X server. The local family specifies all the local connections.