Skip to content

Make ADC field validation errors deterministic #855

Done

Description

@tompollard

Problem

Writing sample-data/n8_evoked_raw_95_F1_R9 fails because of invalid ADC header fields, but the first reported field can be adc_zero or adc_res depending on PYTHONHASHSEED. The write-field validation in src/wfdb/io/_header.py iterates over a set, so its error order is not stable. This predates #851.

Expected behavior

Validate and report fields in specification order so the same invalid record produces the same error across runs. Add a test with multiple invalid fields that checks the reported order.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions