twlite / discord-ytdl-core

Simple ytdl wrapper for discord bots with custom ffmpeg args support.
https://www.npmjs.com/package/discord-ytdl-core
Apache License 2.0
51 stars 10 forks source link

MinigetError: input stream: Status code: 404 #25

Closed LoneExile closed 3 years ago

LoneExile commented 3 years ago

error from this line const songInfo = await ytdl.getInfo(args[1]) , args[1] is song url

MinigetError: Status code: 404
    at ClientRequest.<anonymous> (/app/node_modules/miniget/dist/index.js:210:27)
    at Object.onceWrapper (node:events:514:26)
    at ClientRequest.emit (node:events:394:28)
    at HTTPParser.parserOnIncomingClient (node:_http_client:621:27)
    at HTTPParser.parserOnHeadersComplete (node:_http_common:127:17)
    at TLSSocket.socketOnData (node:_http_client:487:22)
    at TLSSocket.emit (node:events:394:28)
    at addChunk (node:internal/streams/readable:312:12)
    at readableAddChunk (node:internal/streams/readable:287:9)
    at TLSSocket.Readable.push (node:internal/streams/readable:226:10)
    at TLSWrap.onStreamRead (node:internal/stream_base_commons:190:23) {
  statusCode: 404
}
/app/node_modules/discord.js/src/rest/RequestHandler.js:170
          return reject(new DiscordAPIError(request.path, data, request.method, res.status));
                        ^

DiscordAPIError: Cannot send an empty message
    at RequestHandler.execute (/app/node_modules/discord.js/src/rest/RequestHandler.js:170:25)
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (node:internal/process/task_queues:96:5) {
  method: 'post',
  path: '/channels/802691580095234048/messages',
  code: 50006,
  httpStatus: 400
}
twlite commented 3 years ago

This is not the issue from this package.

Check https://github.com/fent/node-ytdl-core/issues/923