Fix parsing release group in Animebytes results (#11648) #11649
Merged
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.
Animebytes has changed their torrent
Property
string format. For ongoing series it contains an episode number as second to last segment, e.g.'Web|MKV|h264|720p|AAC2.0|Softsubs(SubsPlease)|Episode26|Freeleech'
.For finished series, the format is unchanged.
Provider's
parse()
removesFreeleech
segment from the split string, then expects to find the release group name in the last string of an array. This is not the case for ongoing series, where the last string represent an episode number. To find the actual release group name, last two strings should be checked.I intended to provide a test case to facilitate adapting this provider to any future changes of Animebytes data schema. Unfortunately, being unable to configure the authorized provider in the test suite I couldn't record a VCR cassette for the request. I asked more specific questions about providers initialization process in the project's Discord. If you could find some time to explain this mechanism to me, I can provide test coverage for this and other similar providers.