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

--only-policy option doesn't check policy existence #334

Closed
gmontard opened this issue Jan 5, 2023 · 1 comment · Fixed by #345
Closed

--only-policy option doesn't check policy existence #334

gmontard opened this issue Jan 5, 2023 · 1 comment · Fixed by #345
Assignees
Labels
bug Something isn't working

Comments

@gmontard
Copy link
Contributor

gmontard commented Jan 5, 2023

Description

Running --only-policy (or --skip-policy) doesn't check if the policy IDs exist, leading to bad UX and misleading output.

Expected Behavior

Throw an error if using a policy ID that doesn't exist

Actual Behavior

Fail silently

Possible Fix

Check if policy IDs exist first

Steps to Reproduce

  1. curio scan . --only-policy CR-000
  2. curio scan . --skip-policy CR-000

Your Environment

  • Version used: 0.21.1
  • Target codebase stack (e.g. Ruby): Ruby
  • Operating System and version: Mac
@gmontard gmontard added the bug Something isn't working label Jan 5, 2023
@cfabianski cfabianski changed the title --only-policy option doesn't check policy existence --only-policy option doesn't check policy existence Jan 5, 2023
@cfabianski
Copy link
Collaborator

This also applies to detectors (check the detector exists)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants