Skip to content

Handle reserved STmin values per ISO-15765-2 - #160

Draft
fallenmi wants to merge 1 commit into
pylessard:v2.xfrom
fallenmi:agent/fix-reserved-stmin
Draft

Handle reserved STmin values per ISO-15765-2#160
fallenmi wants to merge 1 commit into
pylessard:v2.xfrom
fallenmi:agent/fix-reserved-stmin

Conversation

@fallenmi

Copy link
Copy Markdown

Summary

  • treat reserved FlowControl STmin bytes as 0x7F instead of discarding the frame
  • keep stmin and stmin_sec normalized to the same effective 127 ms value
  • cover both reserved ranges and the valid 0x7F / 0xF9 endpoints

Fixes #147.

Why

ISO 15765-2 requires reserved STmin values to be treated as 0x7F. The current parser raises ValueError, which causes the transport layer to discard an otherwise valid FlowControl frame.

Testing

  • python3 -m unittest test.test_helper_classes.TestPDUDecoding.test_decode_flow_control
  • python3 -m unittest test.test_helper_classes — 9 tests passed
  • python3 -m unittest — 164 tests run, 31 platform-specific skips
  • exhaustive probes for all 256 STmin byte values and transport-layer timing/override behavior

AI disclosure

This pull request was prepared with OpenAI Codex. Codex reproduced the issue, implemented the code and tests, audited visible upstream and fork overlap, and ran the validation listed above. This remains a Draft for the account owner's review.

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.

Error raised on invalid STmin value rather than using maximum default required in specification resulting in frame destruction

1 participant