Skip to content
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

fix /api/v1/videos/:id returns 200 with no content #5162

Merged
merged 1 commit into from
Feb 26, 2025

Conversation

Drikanis
Copy link
Contributor

@Drikanis Drikanis commented Jan 29, 2025

fixes #5161 by checking recommended videos published field for presence before attempting to parse it in api

Tested by checking random videos on /api/v1/videos/. Where a request would normally fail it now correctly returns an empty published field on an offending recommended video.

http get https://invidious.lab/api/v1/videos/Cxjn16rNd0k | jq .recommendedVideos[].published
"2024-02-29T02:43:22Z"
"2025-01-26T02:43:22Z"
"2025-01-28T02:43:22Z"
"2025-01-28T14:43:22Z"
"2025-01-28T21:43:22Z"
"2024-12-29T02:43:22Z"
"2024-02-29T02:43:22Z"
"2024-12-29T02:43:22Z"
""
"2024-01-29T02:43:22Z"
"2024-05-29T02:43:22Z"
"2025-01-28T22:43:22Z"
"2024-01-29T02:43:22Z"
"2025-01-28T22:43:22Z"
"2025-01-28T16:43:22Z"
"2025-01-28T20:43:22Z"
"2025-01-15T02:43:22Z"
"2025-01-15T02:43:22Z"
"2025-01-26T02:43:22Z"
"2021-01-29T02:43:22Z"

@Drikanis Drikanis requested a review from a team as a code owner January 29, 2025 02:42
@Drikanis Drikanis requested review from SamantazFox and removed request for a team January 29, 2025 02:42
@unixfox unixfox changed the title fix #5161 fix /api/v1/videos/:id returns 200 with no content Feb 3, 2025
@syeopite syeopite merged commit 6ac74f4 into iv-org:master Feb 26, 2025
7 of 8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] /api/v1/videos/:id returns 200 with no content, throws exception in logs
2 participants