andweeb / presence.nvim

Discord Rich Presence for Neovim
822 stars 65 forks source link

[NixOS] External command failed when looking for Nvim socket paths #48

Closed enderger closed 2 years ago

enderger commented 2 years ago

Behaviour

RPC does not work at all, likely due to quarks in NixOS

Logs

Session restored from /home/enderger/.local/share/nvim/sessions/\%home\%enderger.vim
[presence.nvim] Setting up plugin for linux
[presence.nvim] Using runtime path: /run/user/1000
[presence.nvim] Using Discord IPC socket path: /run/user/1000/discord-ipc-0
[presence.nvim] Checking Discord IPC socket at /run/user/1000/discord-ipc-0...
[presence.nvim] Using id aadabdab-8a2c-46ab-ad84-a72bc963a6b5
[presence.nvim] Completed plugin setup
[presence.nvim] Getting nvim socket paths...
[presence.nvim] Executing command: `netstat -u|grep --color=never "nvim.*/0"`
[presence.nvim] Checked Discord IPC socket, looks good!
LSP[zls][Info] [notice-main] Using zig lib path '/nix/store/c0xdrg09c5xrgwz1q39c7hngpkrw07sk-zig-0.8.1/lib/zig'
LSP[zls][Info] [notice-main] zls initialized
LSP[zls][Info] [notice-main] Using offset encoding: utf16
[presence.nvim] Unable to get nvim socket paths: ^[[0m^[[1m^[[38;5;9merror^[[0m^[[1m: External command failed^[[0m
[presence.nvim] Got nvim socket paths: {}
[presence.nvim] No other remote nvim instances
andweeb commented 2 years ago

Hi @enderger! Thanks for providing the logs, do you know if the snippet you provided includes all of the messages? There should be more detailing the subsequent connection and authorization with Discord after the socket is checked.

Or by any chance have you disabled the auto-update feature in your config?

enderger commented 2 years ago

Hey, Yes, all messages are included. I’ve tried running the netstat command manually, but no sockets for Neovim show up (I’ve seen the files in /tmp). I should note that NixOS is a fairly strange Linux distro and I’m installing Neovim through Nix (it is automatically wrapped, so there may be shenanigans there). The Discord socket appears to be fine, it’s the Neovim search that errors (with the “external command failed” message showing as the only error). While my configs are integrated with Nix, they are available in literate form on https://man.sr.ht/~hutzdog/dotfiles/users/enderger.md#neovim. I can confirm that auto update is on. If you give me the information I need to provide (first time with this particular project), I’ll gladly provide it (fellow developer who knows how much of a d*ck some users can be).

EDIT: might be related to the fact that I’m too much of a moron to know what a boolean is, apparently (set auto update to a bloody string). On Sun, Nov 28, 2021 at 20:32, Andrew Kwon @.***> wrote:

Hi @enderger https://github.com/enderger! Thanks for providing the logs, do you know if the snippet you provided includes all of the messages? There should be more detailing the subsequent connection and authorization with Discord after the socket is checked.

Or by any chance have you disabled the auto-update feature in your config?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/andweeb/presence.nvim/issues/48#issuecomment-981284381, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIU2GI4J2STCVUFYHSPH2ATUOL65VANCNFSM5I5T54RQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

enderger commented 2 years ago

Seems that I was being impatient or my use of a string containing “true” caused the problem.