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

XML/JSON converter generator adjustments #176

Merged

Conversation

wendellpiez
Copy link
Collaborator

@wendellpiez wendellpiez commented Sep 27, 2021

These address #174 and #175.

Changes:

  • JSON-to-XML converter now supports (optional) $json stylesheet (runtime) parameter, so the JSON can be passed in directly as a literal data stream. $file is still available (designating a file path). If both are provided, $json is used in preference, unless it is an empty string, in which case $file is examined.
  • Also repaired a nuisance bug reported by user @vikas-agarwal76 a few weeks ago (thanks!) - in addition to confusing docs (we repaired in Improvements to converter readme docs OSCAL#1027), a spurious warning message was produced due to a preventable template clash.

Committer Notes

Several improvements were made to the runtime interfaces for both converters (JSON/XML), without changing syntax -- better error messages, no spurious errors under SaxonC etc. (Thanks also to @danielnaab for contribution.) Operationally, nothing should change.

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.

…time interfaces of generated JSON and XML converters
…late priority setting to intervene over template clashes usnistgov#174
…p expressed multiply); tests; refinement of path matching to distinguish between flag matches signaled by 'attribute::' axis, vs field or assembly matches via 'child::' (or implicit) axis. With tests over current OSCAL SSP model.
@wendellpiez wendellpiez marked this pull request as ready for review November 15, 2021 15:46
@wendellpiez wendellpiez linked an issue Nov 16, 2021 that may be closed by this pull request
3 tasks
Copy link
Collaborator

@david-waltermire david-waltermire left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@david-waltermire david-waltermire merged commit c1aacf9 into usnistgov:master Nov 17, 2021
@wendellpiez wendellpiez mentioned this pull request Nov 17, 2021
8 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants