Repository navigation
Fixing 8.5.0 going from prerelease to release - #1465
Merged
Merged
Conversation
…tandard#1464) SchemaLoaderJSON._check_is_schema_json runs before the header is read: a root that is not an object, or an object without a version key, raises HedFileError INVALID_HED_FORMAT naming the file and its top-level keys. Before, hed-schemas schema_versions.json failed as SCHEMA_HEADER_INVALID "Unknown attribute generated found in header line", and an array or a bare string raised AttributeError. A file with version but no tags still loads as before; making that SCHEMA_SECTION_MISSING is a separate issue. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…tests - hed/schema/schema_data/HED8.5.0.xml is the released schema, byte-identical to hed-schemas standard_schema/hedxml/HED8.5.0.xml. - Tests that expected SCHEMA_PRERELEASE_VERSION_USED for 8.5.0 or its partners now expect none; the warning fixture uses version 99.0.0 so no release retires it. CLI examples name 8.6.0 as the prerelease. - test_saving_default_schemas reloads the TSV round trip with the same xml_folder as the original: the vendored hed-tests HED8.5.0.xml is a prerelease snapshot without the 44 hedIds the release assigned, so the partner must come from one place. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
Static review found no blocking issues in these focused changes; tests were not executed.
0 open findings
What changed in this PR
Updates tests and CLI examples for HED 8.5.0's release and improves rejection of JSON inputs that are not HED schemas.
Changes:
- Adjusts release-sensitive expectations and schema fixtures.
- Adds JSON format checks and regression tests.
- Updates prerelease CLI examples to 8.6.0.
| File | Description |
|---|---|
| tests/scripts/test_script_util.py | Uses a compliant schema with a future version for warning tests. |
| tests/schema/test_schema_compliance.py | Removes obsolete 8.5.0 prerelease warning expectations. |
| tests/schema/test_json_not_a_schema.py | Tests invalid JSON inputs and valid schema loading. |
| tests/schema/test_hed_schema_io_df.py | Preserves fixture partner selection during round trips. |
| hed/schema/schema_io/json2schema.py | Rejects non-object roots and missing version keys. |
| hed/cli/cli.py | Updates help examples to prerelease 8.6.0. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
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.
No description provided.