Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Muse joins vc, but doesn't play any music #1166

Open
3 tasks
kirankunigiri opened this issue Dec 12, 2024 · 1 comment
Open
3 tasks

Muse joins vc, but doesn't play any music #1166

kirankunigiri opened this issue Dec 12, 2024 · 1 comment
Labels

Comments

@kirankunigiri
Copy link

What's happening?
Muse joins the vc when I use /play and it even shows the song preview and that it is added to the queue. However, it doesn't play any audio. I don't see any error messages in the logs when I played the song. I'm running it through node on wsl from the latest commit. I tried docker before, but the docker version didn't even load the song correctly so I switched to the node version.

Logs

(base) kiran@KiranPC:~/github/muse$ DEBUG=* npm run start

> muse@2.10.0 start
> npm run env:set-database-url -- tsx src/scripts/migrate-and-start.ts


> muse@2.10.0 env:set-database-url
> tsx src/scripts/run-with-database-url.ts tsx src/scripts/migrate-and-start.ts

(node:169670) ExperimentalWarning: `--experimental-loader` may be removed in the future; instead use `register()`:
--import 'data:text/javascript,import { register } from "node:module"; import { pathToFileURL } from "node:url"; register("file%3A///home/kiran/github/muse/node_modules/tsx/dist/loader.js", pathToFileURL("./"));'
(Use `node --trace-warnings ...` to show where the warning was created)
(node:169693) ExperimentalWarning: `--experimental-loader` may be removed in the future; instead use `register()`:
--import 'data:text/javascript,import { register } from "node:module"; import { pathToFileURL } from "node:url"; register("file%3A///home/kiran/github/muse/node_modules/tsx/dist/loader.js", pathToFileURL("./"));'
(Use `node --trace-warnings ...` to show where the warning was created)
  prisma:tryLoadEnv  Environment variables loaded from /home/kiran/github/muse/.env +0ms
  prisma:client  checkPlatformCaching:postinstall true +0ms
  prisma:client  checkPlatformCaching:ciName undefined +0ms
  prisma:tryLoadEnv  Environment variables loaded from /home/kiran/github/muse/.env +110ms
  prisma:client  dirname /home/kiran/github/muse/node_modules/.prisma/client +0ms
  prisma:client  relativePath ../../.. +0ms
  prisma:client  cwd /home/kiran/github/muse +0ms
  prisma:client  protocol graphql +0ms
  prisma:client  clientVersion 4.16.0 +0ms
  prisma:client  clientEngineType library +0ms
  prisma:client:libraryEngine  internalSetup +0ms
  prisma:client  checkPlatformCaching:postinstall true +165ms
  prisma:client  checkPlatformCaching:ciName undefined +0ms
  prisma:tryLoadEnv  Environment variables loaded from /home/kiran/github/muse/.env +165ms
  prisma:client  dirname /home/kiran/github/muse/node_modules/.prisma/client +164ms
  prisma:client  relativePath ../../.. +0ms
  prisma:client  cwd /home/kiran/github/muse +0ms
  prisma:client  protocol graphql +0ms
  prisma:client  clientVersion 4.16.0 +0ms
  prisma:client  clientEngineType library +0ms
  prisma:client:libraryEngine  internalSetup +164ms
========================================
========================================
================= muse =================
========================================
=========== Made with 🎶 by ============
==== https://github.com/codetheweb =====
========================================
========================================

Running version 2.10.0 built on unknown date (commit unknown)

🔧 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...  prisma:get-platform  Found distro info:
{
  "targetDistro": "debian",
  "familyDistro": "debian",
  "originalDistro": "ubuntu"
} +0ms
  prisma:get-platform  Trying platform-specific paths for "debian" (and "ubuntu") +0ms
  prisma:get-platform  Found distro info:
{
  "targetDistro": "debian",
  "familyDistro": "debian",
  "originalDistro": "ubuntu"
} +0ms
  prisma:get-platform  Trying platform-specific paths for "debian" (and "ubuntu") +0ms
  prisma:get-platform  Found libssl.so file using platform-specific paths: libssl.so.3 +1ms
  prisma:get-platform  The parsed libssl version is: 3.0.x +0ms
  prisma:client:engines:resolveEnginePath  enginePath /home/kiran/github/muse/node_modules/.prisma/client/libquery_engine-debian-openssl-3.0.x.so.node +0ms
  prisma:get-platform  Found libssl.so file using platform-specific paths: libssl.so.3 +4ms
  prisma:get-platform  The parsed libssl version is: 3.0.x +0ms
  prisma:client:engines:resolveEnginePath  enginePath /home/kiran/github/muse/node_modules/.prisma/client/libquery_engine-debian-openssl-3.0.x.so.node +5ms
  prisma:client:libraryEngine  library starting +29ms
  prisma:client:libraryEngine  library started +1ms
  prisma:client  prisma.$queryRaw(SELECT COUNT(id) FROM _prisma_migrations, []) +0ms
  prisma:client  Prisma Client call: +35ms
  prisma:client  prisma.$queryRaw({
  query: 'SELECT COUNT(id) FROM _prisma_migrations',
  parameters: {
    values: '[]',
    __prismaRawParameters__: true
  }
}) +1ms
  prisma:client  Generated request: +0ms
  prisma:client  mutation {
  queryRaw(
    query: "SELECT COUNT(id) FROM _prisma_migrations"
    parameters: "[]"
  )
}
 +0ms
  prisma:client:libraryEngine  sending request, this.libraryStarted: true +6ms
✔ Database migrations applied.
  prisma:client:libraryEngine  library starting +287ms
  prisma:client:libraryEngine  library started +1ms
  prisma:client  Prisma Client call: +290ms
  prisma:client  prisma.fileCache.findMany({
  where: undefined,
  orderBy: {
    createdAt: 'asc'
  },
  take: 50
}) +1ms
  prisma:client  Generated request: +0ms
  prisma:client  query {
  findManyFileCache(
    orderBy: [
      {
        createdAt: asc
      }
    ]
    take: 50
  ) {
    hash
    bytes
    accessedAt
    createdAt
    updatedAt
  }
}
 +0ms
  prisma:client:libraryEngine  sending request, this.libraryStarted: true +3ms
  muse Evicting oldest files... +0ms
  prisma:client  Prisma Client call: +1ms
  prisma:client  prisma.fileCache.aggregate({
  select: {
    _sum: {
      select: {
        bytes: true
      }
    }
  }
}) +1ms
  prisma:client  Generated request: +0ms
  prisma:client  query {
  aggregateFileCache {
    _sum {
      bytes
    }
  }
}
 +0ms
  prisma:client:libraryEngine  sending request, this.libraryStarted: true +2ms
⠋ 📡 connecting to Discord...  muse Provided token: MTMxNjU2NTc1MTA0NTI5MjEwMw.G5vjV8.************************************** +7ms
  muse Preparing to connect to the gateway... +0ms
  muse No files needed to be evicted. Total size of the cache is currently 0 bytes, and the cache limit is 2000000000 bytes. +9ms
⠸ 📡 connecting to Discord...  muse [WS => Manager] Fetched Gateway Information
  muse     URL: wss://gateway.discord.gg
  muse     Recommended Shards: 1 +253ms
  muse [WS => Manager] Session Limit Information
  muse     Total: 1000
  muse     Remaining: 989 +0ms
  muse [WS => Shard 0] Connecting to wss://gateway.discord.gg?v=10&encoding=json +1ms
  muse [WS => Shard 0] Waiting for event hello for 60000ms +2ms
⠴ 📡 connecting to Discord...  muse [WS => Shard 0] Preparing first heartbeat of the connection with a jitter of 0.9177207430725005; waiting 37855ms +163ms
  muse [WS => Shard 0] Waiting for identify throttle +0ms
  muse [WS => Shard 0] Identifying
  muse  shard id: 0
  muse  shard count: 1
  muse  intents: 1153
  muse  compression: none +0ms
  muse [WS => Shard 0] Waiting for event ready for 15000ms +1ms
⠧ 📡 connecting to Discord...  muse [WS => Shard 0] Shard received all its guilds. Marking as fully ready. +191ms
  muse --------------------------------------------------
  muse Core Dependencies
  muse - @discordjs/voice: 0.17.0
  muse - prism-media: 1.3.5
  muse 
  muse Opus Libraries
  muse - @discordjs/opus: 0.8.0
  muse - opusscript: not found
  muse 
  muse Encryption Libraries
  muse - sodium-native: not found
  muse - sodium: not found
  muse - libsodium-wrappers: 0.7.10
  muse - tweetnacl: not found
  muse 
  muse FFmpeg
  muse - version: 7.1
  muse - libopus: yes
  muse -------------------------------------------------- +20ms
✔ Ready! Invite the bot with https://discordapp.com/oauth2/authorize?client_id=1316565751045292103&scope=bot%20applications.commands&permissions=36700160
  prisma:client  Prisma Client call: +5s
  prisma:client  prisma.setting.findUnique({
  where: {
    guildId: '351270987641126912'
  }
}) +0ms
  prisma:client  Generated request: +0ms
  prisma:client  query {
  findUniqueSetting(where: {
    guildId: "351270987641126912"
  }) {
    guildId
    playlistLimit
    secondsToWaitAfterQueueEmpties
    leaveIfNoListeners
    queueAddResponseEphemeral
    autoAnnounceNextSong
    defaultVolume
    defaultQueuePageSize
    turnDownVolumeWhenPeopleSpeak
    turnDownVolumeWhenPeopleSpeakTarget
    createdAt
    updatedAt
  }
}
 +0ms
  prisma:client:libraryEngine  sending request, this.libraryStarted: true +5s
  prisma:client  Prisma Client call: +265ms
  prisma:client  prisma.keyValueCache.findUnique({
  where: {
    key: '[{"searchParams":{"part":"id, snippet, contentDetails","id":"SXQeyudFe-g"}}]'
  }
}) +0ms
  prisma:client  Generated request: +0ms
  prisma:client  query {
  findUniqueKeyValueCache(where: {
    key: "[{\"searchParams\":{\"part\":\"id, snippet, contentDetails\",\"id\":\"SXQeyudFe-g\"}}]"
  }) {
    key
    value
    expiresAt
    createdAt
    updatedAt
  }
}
 +0ms
  prisma:client:libraryEngine  sending request, this.libraryStarted: true +265ms
  muse Cache hit: [{"searchParams":{"part":"id, snippet, contentDetails","id":"SXQeyudFe-g"}}] +5s
  prisma:client  Prisma Client call: +2ms
  prisma:client  prisma.setting.findUnique({
  where: {
    guildId: '351270987641126912'
  }
}) +0ms
  prisma:client  Generated request: +0ms
  prisma:client  query {
  findUniqueSetting(where: {
    guildId: "351270987641126912"
  }) {
    guildId
    playlistLimit
    secondsToWaitAfterQueueEmpties
    leaveIfNoListeners
    queueAddResponseEphemeral
    autoAnnounceNextSong
    defaultVolume
    defaultQueuePageSize
    turnDownVolumeWhenPeopleSpeak
    turnDownVolumeWhenPeopleSpeakTarget
    createdAt
    updatedAt
  }
}
 +0ms
  prisma:client:libraryEngine  sending request, this.libraryStarted: true +2ms
  prisma:client  Prisma Client call: +1ms
  prisma:client  prisma.setting.findUnique({
  where: {
    guildId: '351270987641126912'
  }
}) +0ms
  prisma:client  Generated request: +0ms
  prisma:client  query {
  findUniqueSetting(where: {
    guildId: "351270987641126912"
  }) {
    guildId
    playlistLimit
    secondsToWaitAfterQueueEmpties
    leaveIfNoListeners
    queueAddResponseEphemeral
    autoAnnounceNextSong
    defaultVolume
    defaultQueuePageSize
    turnDownVolumeWhenPeopleSpeak
    turnDownVolumeWhenPeopleSpeakTarget
    createdAt
    updatedAt
  }
}
 +0ms
  prisma:client:libraryEngine  sending request, this.libraryStarted: true +1ms
  prisma:client  Prisma Client call: +1ms
  prisma:client  prisma.fileCache.findUnique({
  where: {
    hash: 'df9b4a90acad4c47fafa0d1a6fc3bd60a616b2a2b7b094dbf5c933b03b32a2859afb5306fbf24e71a87df3d5ac14dc45b34beaf34132874a886c61651b99602f'
  }
}) +0ms
  prisma:client  Generated request: +1ms
  prisma:client  query {
  findUniqueFileCache(where: {
    hash: "df9b4a90acad4c47fafa0d1a6fc3bd60a616b2a2b7b094dbf5c933b03b32a2859afb5306fbf24e71a87df3d5ac14dc45b34beaf34132874a886c61651b99602f"
  }) {
    hash
    bytes
    accessedAt
    createdAt
    updatedAt
  }
}
 +0ms
  prisma:client:libraryEngine  sending request, this.libraryStarted: true +2ms
  muse [VOICE] received voice state update: {"member":{"user":{"username":"Muse","public_flags":0,"id":"1316565751045292103","global_name":null,"display_name":null,"discriminator":"2596","clan":null,"bot":true,"avatar_decoration_data":null,"avatar":null},"roles":["1316571247341211750"],"premium_since":null,"pending":false,"nick":null,"mute":false,"joined_at":"2024-12-12T01:04:06.122839+00:00","flags":1,"deaf":false,"communication_disabled_until":null,"banner":null,"avatar":null},"user_id":"1316565751045292103","suppress":false,"session_id":"a675f2215f93023086818346774d5919","self_video":false,"self_mute":false,"self_deaf":false,"request_to_speak_timestamp":null,"mute":false,"guild_id":"351270987641126912","deaf":false,"channel_id":"351270987641126914"} +106ms
  prisma:client  Prisma Client call: +102ms
  prisma:client  prisma.setting.findUnique({
  where: {
    guildId: '351270987641126912'
  }
}) +0ms
  prisma:client  Generated request: +0ms
  prisma:client  query {
  findUniqueSetting(where: {
    guildId: "351270987641126912"
  }) {
    guildId
    playlistLimit
    secondsToWaitAfterQueueEmpties
    leaveIfNoListeners
    queueAddResponseEphemeral
    autoAnnounceNextSong
    defaultVolume
    defaultQueuePageSize
    turnDownVolumeWhenPeopleSpeak
    turnDownVolumeWhenPeopleSpeakTarget
    createdAt
    updatedAt
  }
}
 +0ms
  prisma:client:libraryEngine  sending request, this.libraryStarted: true +102ms
  muse [VOICE] received voice server: {"t":"VOICE_SERVER_UPDATE","s":7,"op":0,"d":{"token":"30beb5aef0b72dd9","guild_id":"351270987641126912","endpoint":"santa-clara1517.discord.media:443"}} +92ms
WARNING: @distube/ytdl-core is out of date! Update with "npm install @distube/ytdl-core@latest".
  muse Using format {
  mimeType: 'audio/webm; codecs="opus"',
  qualityLabel: null,
  bitrate: 164491,
  audioBitrate: 160,
  itag: 251,
  url: 'https://rr5---sn-n4v7sney.googlevideo.com/videoplayback?expire=1733987201&ei=ITdaZ5uKA-fUsfIP8qb_wAM&ip=98.248.68.190&id=o-ADrWA-W18-1159pcz0bp-l_XOUbpkd2hTXTHgQtz9FWZ&itag=251&source=youtube&requiressl=yes&xpc=EgVo2aDSNQ%3D%3D&met=1733965601%2C&mh=Al&mm=31%2C26&mn=sn-n4v7sney%2Csn-a5meknsd&ms=au%2Conr&mv=m&mvi=5&pl=23&rms=au%2Cau&initcwndbps=4663750&bui=AfMhrI_EOx9FX_Pg3muSZmafRs0VwF9UgMezKjToIiIwbPRQtKFGxfNNDw0EyF-V1jpDPri-eVaqii1X&spc=x-caUB-8UjSUs5j5pUEwMbIxCt79AyRFhI2jfD2RGZgTYifL3Bn-c4z9vg&vprv=1&svpuc=1&mime=audio%2Fwebm&rqh=1&gir=yes&clen=71964680&dur=4027.741&lmt=1730727958516320&mt=1733965278&fvip=2&keepalive=yes&fexp=51326932%2C51335594%2C51347747&c=ANDROID&txp=5532434&sparams=expire%2Cei%2Cip%2Cid%2Citag%2Csource%2Crequiressl%2Cxpc%2Cbui%2Cspc%2Cvprv%2Csvpuc%2Cmime%2Crqh%2Cgir%2Cclen%2Cdur%2Clmt&sig=AJfQdSswRQIgD7TPokDsghXUbf00VgJDc_grSmqLt_LOFkKlqHSIm6gCIQD6UlntcP7SXtCjBbo5PC3EJozs-V6sy0j1nL2sgCmdVg%3D%3D&lsparams=met%2Cmh%2Cmm%2Cmn%2Cms%2Cmv%2Cmvi%2Cpl%2Crms%2Cinitcwndbps&lsig=AGluJ3MwRQIgMkEg2ZldyuQ5hgen7XJBpQS67lmq2zmonuPfCtp0IhwCIQCmPuNGGuu7A9uBUs7YbO_0gxvBDx3gXZzsCEqjwgUHlg%3D%3D',
  initRange: { start: '0', end: '265' },
  indexRange: { start: '266', end: '7422' },
  lastModified: '1730727958516320',
  contentLength: '71964680',
  quality: 'tiny',
  projectionType: 'RECTANGULAR',
  averageBitrate: 142938,
  audioQuality: 'AUDIO_QUALITY_MEDIUM',
  approxDurationMs: '4027741',
  audioSampleRate: '48000',
  audioChannels: 2,
  loudnessDb: -1.1499996,
  hasVideo: false,
  hasAudio: true,
  container: 'webm',
  codecs: 'opus',
  videoCodec: null,
  audioCodec: 'opus',
  isLive: false,
  isHLS: false,
  isDashMPD: false
} +1s
  muse Not caching video +1ms

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

Additional context
Add any other context about the problem here.

Runtime
I'm running Muse:

  • Directly from the cloned repository
  • Inside a Docker container
  • Something else (please elaborate)

Versions

  • Muse: latest commit
  • Docker (if applicable):
  • OS:
  • Node.js: (if running outside the Docker container) v20.16.0
  • ffmpeg: (if running outside the Docker container, 4.1 or later is required) ffmpeg version 7.1
@kirankunigiri
Copy link
Author

I found a fix. According to this other issue, using ffmpeg v4 instead worked for them. I installed ffmpeg v4 with brew, set the path, and now it sort of works.

brew install ffmpeg@4
export PATH="/home/linuxbrew/.linuxbrew/opt/ffmpeg@4/bin:$PATH"

Sometimes it just completely stops working, at which point I have to kick it from vc and make it join again. Queue and skip also break often. But this is better than nothing! I think this recommendation of using an older ffmpeg should be put in the docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant