maxerbox / vscode-discord

A Visual studio extension, display your current project on vscode in discord with Rich Presence
ISC License
35 stars 13 forks source link

Can't connect to discord rpc #26

Open the-kezian-diary opened 6 years ago

the-kezian-diary commented 6 years ago

After Installation, I get a prompt.

Can't connect to discord rpc: connect ENOENT /run/user/1000/discord-ipc-0

maxerbox commented 6 years ago

I guess discord is launched ?

the-kezian-diary commented 6 years ago

Discord was already launched up. After that I launched VS code. After Installation, On reloading vs code the prompt appears.

A strange thing that i recently noticed, It's happening with all the other vs-code extensions too that rely on Discord RPC.

maxerbox commented 6 years ago

Do you have the client version of discord ?

the-kezian-diary commented 6 years ago

Yes, I do have the client installed (discord-0.0.4.deb)

NetLuiz commented 5 years ago

Yeah i have same problem too

AliDeym commented 5 years ago

Yeah i have same problem too

Issue seems to be Ubuntu 18.04 using snap, so the discord directory looks like snap.discord and not discord. Download Discord Presence plugin, and if it doesn't work for you, head over /home/{user}/.vscode/extensions/icrawl.discord-vscode-x.xx.x/node_modules/discord-rpc/src/transports/ and replace the IPC.js file with the one that I have forked, in my repositories.

Nishant-Pall commented 3 years ago

Am i crazy, there's no node_modules folder in the folder?

therealsujitk commented 3 years ago

Am i crazy, there's no node_modules folder in the folder?

@Nishant-Pall what exactly do you mean? node_modules should never be committed to any repository, it only contains dependencies defined in the lock file (package-lock.json or yarn.lock). That's why we tell git to ignore this folder in .gitignore. If you're testing this on your local environment you need to run npm install or yarn that will install all dependencies given in package.json and generate a lock file.

Nishant-Pall commented 3 years ago

That's why we tell git to ignore this folder in .gitignore. If you're testing this on your local environment you need to run npm install or yarn that will install all dependencies given in package.json and generate a lock file.

Oh yeah, I forgot my bad, although I was able to solve the issue, just do sudo snap remove discord sudo snap remove code and install them from the main site and not from snap.