You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Validation returns incorrect failures when called with the -t flag, at least for -t system-security-plan when the model has been split using trestle split
To Reproduce
Steps to reproduce the behavior:
Create a new system-security-plan trestle create -t system-security-plan -o validate-test
Edit ssp to put a valid profile href in
Verify that trestle validate -f system-security-plans/validate-test/system-security-plan.json and trestle validate -t system-security-plan -n validate-test correctly report that the model is valid
Split the model: trestle split -f system-security-plans/validate-test/system-security-plan.json -e "system-security-plan.metadata"
Verify that trestle validate -f system-security-plans/validate-test/system-security-plan.json still reports that the model is valid
Try to validate with trestle validate -t system-security-plan -n validate-test
Expected behavior
The model is still valid
Actual behavior
Step 6 reports that the model has extra fields.
Screenshots / Logs.
Environment
OS: docker
Python version: 3.11
Installed packages: compliance-trestle 3.4.0
The text was updated successfully, but these errors were encountered:
It's popping that issue when assigning things to the pydantic.v1.main.SystemSecurityPlan stripped model, but I don't know why it's an issue for -t/-n and not for either -f or -a versions of the command.
Describe the bug
Validation returns incorrect failures when called with the
-t
flag, at least for-t system-security-plan
when the model has been split usingtrestle split
To Reproduce
Steps to reproduce the behavior:
trestle create -t system-security-plan -o validate-test
trestle validate -f system-security-plans/validate-test/system-security-plan.json
andtrestle validate -t system-security-plan -n validate-test
correctly report that the model is validtrestle split -f system-security-plans/validate-test/system-security-plan.json -e "system-security-plan.metadata"
trestle validate -f system-security-plans/validate-test/system-security-plan.json
still reports that the model is validtrestle validate -t system-security-plan -n validate-test
Expected behavior
The model is still valid
Actual behavior
Step 6 reports that the model has extra fields.
Screenshots / Logs.
Environment
The text was updated successfully, but these errors were encountered: