Skip to content

horiba_pentra_xlr: widen report_type to accept 'I' and fix CommentRecord.source tuple syntax#75

Merged
ramonski merged 1 commit into
2.xfrom
fix-pentra-xlr-set-tuples
Jun 3, 2026
Merged

horiba_pentra_xlr: widen report_type to accept 'I' and fix CommentRecord.source tuple syntax#75
ramonski merged 1 commit into
2.xfrom
fix-pentra-xlr-set-tuples

Conversation

@ramonski

@ramonski ramonski commented Jun 2, 2026

Copy link
Copy Markdown
Contributor

Description of the issue/feature this PR addresses

Audit of horiba_pentra_xlr against the Horiba Pentra XLR ASTM interface manual surfaced two small schema issues in the Order and Comment records.

Current behavior before PR

  • OrderRecord.report_type is a SetField(values=("F", "C")). Spec 9.4.26 (Note 4) also lists I (Result unvalidated, used when unconditional validation is off). I is logged as unexpected at parse time.
  • CommentRecord.source is declared SetField(values=("I")). Because ("I") is a string, not a tuple, the SetField allow-list silently becomes set('I') — equivalent to a one-element tuple by accident, but semantically wrong and easy to break when a second value is added.

Desired behavior after PR is merged

  • OrderRecord.report_type accepts ('F', 'C', 'I').
  • CommentRecord.source uses values=('I',) so the allow-list is unambiguous.

@ramonski ramonski force-pushed the fix-pentra-xlr-set-tuples branch from 14dceef to db004f8 Compare June 3, 2026 10:12
@ramonski ramonski force-pushed the fix-pentra-xlr-set-tuples branch from db004f8 to 0ba6702 Compare June 3, 2026 10:36
@ramonski ramonski merged commit 7c77dc5 into 2.x Jun 3, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant