-
Notifications
You must be signed in to change notification settings - Fork 23
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(generate): component generation fixed for many catalogs #573
Conversation
I tried with the basic-catalog and got the following
Is that expected? Seems like the basic catalog isn't providing some required data for the component-definition to be properly constructed (the error seems to indicate it's missing |
That error is indicating a problem writing to a file - and given that a validation error is occurring - is there any chance you attempted to write this output (possibly the default file output) to a pre-existing and non-valid file? |
Ok yep I went back and reviewed the commands I used -
Which output a
Which tries to write to the same component-definition, but I guess is hitting that error that the file is invalid? Which is sort of weird because it was written the first time around... Definitely an edge case, but looks like the initial command output an invalid file or something. |
Agreed - I'll look at fixing some of this behavior. |
@meganwolf0 We now verify that at least one control was identified before the creation of the file otherwise producing an error that no controls could be found. This should prevent the issue you saw before. |
Description
This fixes a nil pointer dereference error caught while testing the fedramp catalog generation.
This also includes much better depth of control enumeration given how groups and controls can be potentially nested in catalogs.
Testing Targets
Outside of the unit testing for generation functionality - catalogs that can be used for testing:
Related Issue
Fixes #571
Type of change
Checklist before merging