Interim fix: recognize M4A/AAC as valid encoding type, warn content validation unsupported#1637
Open
jordanpadams wants to merge 1 commit into
Open
Interim fix: recognize M4A/AAC as valid encoding type, warn content validation unsupported#1637jordanpadams wants to merge 1 commit into
jordanpadams wants to merge 1 commit into
Conversation
…nt validation unsupported (#1635) - Add M4A/AAC to EncodingMimeMapping so it no longer throws IllegalArgumentException - Replace internal error with a WARNING that content validation is not yet supported - Add new ProblemType CONTENT_VALIDATION_UNSUPPORTED for clear reporting - Add Cucumber test in 4.2.x.feature Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
nutjob4life
reviewed
Jul 3, 2026
| GIF(Arrays.asList("gif")), | ||
| J2C(Arrays.asList("j2c", "jp2", "mj2", "mjp2")), | ||
| JPEG(Arrays.asList("jpg", "jpeg")), | ||
| M4A(Arrays.asList("m4a")), |
Member
There was a problem hiding this comment.
M4A files often have the extension .aac so should this be M4A(Arrays.asList("m4a", "aac")),?
Also, since AAC is the codec and M4A is the container, would the enum be better off known as M4A_AAC (similar to the string detected later, line 38, as M4A/AAC)?
nutjob4life
approved these changes
Jul 3, 2026
nutjob4life
left a comment
Member
There was a problem hiding this comment.
This looks fine to me. I left one interspersed comment which can be ignored.
Approval: ✅
Maven details:
[INFO] Tests run: 323, Failures: 0, Errors: 0, Skipped: 302
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 26.117 s
[INFO] Finished at: 2026-07-02T20:09:49-05:00
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.



Summary
Fixes #1635. M4A/AAC is a valid
encoding_standard_idper PDS4 standards, but validate was throwingERROR [error.validation.internal_error]because the encoding type was not recognized. This interim fix:M4A/AACtoEncodingMimeMapping(mapped to newM4Aentry with.m4aextension), eliminating theIllegalArgumentExceptionthat was surfacing as an internal errorcheckMetadatacall in theM4A/AACcontent validation branch with aWARNING(warning.validation.content_validation_not_yet_supported) advising users that content validation for M4A/AAC is not yet supported and to consult PDS4 expertsProblemType.CONTENT_VALIDATION_UNSUPPORTEDfor clear, consistent reporting4.2.x.featureverifying exactly 1 warning and no errorsFull content validation for M4A/AAC is tracked in a follow-on requirement issue.
Test plan
mvn test -Dtest=\!ReferenceIntegrityTest* "-Dcucumber.filter.name=NASA-PDS/validate#1635-1"passes (1 scenario, 3 steps)mvn compileclean🤖 Generated with Claude Code