X11 / xserver / XWIN gvim problems

Case:

WARNING**: Error retrieving accessibility bus address: org.freedesktop.DBus.Error.ServiceUnknown: The name org.a11y.Bus was not provided by any .service files

Solved by adding NO_AT_BRIDGE=1 before launching gvim ( i.e [user@server]$ NO_AT_BRIDGE=1 gvim myfile.txt) source: https://github.com/NixOS/nixpkgs/issues/16327

Case:

connect /tmp/.X11-unix/X0: Permission denied
E233: cannot open display
Press ENTER or type command to continue

Solved by using correct DISPLAY informations before connecting (DISPLAY=localhost:0.0) source: https://unix.stackexchange.com/a/220234