Closed jalako closed 6 years ago
Sorry, I can't reproduce the error and need some more information about your system. I'm using PHP 7.0 on Windows 7 right now. I have downloaded ffmpeg.exe and my config/custom.php
contains this:
<?php
// config/custom.php
return [
'debug' => true,
'enable_youtube_decipher_signature' => true,
'MP3Enable' => true, // enable or disable media conversion and download to mp3
'MP3ConvertVideo' => true, // 'false' download adaptive audio only to save bandwidth.
'MP3Quality' => '128k', // 'number(k)' (64k, 80k, 96k, 112k, 128k, 160k, 192k) or 'high': bitrate quality of converted mp3
'MP3TempDir' => realpath(__DIR__ . '/../cache/'), // temporary download location for media
'ffmpegPath' => 'C:\Program Files (x86)\ffmpeg\ffmpeg.exe', // ffmpeg location path
];
Also a video url would be helpful so we can ensure that it is definitely not a problem with the video or a specific url.
I am running
PHP 7.0.19-1 (cli) (built: May 11 2017 14:04:47) ( NTS )
on Debian 9.3
So in my case I am not using ffmpeg.exe
One Link that doesn't work :
https://www.youtube.com/watch?v=fZAV3GhTbp0
'enable_youtube_decipher_signature' => true, 'MP3Enable' => true, 'MP3ConvertVideo' => true, 'MP3Quality' => '128k', 'MP3TempDir' => realpath(__DIR__ . '/../cache/'), 'ffmpegPath' => 'C:\Program Files (x86)\ffmpeg\ffmpeg.exe', 'aria2Path' => 'C:\cygwin\bin\aria2c.exe',
@jalako you need fffmpeg installed to convert and download to mp3 and change ffmpegPath
maybe to /usr/bin/ffmpeg
@ewwink thank you for your answer. It now works correctly. I didn't realize, that I had to change it because first of all the default path was an exe because of which I immediately thought it was not relevant to me. You should maybe consider putting in the readme that in order to get the mp3 download to work, you need ffmpeg and change the path to it in the config. Or atleast write a hint in the default config stating this.
Thanks @ewwink for pointing this out. @jalako I've set it on our todo list for the docs.
I get an error when I want to download an mp3
I downloaded the newest version of the YouTube-Downloader. Gave read and write permission. Created a config that enables the mp3-download.
The video is irrelevant. Doesn't work with any.
Expected behavior: I would be able to download the mp3
Actual behavior: An error occurs
Version
Youtube Downloader 0.7-dev
Additional Information
Error:
Fatal error: Uncaught Exception: malformed in /var/www/xxx/src/Http/CurlClient.php:153 Stack trace: #0 /var/www/xxx/src/Http/CurlClient.php(63): YoutubeDownloader\Http\CurlClient->getHttpResponseFromCurl(Resource id #6, Array) #1 /var/www/xxx/src/Application/ControllerAbstract.php(105): YoutubeDownloader\Http\CurlClient->send(Object(YoutubeDownloader\Http\Request), Array) #2 /var/www/xxx/src/Application/DownloadController.php(102): YoutubeDownloader\Application\ControllerAbstract->getSize(NULL, Object(YoutubeDownloader\Config), Object(YoutubeDownloader\Toolkit)) #3 /var/www/xxx/src/Application/App.php(83): YoutubeDownloader\Application\DownloadController->execute() #4 /var/www/xxx/download.php(23): YoutubeDownloader\Application\App->runWithRoute('download') #5 {main} Next RuntimeException: A curl error occurs while execute the curl handler. in /var/www/xxx/src/Http/CurlClient.php:156 Stack trace: #0 /var/www/xxx/src/Http/CurlClient.php(63): You in /var/www/xxx/src/Http/CurlClient.php on line 156