From 4f7425086ebacd3ff80e115e3f3bf218d8a84698 Mon Sep 17 00:00:00 2001 From: Harry Kim Date: Wed, 5 Nov 2025 19:32:00 -0800 Subject: [PATCH] New: Parse 'F1RST' releases as Korean --- .../ParserTests/MiniSeriesEpisodeParserFixture.cs | 3 +++ src/NzbDrone.Core/Parser/ParserCommon.cs | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/NzbDrone.Core.Test/ParserTests/MiniSeriesEpisodeParserFixture.cs b/src/NzbDrone.Core.Test/ParserTests/MiniSeriesEpisodeParserFixture.cs index b91e49415..de4eb92a2 100644 --- a/src/NzbDrone.Core.Test/ParserTests/MiniSeriesEpisodeParserFixture.cs +++ b/src/NzbDrone.Core.Test/ParserTests/MiniSeriesEpisodeParserFixture.cs @@ -31,6 +31,9 @@ namespace NzbDrone.Core.Test.ParserTests [TestCase("My Only Series Title.E37.190120.1080p-NEXT.mp4", "My Only Series Title", 37, "2019-01-20")] [TestCase("Series.E191.190121.720p-NEXT.mp4", "Series", 191, "2019-01-21")] [TestCase("The Series Title Challenge.E932.190120.720p-NEXT.mp4", "The Series Title Challenge", 932, "2019-01-20")] + [TestCase("백번의 추억.E12.251019.1080p-F1RST", "백번의 추억", 12, "2025-01-19")] + [TestCase("나는 SOLO <나는 솔로>.E223.251015.1080p-F1RST", "나는 SOLO 나는 솔로", 223, "2025-10-15")] + [TestCase("나는 SOLO 그 후, 사랑은 계속된다(나솔사계).E135.251016.1080p-F1RST", "나는 SOLO 그 후, 사랑은 계속된다(나솔사계)", 135, "2025-10-16")] // [TestCase("", "", 0, "")] public void should_parse_korean_series_episode(string postTitle, string title, int episodeNumber, string airdate) diff --git a/src/NzbDrone.Core/Parser/ParserCommon.cs b/src/NzbDrone.Core/Parser/ParserCommon.cs index 4e3b56f3c..3166a7916 100644 --- a/src/NzbDrone.Core/Parser/ParserCommon.cs +++ b/src/NzbDrone.Core/Parser/ParserCommon.cs @@ -9,7 +9,7 @@ internal static class ParserCommon internal static readonly RegexReplace[] PreSubstitutionRegex = new[] { // Korean series without season number, replace with S01Exxx and remove airdate - new RegexReplace(@"\.E(\d{2,4})\.\d{6}\.(.*-NEXT)$", ".S01E$1.$2", RegexOptions.Compiled), + new RegexReplace(@"\.E(\d{2,4})\.\d{6}\.(.*-(F1RST|NEXT))$", ".S01E$1.$2", RegexOptions.Compiled), // Some Chinese anime releases contain both English and Chinese titles, remove the Chinese title and replace with normal anime pattern new RegexReplace(@"^\[(?:(?[^\]]+?)(?:[\u4E00-\u9FCC]+)?)\]\[(?[^\]]+?)(?:\s(?<chinesetitle>[\u4E00-\u9FCC][^\]]*?))\]\[(?:(?:[\u4E00-\u9FCC]+?)?(?<episode>\d{1,4})(?:[\u4E00-\u9FCC]+?)?)\]", "[${subgroup}] ${title} - ${episode} - ", RegexOptions.Compiled),