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

Fix missing type reference on generated attributes for flags #218

Conversation

david-waltermire
Copy link
Collaborator

Committer Notes

Fixed a bug caused when the SchemaGenerationFeature.INLINE_DEFINITIONS is enabled causing XML schema type references to not be produced for attributes associated with flags. This change restores the correct behavior by adding a type.isGeneratedType conditional check. Resolves usnistgov/liboscal-java#181.

This issue is difficult to test for, since it involves testing a specialized schema generation configuration. A new issue has been created to work on this.

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.

…S is enabled causing XML schema type references to not be produced for attributes associated with flags. This change restores the correct behavior by adding a type.isGeneratedType conditional check. Resolves usnistgov/liboscal-java#181.
@david-waltermire david-waltermire force-pushed the liboscal-java-issue181-fix-datatype-reference branch from e5337d5 to cafa864 Compare September 18, 2023 17:14
Copy link
Collaborator

@aj-stein-nist aj-stein-nist left a comment

Choose a reason for hiding this comment

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

Looks good to me.

I ran the example 0.12.1 cli generated schema command versus a local build with this patch off this branch with example model and schemas in this Gist and I am able to get inline types.

@david-waltermire david-waltermire merged commit 5e02200 into usnistgov:release-0.12 Sep 18, 2023
1 check passed
@david-waltermire david-waltermire deleted the liboscal-java-issue181-fix-datatype-reference branch September 18, 2023 17:30
aj-stein-nist added a commit to usnistgov/liboscal-java that referenced this pull request Sep 20, 2023
Update to upcoming metaschema-java release 0.12.2 to get updated XML schema generation type signature code from usnistgov/metaschema-java#218. Fixes #181.
aj-stein-nist added a commit to usnistgov/liboscal-java that referenced this pull request Sep 20, 2023
Update to upcoming metaschema-java release 0.12.2 to get updated XML schema generation type signature code from usnistgov/metaschema-java#218. Fixes #181.
aj-stein-nist added a commit to usnistgov/liboscal-java that referenced this pull request Sep 21, 2023
Update to upcoming metaschema-java release 0.12.2 to get updated XML schema generation type signature code from usnistgov/metaschema-java#218. Fixes #181.
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