Allow space as a date-time separator in Util.parseXsDateTime
#2868
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.
The
XS_DATE_TIME_PATTERNinUtil.javawas previously limited to parsing ISO 8601 date-times that use a literal 'T' or 't' as the separator between the date and time components.However, some content providers and metadata sources use a space character as the separator (e.g., "2025-10-28 12:09:41.913000+00:00"). This caused
Util.parseXsDateTimeto fail when parsing these valid, albeit non-standard, date-time strings, leading to potential parsing errors for certain media streams.This commit updates the regular expression by adding a space to the character class
[Tt], making it[Tt ]. This change extends parsing support to include date-times with a space separator while maintaining full compatibility with the standard 'T'/'t' separators.