Repository navigation
fix: support profile filtering in plan command - #713
Merged
Merged
Conversation
Assisted-by: Cursor:Claude-Opus-5.5 Signed-off-by: Johnson Lyu <cl7084@nyu.edu>
Marc-cn
approved these changes
Nov 4, 2026
Marc-cn
left a comment
Collaborator
There was a problem hiding this comment.
Mirrors audit --profile exactly (_resolve_profile_ids, intersection with --include, error when nothing is left), and removes the #568 refusal that #597 made obsolete. Checked on the VM against main: plan --profile level1_quick lists the 26 level-1 controls and filters 40; --profile access_control --include OSPS-BR-01.01 exits 1 with the no-overlap error; tests/darnit/test_cli.py + config 665 passed, ruff clean. One side note, not this PR: the access_control profile references three controls that don't exist (OSPS-AC-01.02, 01.03, 02.02).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #709.
darnit plan --profileby reusing the existing profile resolution logic fromaudit.--include,--exclude, and--tags, with consistent error handling for invalid or empty selections.Type of Change
Framework Changes Checklist
If this PR modifies the darnit framework (
packages/darnit/):docs/architecture/framework-design.md) if behavior changeduv run python scripts/validate_sync.py --verboseand it passesControl/TOML Changes Checklist
If this PR modifies controls or TOML configuration:
Testing
uv run pytest tests/ -v)uv run ruff check .)Focused CLI tests: 62 passed.
Framework sync validation and
git diff --checkpassed.AI assistance
Cursor (Claude Opus 5.5) assisted with implementation and regression tests. Changes were reviewed and validated locally.
Additional Notes
The broader non-integration test run on Windows reported 4,594 passed, 127 failed, 66 errors, and 18 skipped. Failures include platform-specific issues involving POSIX permissions, symlinks, shell commands, path separators, and text encoding. The full suite has not passed locally, and some failures remain uninvestigated.
No control definitions or TOML configuration files were modified.