itunes: support for lowercased episodeType values#48
Closed
liberlanco wants to merge 1 commit intoruby:masterfrom
Closed
itunes: support for lowercased episodeType values#48liberlanco wants to merge 1 commit intoruby:masterfrom
liberlanco wants to merge 1 commit intoruby:masterfrom
Conversation
Member
|
I can understand what you think but please disable validation for this case. (And please feedback this to fireside.fm if you want.) In general, feed readers parse feed loosely as much as possible because there are many broken feeds in the world and feed readers needs to process them as much as possible. |
kou
reviewed
May 25, 2024
| def #{name}=(new_value) | ||
| if @do_validate and | ||
| !["Full", "Trailer", "Bonus", nil].include?(new_value) | ||
| !["full", "trailer", "bonus", nil].include?(new_value.downcase) |
Member
There was a problem hiding this comment.
Could you accept only Full/full variants? (We don't want to accept FULL, fULL and so on.
Suggested change
| !["full", "trailer", "bonus", nil].include?(new_value.downcase) | |
| !["Full", "full", "Trailer", "trailer", "Bonus", "bonus", nil].include?(new_value) |
Member
|
Apple uses |
Member
|
Implemented by #53. |
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.
I met this issue with following RSS: https://feeds.fireside.fm/smartlogic/rss
They uses lowercase values for episodeType like 'trailer' or 'full'. I tried 2 different RSS readers with the URL and all of them read this feed without problems (liferea and some from flatpack, forget the name).
ruby/rss raises exception:
I also tried RSS validator, and it gave many errors but not about episodeType value: https://www.rssboard.org/rss-validator/check.cgi?url=https%3A%2F%2Ffeeds.fireside.fm%2Fsmartlogic%2Frss
Hence I understood that official specs defines Full, Trailer and Bonus as legal values for this XML tag, but looks like it's already common practice to use lowercase values (even validator doesn't think it's bad)
So here is the patch to support them + small test update with lowercase value