bitfocus / companion-module-discord-api

MIT License
5 stars 2 forks source link

"Failed to create connection" #3

Closed chabad360 closed 2 years ago

chabad360 commented 2 years ago

Describe the bug Trying to add the connection fails.

To Reproduce Steps to reproduce the behaviour:

  1. Click "Add"
  2. Wait 5 seconds
  3. See error

Expected behaviour The module would get added successfully

System (please complete the following information):

Additional Information:

Error:

module(discord-api): Error loading module: Error: Cannot find module './png64' Require stack: 
- /opt/companion/resources/app.asar/node_modules/companion-module-discord-api/dist/feedback.js 
- /opt/companion/resources/app.asar/node_modules/companion-module-discord-api/dist/index.js 
- /opt/companion/resources/app.asar/lib/instance.js 
- /opt/companion/resources/app.asar/app.js 
- /opt/companion/resources/app.asar/electron.js - 
thedist commented 2 years ago

I'm not able to reproduce the issue, as looking at the files from the build process I can clearly see the png64 directory. I'm not sure if this may be an issue with a specific beta build or something so when the Bitfocus Beta Builds page isn't broken I'll try a few different builds and see if I can reproduce with them as that error isn't present on my current build.

There does seem to be some sort of connection issue with the built version of Companion that's not present in a dev Companion, I'm debugging this but I'm still not able to reproduce your issue of not being able to load the png64 file.

chabad360 commented 2 years ago

Hmm, I just tried it on the latest beta and it still fails (to be clear, this is on Linux). Add just to be sure, other connections get added without a hitch.

thedist commented 2 years ago

I think I've found one thing that may be causing issues connecting, I'll have a patch for it soon.

Just to make sure you're aware though, this module is very much in beta for a reason, and there's some work on it that can't be completed until Discords developer team get around to handling their tickets (waiting several months now) so it wont be fully production ready until then.

chabad360 commented 2 years ago

Heh, I don't mind using my own keys. You should see the script I'm currently using to control Discord mute and unmute, it's not pretty.

thedist commented 2 years ago

This should be fixed now in the latest beta.