Make sure description isn't null when extracting chapters from description#7505
Conversation
absidue
left a comment
There was a problem hiding this comment.
Before we do a fix to just make the error go away, we should check that the description is actually completely missing in those responses or whether it has been moved to somewhere else in the response structure, in which case we should extract it from the new location. My suspicion is that it is the latter (yt-dlp has had reports recently about the translated title not being extracted, which sounds related) and an A/B test which would explain why it can't be reproduced consistently.
Unfortunately @efb4f5ff-1298-471a-8973-3d47447115dc wasn't able to reproduce it with the devtools attached, so we currently only have the error message (in electron/chromium logs are captured all the time, requests and responses are only captured while devtools are open).
I'm not blocking this pull request entirely, I just want to be sure that this is the right fix. If we don't have an answer right before we do the next release, I am happy to approve it as-is so that users don't see the error.
|
I've caught the error again and shared the responses |
|
Looks like it has a placeholder (descriptionPlaceholder) saying that the description is empty now: {
"expandableVideoDescriptionBodyRenderer": {
"descriptionPlaceholder": {
"content": "No description has been added to this video.",
"styleRuns": [
{
"startIndex": 0,
"fontColor": 4284506208,
"italic": true
}
]
}
}
}, |
|
As it looks like the description is actually missing and it seems like YouTube is just switching how they handle videos without a description, I'll remove my block. |
04c62f8 to
87a48fd
Compare
* development: (214 commits) Translated using Weblate (Portuguese (Brazil)) Translated using Weblate (French) Translated using Weblate (French) add search filter reset button (FreeTubeApp#7531) ! Fix variant selection when no variant's audio role marked as main (FreeTubeApp#7571) Make sure description isn't null when extracting chapters from description (FreeTubeApp#7505) Translated using Weblate (French) Bump stefanzweifel/git-auto-commit-action from 5 to 6 (FreeTubeApp#7564) Translated using Weblate (Swedish) Bump the eslint group with 3 updates (FreeTubeApp#7567) Bump sass from 1.89.1 to 1.89.2 (FreeTubeApp#7565) Bump shaka-player from 4.14.15 to 4.14.18 (FreeTubeApp#7566) Bump postcss from 8.5.4 to 8.5.5 in the stylelint group (FreeTubeApp#7568) Bump electron-builder from 26.0.16 to 26.0.17 (FreeTubeApp#7569) Translated using Weblate (English (United Kingdom)) add beta to asset name (FreeTubeApp#7512) Translated using Weblate (Dutch) Translated using Weblate (Dutch) Fix builds failing due to broken Weblate keys (FreeTubeApp#7560) Translated using Weblate (Persian) ... # Conflicts: # package.json # src/renderer/helpers/api/local.js
…ption (FreeTubeApp#7505) * Make sure description isn't null when extracting chapters from description * set default value for description to empty string

Pull Request Type
Related issue
closes #7503
Description
result.basic_info.short_description and result.secondary_info.description.text are both nullable strings and for whatever reason both returned null from Rune's testing
Testing
Desktop