Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose changes made to create a comon data type implementation that can be shared across projects #341

Closed
wants to merge 6 commits into from

Conversation

david-waltermire
Copy link
Collaborator

Committer Notes

This feature branch is extracting all schema changes made in develop that relate to the schema folder.

All Submissions:

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  • Have you squashed any non-relevant commits and commit messages? [instructions]
  • Do all automated CI/CD checks pass?

Changes to Core Features:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your core changes, as applicable?
  • Have you included examples of how to use your new feature(s)?
  • Have you updated all website](https://pages.nist.gov/metaschema) and readme documentation affected by the changes you made? Changes to the website can be made in the website/content directory of your branch.

david-waltermire and others added 6 commits March 29, 2023 16:47
* Relocate schema resources (#191)

- Moved schema resources out of XSLT implementation
- Relocated XSD and datatype XML schemas.
Removed junk and generated files.
Many datatype adjustments
   - Tweeks to schema data types to address unicode issues. Resolves usnistgov/OSCAL#1127. Resolves usnistgov/OSCAL#956.
   - Adjusted type names of Metaschema types to be purely hyphenated.
   - Removed extra character ranges that are causing C# problems. Resolves usnistgov/OSCAL#1127.
- Adjusted URI data type names to be more consistent between XML and JSON.
Many metaschema.xsd adjustments
- Alignment of data types used with new Metschema datatype names.
- Additional repairs of tests, including naming consistency.
   - adding new unit test for a valid json-value key using a label
   - many fixes to broken tests
   - Removed duplicate uuid test scenario.
   - Many fixes to make unit test Metaschemas valid.
- Added JSON schema schema.
- Some schema generation refactoring to support new data-driven test harness.

* Fixed URI of choice unit test.

* Update metaschema-datatypes.xsd

Adjusting whitespace handling for URI types.

* adding leading and trailing whitespace checks to all XML schema datatype derived types

* Adjustments to debug charstrings.

* Update metaschema-datatypes.json

Minor adjustments to data types for comments on #1260.

* refactored metaschema schema to support external constraint definitions

* Added constraint extensibility configuration.

* added formal-name and description to definition references

* XSLT M4 Metaschema pipeline updates (#214)

* Composition unit tests now valid to updated schemas; added (missing) tests.

* Adding XSpec for schema generation; nominal schema target examples

* Adding XSpec tests (testing schema generation as transforms) and initial set of targets for testing

* Major reorganization and archiving (some temporary, prior to defenestration); new tests; readme documents in each folder for schema-generation unit tests to help trace efforts
* More details in json-value-key readme; updated top-level JSON schema generation xspec
* Metaschema Schematron rule intercepting a json-key setting with no BY_KEY in the grouping logic
* Cleaned up extra JSON Schema file
* Updated metaschema model wrt json-key, json-value-key flag-ref (no longer flag-name); other Metaschema touchups
* Rewiring and simplifying XSD production pipeline with datatypes now acquired from the normative metaschema /schema subdirectory - removed the namespace fixup step, no longer needed.
* Updated anthology ('menagerie') metaschema example, with cleanup
* In XSD generation, now emitting datatype definitions only for datatypes actually needed by a schema
* Updating schema TODO notes on synching unit tests; bit of cleanup
* Addressing #212 - XML to JSON converter no longer chokes on edge cases (array items of SINGLETON_OR_ARRAY groups)
* Updating top-level composition unit tests
* .gitignore covering HTML reports from test runs
* Removing outdated testing results
* Adding back support for old datatype names as indicated in metaschema.xsd (cf line 1252)
* Restoring deprecated datatypes per #195
* Bit of cleanup; utility maintenance
* Removing 'INFO' level comment in XSD
* Tweakage to align XSD out (dropping comment; cleaning up namespaces)
* Patching hole in JSON datatype assignment also
* Emitting cleaner namespaces in XSD; slight refactoring of JSON Schema
* Adjusting JSON Schema type definitions to produce valid constraints over Metaschema atomic types
* Extending atomic data type acquisition to collect one level of indirect references
* Cleaning up obsolete datatype support
* Bit more cleanup; updated readme
* Adjusting handling of warnings and exception messages in pipelines
* Removing outdated artifacts from schema generation unit testing.md

Co-authored-by: Wendell Piez <[email protected]>
- Updated data types to ensure consistency between specification and implementation.
- Identify locations of data type schemas in data type specifications.
- Discuss use of regular expression dialects used in XML and JSON schema. #235
…the data type implementations restrict leading and trailing whitespace.
@aj-stein-nist
Copy link
Collaborator

Sorry for the delays. I was meant to review this sooner rather than later but got hung up on some blocker tasks that would not allow OSCAL to move forward with a merge if this feature branch works.

I will be testing this today and early next week urgently as discussed in the context of usnistgov/OSCAL#1703.

@david-waltermire
Copy link
Collaborator Author

Talked with @aj-stein-nist about this approach to integrating schema changes into main. This approach does not have the related XSLT changes, which breaks all of the production scripts. This makes approaching integrating schema changes from develop into main in this way a non-starter.

@aj-stein-nist
Copy link
Collaborator

Thanks for closing this, as discussed, this was based in an idea I had and it would have not worked to meet what we needed. I will go check out #343.

@david-waltermire david-waltermire deleted the feature-shared-data-type-schemas branch October 4, 2023 15:50
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.

2 participants