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

Added special handling for Leaf Constructs #47

Merged
merged 2 commits into from
Mar 11, 2024
Merged

Conversation

ammokhov
Copy link
Contributor

@ammokhov ammokhov commented Mar 7, 2024

Issue #, if available:

Description of changes:

There are certain leaf level constructs - JSON native and CloudFormation specific.

  1. Adding constructs to a set of known keywords to be able to include it in the report.
  2. Previously it did not check if added nested keyword is a reserved name or not. If it is reserved but we did not check it would be accounted as a property, which is technically not correct.

Example:
previous schema

{
  "properties": {
    "Array": {
      "insertionOrder": true, ...
    }
  }
}

new schema

{
  "properties": {
    "Array": {
      ...
    }
  }
}

original diff:

{
  "properties": {
    "removed": ["/properties/Array/insertionOrder"]
  }
}

new diff:

{
  "insertionOrder": {
    "removed": ["/properties/Array"]
  }
}

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@ammokhov ammokhov self-assigned this Mar 7, 2024
@ammokhov ammokhov added the enhancement New feature or request label Mar 7, 2024
@ammokhov ammokhov merged commit 61b46bf into main Mar 11, 2024
3 checks passed
@ammokhov ammokhov deleted the cfn-leaf-level-constructs branch March 11, 2024 17:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants