Repository navigation
Offer Upload the file when a link's video cannot be downloaded - #441
Merged
Merged
Conversation
A failed download only said "New project → Upload" in text, and Retry was the
only action, though it cannot get past an age-restricted, private or removed
video. The age-restricted reason was also picked by matching "age" anywhere in
yt-dlp's output, so a refused page ("Unable to download webpage: HTTP Error
403") was reported as age-restricted.
- ytdlp-errors: AGE_GATE / isAgeRestricted read from the fatal line; the bot
check no longer matches "Sign in to confirm your age".
- ingest: describeDownloadFailure picks the reason from the fatal line; every
download failure starts with one prefix, and uploadAvoids reads it back.
- projects: failure { cause, uploadInstead } on the project; the length lookup
refuses age-restricted, private or removed videos up front (UnusableSourceError,
which LiveSourceError now extends).
- web: the failure banner leads with Upload the file (/new?source=upload&title=)
and explains what Retry does; NewProject honours the new parameters.
- MCP and CLI: failure field and an upload hint; docs for YTDLP_COOKIES_FILE.
Signed-off-by: dillonstreator <dillonstreator@gmail.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
When a project's link can't be downloaded (blocked, age-restricted, private, removed, a live stream), the project page now leads with Upload the file. The button opens New project on the Upload tab with the project's title filled in (
/new?source=upload&title=…). Retry becomes the second button, and the note under the error says what each choice does. For failures where the same video would fail the same way again (cause: input), the note says so.The same information is available outside the web UI:
failure: { cause, uploadInstead }, which isnullunless the project failed.get_project,list_projectsandwait_for_projectreturn that field.get_projectandwait_for_projectalso add a hint to upload the file and pass theuploadIdtocreate_project.reelsaw statusprints the same advice.Bug fixed
describeDownloadFailurechose "age-restricted" by matching/age/iagainst all of yt-dlp's output, and "webpage" matches. So a refused page (Unable to download webpage: HTTP Error 403, a bot block) was reported to users as age-restricted.ERROR:line, the one it actually gave up on.AGE_GATE,isAgeRestricted).BOT_CHECKno longer matches "Sign in to confirm your age".content, so it stops instead of walking every exit.Caught before the project is created
When Reelsaw looks up a link's length (for accounts with a minutes limit, or when clipping ranges), an age-restricted, private or removed video is now refused by
check_sourceand at creation, with the same sentence as the download would give. This reuses the live-stream path:LiveSourceErrornow extends a newUnusableSourceError.Notes for review
uploadAvoidsrecognises a download failure from the stored error text. Every download failure now starts with one prefix ("Could not download"). Rows from before this change ("Download failed:") and the live-stream message are also recognised. Tests check that everydescribeDownloadFailureresult matches.failuregoes in the tool results as a hint rather than in theget_projectdescription.YTDLP_COOKIES_FILEdescription in CONFIG.md and both.env.examplefiles. The README line is updated.Testing
uploadAvoids. The yt-dlp, ingest, peek and MCP definition tests pass.pnpm lint,pnpm guards,docs:checkandi18n:check.failedscenario plus an age-restricted variant: the banner at desktop and phone widths, the Upload deep link, and thefailurefield fromprojects.get.