gopassbridge icon indicating copy to clipboard operation
gopassbridge copied to clipboard

"Error when communicating with the native messaging host." unless browser started from terminal.

Open nargetdev opened this issue 3 years ago • 5 comments

For anyone else running into this ..

Everything "just works" if you just open the application from the terminal i.e. open '/Applications/Brave Browser.app' .. rather than from the usual cmd+space launcher.

Not sure why, but I was really struggling to resolve before I got that sorted.

nargetdev avatar Feb 08 '22 19:02 nargetdev

Usually, this means that your shell sets up some additional environment that is not set up when running from a launcher. What platform are you running it on?

martinhoefling avatar Apr 08 '22 20:04 martinhoefling

I'm having the same issue on Mac OS 12.3.1.

5mutawa avatar May 01 '22 19:05 5mutawa

Same on NixOS (Linux).

con-f-use avatar May 05 '23 22:05 con-f-use

I think it might be, because I set a custom PASSWORD_STORE_DIR via environment variable and according to firefox debug, it doesn't seem to get that env var. But I'm not sure why.

Edit: I can confirm that, the PASSWORD_STORE_DIR environment variable was somehow not propagated to firefox, so I wrapped the executable to include it.

con-f-use avatar May 08 '23 12:05 con-f-use

I was hitting this on MacOS (13.2.1). I had installed gopass, gopass-jsonapi, and GnuPG via MacPorts. When launching Chrome from the launcher, gpg wasn't ending up in my PATH. I modified ~/.config/gopass/gopass_wrapper.sh to include:

 export PATH="$PATH:/opt/local/bin" # required on MacOS/MacPorts

And that fixed it for me.

wholtz avatar May 09 '23 19:05 wholtz