fix(skills): honor policy table for dangerous verdicts#1007
Open
stablegenius49 wants to merge 1 commit intoNousResearch:mainfrom
Open
fix(skills): honor policy table for dangerous verdicts#1007stablegenius49 wants to merge 1 commit intoNousResearch:mainfrom
stablegenius49 wants to merge 1 commit intoNousResearch:mainfrom
Conversation
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.
What does this PR do?
Fixes the skills guard install-policy precedence bug so the
INSTALL_POLICYtable actually controls dangerous verdict handling:builtinpolicy row instead of being hard-blocked before policy lookup--forcenow overrides blocked policy decisions fortrustedandcommunitysources, including dangerous verdicts/skills installnow accepts--yes/-yas an alias for--forceRelated Issue
Fixes #1006
Type of Change
Changes Made
tools/skills_guard.pydangerousverdicts before trust-policy evaluationINSTALL_POLICYdecide first, then let--forceoverride blocked decisionshermes_cli/skills_hub.py--yes/-yas aliases for--forcein/skills installhermes_cli/main.py--forcetests/tools/test_skills_guard.pytests/tools/test_force_dangerous_override.pyHow to Test
dangerous(for exampleofficial/email/agentmail) and confirm it is no longer blocked solely by the early return.trustedorcommunityskill with a blockeddangerousverdict is still blocked without--force, but installs when--forceis provided./skills install ... --yesbehaves the same as/skills install ... --force.Verification run in this environment
python3 -m py_compile hermes_cli/main.py hermes_cli/skills_hub.py tools/skills_guard.py tests/tools/test_skills_guard.py tests/tools/test_force_dangerous_override.pyofficial/... -> builtin/skills install ... --yessettingforce=Truerich,firecrawl,uv), so I left the full-suite checkbox unchecked instead of claiming otherwise.Checklist
Code
fix(scope):,feat(scope):, etc.)pytest tests/ -qand all tests passDocumentation & Housekeeping
docs/, docstrings) — or N/Acli-config.yaml.exampleif I added/changed config keys — or N/ACONTRIBUTING.mdorAGENTS.mdif I changed architecture or workflows — or N/A