Repository navigation
Download failures say which yt-dlp produced them - #134
Merged
Merged
Conversation
yt-dlp is frozen into the installer at build time, and Twitch, Kick and YouTube change things regularly. So a site change breaks one platform for every installed copy until the next release, and the failure says nothing about the version that hit it — which is the first thing needed to tell a changed site from a broken app. See ColinGPT9#39 and KNOWN-ISSUES.md. Every platform's download already passes through sources/dispatch.download, so the version travels with the failure from one place rather than three. What is added is chosen from the failure itself: yt-dlp's own words for a changed extractor ("unable to extract", "no video formats found", and the "confirm you are on the latest version" hint it prints with them) name the version and say a newer one may already have the fix, while a timeout or a sign-in wall get the version as context and no claim, because a newer yt-dlp would not have helped and pointing someone at one moves them further from the answer. Nothing is added to the failures the sources already explain in the app's own words (ValueError: an age-gated video, a deleted Kick VOD, a live stream) or to a cancellation, and the exception is re-raised rather than replaced, so every existing `except` still catches it and the traceback still points at the platform that failed. The note never echoes the failure text, so it cannot put back a cookie or a private URL that the job layer scrubs on the way out. This is the first of the three options in ColinGPT9#39: a reliable diagnostic, not an updater. The app still downloads and installs nothing, and no network check was added. Read through the same module server/feedback.py already uses, so it reports the bundled copy in an installed build and site-packages in a checkout, and "unknown" rather than a second exception if it cannot be read. Not verified against live YouTube, Twitch or Kick failures: no download is made here, and the source modules' own tests need yt_dlp, so they skip on CI. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com>
|
@chiragjangiir is attempting to deploy a commit to the Clips Studio Team on Vercel. A member of the Team first needs to authorize it. |
Owner
|
I will fix it in a couple of days |
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 this changes
A download that fails now names the yt-dlp that produced it, and adds that a
newer yt-dlp may already have the fix when the failure looks like the site
changing under the extractor.
Refs #39 — deliberately not
Fixes, see below.Why
yt-dlpis collected into the installer at build time (clips-studio.spec),while Twitch, Kick and YouTube change things regularly and yt-dlp fixes them
within days. So a site change breaks one platform for every installed copy
until the next release, and the failure itself says nothing about the version
that hit it. This is what a user gets today for an extractor break, captured
from
main:Nothing there identifies the copy in use, so "Kick stopped working" cannot be
triaged without asking for a Feedback Hub report, and a user has no way to know
the fix already exists upstream.
KNOWN-ISSUES.mdexplains the situation, butonly to someone who goes looking — the failure says nothing. #39 notes that
option 1 is worth doing regardless of the other two, and it is what this does.
Every platform's download already passes through one function
(
sources/dispatch.download), so the version travels with the failure from oneplace rather than three. The note reads from
yt_dlp.version.__version__atruntime — the same import
server/feedback.pyuses — so it reports the bundledcopy in an installed build, and nothing is hard-coded:
Only evidence of an extractor change gets that suggestion: yt-dlp's own wording
(
unable to extract,no video formats found,unsupported url,nsig extraction failed) plus theConfirm you are on the latest versionhintit prints with those errors. A timeout or a sign-in wall gets the version as
context and no claim, because a newer yt-dlp would not have helped and pointing
someone at one moves them further from the answer.
How you tested it
npm run typecheckpasses (inui/)None of the three apply: this touches no
ui/file, and it changes no clipping,tracking, caption or rendering behaviour. It was not run against a real video
because it does not need one — no download is made anywhere in the change or its
tests.
What was run, from the repository root:
pytest— no yt-dlp (the CIPythonjob's environment)pytest— with yt-dlp 2026.08.19 and defusedxmlpytest tests/test_ytdlp_failure_diagnostics.py— no yt-dlppytest tests/test_ytdlp_failure_diagnostics.py— with yt-dlpruff check .python -m compileall -q analysis core creator llm longform multilingual plugins publish sdk server sources sports transcription video video_editor main.pyThe two messages quoted above are real output, from the same probe run against
mainand against this branch with the platform downloader replaced by thefailure. No network request is made and no download happens in any test.
The new file follows the split already used in
tests/test_input_safety.py: theversion lookup and the wording live in
sources/ytdlp_common.py, which importswithout yt-dlp, so those run in the
Pythonjob. The four tests that need thesource modules sit behind
pytest.importorskip("yt_dlp"), so they skip there andrun wherever yt-dlp is installed.
Anything reviewers should know
produced the failure; the app still downloads and installs nothing, adds no
startup check, and makes no request for a version. That is why it is
Refs,not
Fixes.except DownloadError,except ValueErrorandexcept Exceptionall stillcatch it and the traceback still points at the platform that failed.
sources translate into plain English raises
ValueError(youtube._friendly_errors,kick._gone_or_raise: age-gated, deleted Kick VOD, live stream, wrong-platformlink), and cancellations are left alone. Appending a version to those reads as
noise, and on the live-stream and wrong-link ones it is not even relevant.
The trade-off: if a future source explained a failure with something other
than
ValueError, that failure would get a version line it does not need.extractor error worded differently falls through to the version-only note
rather than being guessed at. A test asserts that a timeout and both kinds of
sign-in wall are not told to update.
the failure text, so it cannot put a cookie, token or private URL back into a
message the job layer scrubs. There is a test for that.
server/jobs.pybroadcasts the first 500characters of a failure (2000 are stored). The note is appended, so a very
long upstream error could push it out of the live event. Prefixing instead
would cut the original reason, which seemed the worse trade.
reproduced; the classification is asserted against the wording yt-dlp is known
to use, which models the failure rather than being it. Worth keeping in mind if
a signature list needs widening later.
dispatch.downloadare annotated. Channel listing(
sources/channel_feed.py) and the split-setup probe(
sources/preview_frames.py) keep their current wording, since Bundled yt-dlp goes stale between releases, so a site change breaks every install #39 is aboutdownloads — say the word if you want those covered too.