Skip to content

Conversation

@YohayAiTe
Copy link
Contributor

Summary

  • This is a…
    • Bug fix
    • Feature addition
    • Refactoring
    • Minor / simple change (like a typo)
    • Other
  • Describe this change in 1-2 sentences:

Problem

When saving an ID3 file with LRC synced lyrics, it only accepted a very narrow definition of timestamps (two-digit minutes, two-digit seconds, and three-digit milliseconds). While this is fine for preserving the field (as in PICARD-1092), some plugins may import or download LRCs with different timestamps, and people can edit the field manually and change as well.

No JIRA ticket was open for this problem, and there was no LRC support at all in the previous release.

Solution

I changed the regular expressions that are used for LRC decoding (ID3File.__lrc_*_re_parse), and the corresponding timestamp parsing at ID3File._parse_lrc_text. I also added new test cases for the new timestamps.

Action

Additional actions required:

  • Update Picard documentation (please include a reference to this PR)
  • Other (please specify below)

Copy link
Member

@phw phw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks a lot for this fix. Looks good to me

@phw phw enabled auto-merge (squash) December 29, 2024 11:04
auto-merge was automatically disabled December 29, 2024 11:10

Head branch was pushed to by a user without write access

@phw phw enabled auto-merge (squash) December 29, 2024 11:16
@YohayAiTe YohayAiTe requested a review from phw December 29, 2024 11:19
Copy link
Member

@phw phw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks again

@phw phw merged commit 241aa66 into metabrainz:master Dec 29, 2024
43 checks passed
@YohayAiTe YohayAiTe deleted the support_more_lrc_timestamps branch December 29, 2024 11:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants