museofficial / muse

🎧 a self-hosted midwestern Discord music bot that doesn't suck
MIT License
880 stars 229 forks source link

Bot is stuck on "Sending Command..." in Discord #617

Open giomxx opened 2 years ago

giomxx commented 2 years ago

What's happening? Concisely describe what's going wrong.

When trying to run a command in discord, it is just stuck on "sending command...". I have tried multiple commands, on multiple servers, and multiple installations of the bot.

No logs, or console output is created past the "Ready!" message.

Logs

Screenshots If applicable, add screenshots to help explain your problem.

image

Additional context Add any other context about the problem here.

Runtime I'm running Muse:

Versions

hubret commented 2 years ago

I'm assuming youre using the latest version of muse?

I'm also seeing this when trying to set role after a fresh upgrade (1.6 -> 1.8.2): 1.6 through 1.8.2 all show this same behavior for me: image

Nothing in console either.

<1.6 shows:

image

giomxx commented 2 years ago

Yeah it is a weird one, I'm on a fresh install of the latest. Mine doesn't even get to "Application did not respond", it just infinitely loads

codetheweb commented 2 years ago

Have you both run yarn install? A dependency was recently changed that might be causing this.

hubret commented 2 years ago

I've run npm i after checking out each tag I tested. That's good to know, I might try to boot this up from scratch if it might be an old package left over for some reason.

Edit: after a fresh clone, checkout to latest release, install packages, and then start script, the same thing happens.

It turns out I might be having a different issue. Muse bot is not responding to /config, but will respond to /play, and will join my channel, but won't actually start playing audio.

Error: type reelShelfRenderer is not known
    at parseItem (/home/hubret/muse/node_modules/ytsr/lib/parseItem.js:74:13)
    at catchAndLogFunc (/home/hubret/muse/node_modules/ytsr/lib/parseItem.js:81:12)
    at module.exports (/home/hubret/muse/node_modules/ytsr/lib/parseItem.js:104:46)
    at /home/hubret/muse/node_modules/ytsr/lib/main.js:53:34
    at Array.map (<anonymous>)
    at module.exports (/home/hubret/muse/node_modules/ytsr/lib/main.js:53:25)
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async KeyValueCacheProvider.wrap (file:///home/hubret/muse/src/services/key-value-cache.ts:46:20)
    at async run (file:///home/hubret/muse/node_modules/p-queue/dist/index.js:109:36)

/********************************************************************************************************************************************************************************************************
failed at func parseItem: type reelShelfRenderer is not known
pls post the the files in /home/hubret/muse/node_modules/ytsr/dumps to https://github.com/TimeForANinja/node-ytsr/issues
os: linux-x64, node.js: v16.14.0, ytsr: 3.6.0
********************************************************************************************************************************************************************************************************\

Edit 2: this is on master branch, but I waited a few minutes after trying again, and muse sent me another greeting message (so this is the second greeting message for this installation, and it happened after a substantial amount of time). /config now works. Maybe something needed to resolve for the whole time between the two welcome messages, and the bot couldnt respond to any commands during that time.

Oh my god I had two instances running at the same time

giomxx commented 2 years ago

I've been using npm i instead of yarn, a completely fresh install, following the install guide on the readme

codetheweb commented 2 years ago

@giomxx can you run in debug mode by setting the environment variable DEBUG to * and post the output? (DEBUG=* npm run start on *sh)

joepboumans commented 2 years ago

image I have exactly the same problem. I created a new stack and then ran npm i and yarn install, but both did not yield any results.

The only error that I get is the error below. This only happens the first time I start the container and after it restarts itself the error is gone.

Running version 2.0.4 built on 5/17/2022 (commit eb07ac6d2275a5aa30754c3ed4bc4f5c89a0c72e)
🔧 Need help? https://github.com/codetheweb/muse/discussions/new
🐛 Bug? https://github.com/codetheweb/muse/issues/new
✨ New feature? https://github.com/codetheweb/muse/issues/new
☕ Discussion? https://github.com/codetheweb/muse/discussions/new
💰 Help me? https://www.paypal.me/codetheweb https://github.com/sponsors/codetheweb
- Applying database migrations...
(node:90) ExperimentalWarning: stream/web is an experimental feature. This feature could change at any time
✔ Database migrations applied.
- 📡 connecting to Discord...
node:internal/process/promises:246
          triggerUncaughtException(err, true /* fromPromise */);
          ^
Error: getaddrinfo ENOTFOUND accounts.spotify.com
    at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:71:26) {
  errno: -3008,
  code: 'ENOTFOUND',
  syscall: 'getaddrinfo',
  hostname: 'accounts.spotify.com',
  response: undefined
}
file:///usr/app/node_modules/execa/lib/error.js:59
        error = new Error(message);
                ^
Error: Command failed with exit code 1: esmo src/scripts/migrate-and-start.ts
    at makeError (file:///usr/app/node_modules/execa/lib/error.js:59:11)
    at handlePromise (file:///usr/app/node_modules/execa/index.js:119:26)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async file:///usr/app/src/scripts/run-with-database-url.ts:5:3 {
  shortMessage: 'Command failed with exit code 1: esmo src/scripts/migrate-and-start.ts',
  command: 'esmo src/scripts/migrate-and-start.ts',
  escapedCommand: 'esmo "src/scripts/migrate-and-start.ts"',
  exitCode: 1,
  signal: undefined,
  signalDescription: undefined,
  stdout: undefined,
  stderr: undefined,
  failed: true,
  timedOut: false,
  isCanceled: false,
  killed: false
}
error Command failed with exit code 1.
codetheweb commented 2 years ago

@joepboumans I'm pretty sure your issue is unrelated and outside the scope of Muse; it looks like your DNS server might be flakey.