Filter non-watch YouTube Takeout activity - #494
Merged
karlicoss merged 1 commit intoJul 22, 2026
Conversation
AndrewSB
marked this pull request as ready for review
July 18, 2026 21:35
Contributor
Author
|
hey @karlicoss! this was done by AI, but I've validated the change after it's successfully parsed the youtube section of my takeout happy to make any edits you'd like |
Owner
|
Hey, thank you! Looks good :) |
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
www, and mobile hostsvparameter is present but blankWatchedRoot cause
The Takeout normalizer treated nearly every activity attributed to YouTube as watch history, then validated it with a literal
://www.youtube.com/watch?v=substring. Current Takeout data includes Shorts and non-watch YouTube activities, so valid Shorts raisedRuntimeErrorwhile unrelated activity was either raised as an error or silently counted as a watch.Impact
Consumers get a cleaner watch-history stream, including Shorts, without losing deleted/private-video placeholders.
Checks
uv run --group testing --with google-takeout-parser pytest -o addopts='' -q src/my/tests/youtube.py— 2 passeduv run --group testing ruff check src/my/youtube/takeout.py src/my/tests/youtube.py— passeduv run --group testing ruff format --check src/my/youtube/takeout.py src/my/tests/youtube.py— passedFull private Takeout audit using the parser fix from purarue/google_takeout_parser#95:
RuntimeErrorsThe aggregate proof report contains no personal event content. SHA-256:
74f560123787827dcb96e10bda2d1508d17656d85bbe47bbbf77c96583f47048.