UnhandledPromiseRejectionWarning: Error: Command failed with exit code 3221225781: C:\Users\Ibrahim\Desktop\Downloader\node_modules\youtube-dl\bin\youtube-dl.exe --dump-json --format=18 --encoding utf8 http://www.youtube.com/watch?v=LXb3EKWsInQ
at makeError (C:\Users\$USER\Desktop\Downloader\node_modules\execa\lib\error.js:56:11)
at handlePromise (C:\Users\$USER\Desktop\Downloader\node_modules\execa\index.js:114:26)
at process._tickCallback (internal/process/next_tick.js:68:7)
(node:17392) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:17392) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
I try running a basic example on this repo and I'm getting
UnhandledPromiseRejectionWarning
. youtube-dl version:3.0.2
This is my code:
and this is the error: