youtube videos list: request all non-owner parts by default (+ --parts flag)#871
youtube videos list: request all non-owner parts by default (+ --parts flag)#871coeur-de-loup wants to merge 1 commit into
Conversation
Extend 'yt videos list' so it fetches every videos.list part readable for arbitrary (non-owned) videos — snippet, contentDetails, statistics, status, topicDetails, recordingDetails, liveStreamingDetails, player, localizations — instead of only the previous 3 (snippet,contentDetails,statistics). A new --parts flag narrows the set when desired; the default is the full non-owner list. Owner-only parts (fileDetails/processingDetails/suggestions) are deliberately excluded — the API returns them only for the account's own uploads. The Google SDK omits parts with no data for a given video (e.g. liveStreamingDetails on a non-live video), so the broad request tolerates per-video partial responses without erroring. Tests assert the full part set is requested by default, --parts overrides it, non-core part fields (status.privacyStatus, topicDetails, all thumbnail sizes, liveStreamingDetails) survive in --json output, and a video missing optional parts still serializes cleanly.
|
Codex review: needs real behavior proof before merge. Reviewed June 27, 2026, 1:07 PM ET / 17:07 UTC. Summary Reproducibility: not applicable. this is a feature/default-change PR rather than a bug report. Source inspection confirms current main uses the three-part request and the PR changes omitted-flag behavior. Review metrics: 2 noteworthy metrics.
Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Rank-up moves:
Proof guidance:
Risk before merge
Maintainer options:
Next step before merge
Security Review findings
Review detailsBest possible solution: Preserve the existing three-part default unless maintainers intentionally approve broad-by-default; land a documented opt-in selector with redacted live YouTube proof. Do we have a high-confidence way to reproduce the issue? Not applicable: this is a feature/default-change PR rather than a bug report. Source inspection confirms current main uses the three-part request and the PR changes omitted-flag behavior. Is this the best way to solve the issue? No: the implementation is focused, but broad-by-default changes existing output and quota behavior without maintainer approval. The safer path is preserving the old default or getting an explicit maintainer decision plus docs and live proof. Full review comments:
Overall correctness: patch is incorrect AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 213ddb60d7d1. Label changesLabel justifications:
Evidence reviewedWhat I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
What
gog youtube videos listcurrently requests only three parts —snippet,contentDetails,statistics— so--jsonsilently drops everything else the API returns for a non-owned video.This makes the default request broad: every part readable for any non-owned video —
snippet, contentDetails, statistics, status, topicDetails, recordingDetails, liveStreamingDetails, player, localizations— and adds a--partsflag to narrow it back down (e.g.--parts snippet,statistics).Why
Tools that archive video metadata want lossless capture by default rather than having to enumerate parts. Default-broad + opt-in-narrow matches what read-only consumers generally expect.
Details
fileDetails,processingDetails,suggestions) are deliberately excluded from the default — the API 403s on them for videos the authenticated user doesn't own. They remain requestable via explicit--partsif you target your own uploads.liveStreamingDetailson a non-live video), so the broad request tolerates per-video partial responses without erroring.--parts snippet,contentDetails,statisticsfor the previous minimal behavior.Tests
Adds coverage for: the default requests exactly the nine non-owner parts (never the three owner-only ones);
--partsoverride narrows (incl. whitespace trimming); non-core fields (status.privacyStatus,topicDetails, all thumbnail sizes,liveStreamingDetails) survive into--json; and a video missing optional parts still serializes cleanly.🤖 Generated with Claude Code