Androz2091 / discord-music-bot

The perfect music bot for your Discord server! 🤘
238 stars 127 forks source link

Can't start bot. #18

Closed Matthaeus07 closed 2 years ago

Matthaeus07 commented 3 years ago

When I want to start the bot with 'node .' it says:

'$ node . C:\Users*myuser*\Documents\musicbot\discord-music-bot\node_modules\slash-create\lib\ creator.js:31 throw new Error('An application ID must be defined!'); ^

Error: An application ID must be defined! at new SlashCreator (C:\Users*myuser\Documents\musicbot\discord-music-bot\node_ modules\slash-create\lib\creator.js:31:19) at Object. (C:\Users*myuser\Documents\musicbot\discord-music-bot\ind ex.js:21:17) at Module._compile (node:internal/modules/cjs/loader:1101:14) at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10) at Module.load (node:internal/modules/cjs/loader:981:32) at Function.Module._load (node:internal/modules/cjs/loader:822:12) at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_ma in:79:12) at node:internal/main/run_main_module:17:47 '

Edward-Nigma commented 3 years ago

I also experienced the same error. I'm running this program on a fresh Ubuntu installation. I can only assume something's going wrong with slash-create? I think that it's supposed to draw the information in .env. I made sure that I filled in all the blanks in that text file (I copied the original .env.example and modified it, as instructed). In any case, I've also attached my error message.

MyUser@PCName:~$ node discord-music-bot
/home/MyUser/node_modules/slash-create/lib/creator.js:31
            throw new Error('An application ID must be defined!');
            ^

Error: An application ID must be defined!
    at new SlashCreator (/home/MyUser/node_modules/slash-create/lib/creator.js:31:19)
    at Object.<anonymous> (/home/MyUser/discord-music-bot/index.js:21:17)
    at Module._compile (node:internal/modules/cjs/loader:1101:14)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1153:10)
    at Module.load (node:internal/modules/cjs/loader:981:32)
    at Function.Module._load (node:internal/modules/cjs/loader:822:12)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:79:12)
    at node:internal/main/run_main_module:17:47
DanielKHL commented 2 years ago

I also have this issue? anyone know how to solve it?

Edward-Nigma commented 2 years ago

It looks like I was missing a few things. I forgot to install the sodium/tweetnacl/libsodium-wrappers for discordjs/voice. Anyway, in order to install these, make sure you have node-gyp, autoconf, and automake. You will additionally need fluent-ffmpeg and ytdl-core to run the bot. I believe I may have also been missing opusscript.

Basically, I was missing a ton of stuff deep into the dependencies. Hope this can get everyone back on track!