wolfgangw / backports

Deep inspection of digital cinema packages
27 stars 12 forks source link

Spurious hints for (almost) any content of Language element in DCSubtitle #105

Closed matmat closed 8 months ago

matmat commented 8 months ago

I belive this is due to using [:alpha:] instead of [[:alpha:]] for the character class in the regex in: https://github.com/wolfgangw/backports/blob/922452767cf543487aba5a5a34f11e527d1e8045/dcp_inspect#L3118

Gives e.g. hints like these:

Hint: CPL 4731890a-64d5-46c1-8242-84c6e95b7caa: Reel 1: DCSubtitle ff0aead6-6a9a-4493-bdbb-3f822f236b05: Language content contains unexpected characters: "gr"
Hint: CPL c2e2448c-25eb-4731-8d75-7787cba1280d: Reel 1: DCSubtitle 8021ee8e-f8b5-4995-a9f8-15e345234eaa: Language content contains unexpected characters: "ro"
Hint: CPL 57100ad9-5ac8-4d7c-8676-745dff28f93e: Reel 1: DCSubtitle 4226e2b1-631f-4b63-8b51-6c2ad7b83c2e: Language content contains unexpected characters: "de"
Hint: CPL 82a25f1e-b73c-408a-906c-f3497d392be9: Reel 1: DCSubtitle eee92775-642d-4d2b-8fb1-c0cd649c0866: Language content contains unexpected characters: "en"
Hint: CPL 0a3cbaba-67eb-4ffe-951f-f00a9edf7f87: Reel 1: DCSubtitle 3268be26-6ec7-40fd-9330-03e0a194e5f1: Language content contains unexpected characters: "bg"
Hint: CPL e34dedc5-42ba-40ee-873b-72791c419544: Reel 1: DCSubtitle 6e151002-796a-4625-9d23-c9f778c2dbdb: Language content contains unexpected characters: "fr"

Made #101 attempting to fix this.

wolfgangw commented 8 months ago

Oh boy, now I get why my regexp license got revoked.

Thank you, Mattias. This one has been in there for a sporty 10 years. Thanks for the PR, I did it it a little differently, to clarify, though. See 0bcae0547e35e7040fd6532b0189b4d33feb576d

matmat commented 8 months ago

Thank you! Still got your Ruby license I hope! :)