-
Notifications
You must be signed in to change notification settings - Fork 114
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
Can't override '--cookies', causes downloads to fail in all modes other than Classic Mode #240
Comments
From the first screenshot you provided, I would guess that your problem is nothing to do with cookies. The error message in the first screenshot occurs when Tartube tries to interpret the video's upload date, which causes a crash, presumably because LinkedIn is sending in invalid date. All LinkedIn Video seems to be behind a paywall, so you can test this for yourself, and tell me what happens. Click Edit > System preferences... Output > Terminal window. Select the box Write output from downloader's STDOUT to the terminal window. Then de-select the box but don't write each video's JSON data. Select a single video, right-click it and select Check video. The video's metadata should appear in the terminal window. You can either copy-paste the entire output, or you can find the value for upload_date, which should be near the top, and tell me that. I can add a workaround for an invalid date, but it will be much easier if I don't have to guess what the invalid date is. |
By the way, a few months ago youtube-dl began writing the It will be trivial to support a custom location for the cookies file, if that's necessary. |
Hey @axcore thanks for your prompt response! I had wondered that as I wasn't able to consistently reproduce the bug, and that Classic Mode worked. Though it seems the autonumber bug (the main one I was trying to avoid) is in youtube-dl rather than Tartube. Oh well. Anyway, I've enabled those settings as you've requested though unfortunately Tartube doesn't output the raw JSON, it just throws that error. Here's the output:
|
Ok. I will apply a workaround, and we can work from there. It might be a day or two before I'm back at my desk, though. |
All good, many thanks for your prompt response again! |
v2.3.045 contains the workaround. I have also updated the code, so that a custom location for the cookies file can be set (Edit > General download options... > Files > Cookies). The update is only on git, so download it from here, and replace the old files in C:\Users[username]\AppData\Local\Tartube\msys64\home\user\tartube with the new ones. Perhaps you can try the same test, and then we can find out what kind of date LinkedIn is trying to specify. |
Thanks for taking the time to submit a bug report! Please include the following information:
What operating system are you using?
Windows 10 Pro, Version 10.0.18363 Build 18363
What version of Tartube are you using?
v2.3.042
This issue affects the latest versions of youtube-dl and youtube-dlc (at time of writing).
Issue
I'm attempting to download videos from LinkedIn Learning (LIL), of which I have a premium account, for offline viewing when I'm away from home, where internet connections are either slow or non-existent.
I've successfully used youtube-dl-gui for this, though am trying to use Tartube due to a few frustrating bugs in youtube-dl-gui.
As I have a premium account, I've followed ytdl-org/youtube-dl#20326 (comment) to work around youtube-dl's issue of not properly downloading videos from LIL because a premium account is required for the videos I'm downloading. So cookies and an identity header are required, as described in the link above. The fix above works successfully in youtube-dl-gui.
Tartube seems to ignore the --cookies command line option, whilst keeping it's own cookies.txt file which Tartube also seems to be unable to access. Oddly enough, downloads from LIL work completely fine in Classic Mode regardless of what command line options are used.
I cannot find where Tartube allows me to manually set or override the cookies.txt file, as Tartube seems to generate it's own. Apart from using the Command line options window in Download options there doesn't appear to be any way to override this.
When Tartube attempts to access the cookies.txt file it can't seem to be able to when downloading a video from a folder in Tartube, throwing [Errno 22] Invalid Argument in the terminal. Not using any additional command line options (apart from '--verbose') also causes Tartube to silently fail downloading. Duplicating the contents of the working cookie.txt file into Tartube's cookie.txt file doesn't work as Tartube for some reason can't access it.
Both cookie.txt files are exactly the same, as I'd copied the working file contents over into to Tartube's generated one.
Using the following commands in youtube-dl-gui works perfectly:
--verbose --cookies C:/cookies/cookies.txt --add-header "x-li-identity:<<identity header removed for privacy reasons>>"
Putting the same commands into Test System Command... for a single video also works correctly.
Troubleshooting
Tartube downloads silently fail in the Output window (they just appear to hang), when trying to override the cookie.txt file. The terminal view shows the error thrown.
Note: there are two --cookie command line options in the Output window, as Tartube doesn't seem to recognise the '--cookie' command line option.
Using Test System Command... with the following command line options works correctly:
--verbose --cookies C:/cookies/cookies.txt --add-header "x-li-identity:<<identity header removed for privacy reasons>>"
Using Classic Mode
Note: file path has changed here as I'd re-installed Tartube into a different location to check for permissions issues, which don't seem to be apparent. --cookies is also duplicated here, though Classic Mode works...
The text was updated successfully, but these errors were encountered: