Skip to content

Reapply "Merge pull request #40 from snyk/feat(reachability)/pass-loc… #44

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

paulrosca-snyk
Copy link
Contributor

…al-policy-to-test"

This reverts commit d96f1f4.

Copy link

snyk-io bot commented Aug 4, 2025

🎉 Snyk checks have passed. No issues have been found so far.

security/snyk check is complete. No issues have been found. (View Details)

license/snyk check is complete. No issues have been found. (View Details)

code/snyk check is complete. No issues have been found. (View Details)

@paulrosca-snyk paulrosca-snyk force-pushed the feat/rechability-local-policy branch from f2d6bb5 to ae9e382 Compare August 4, 2025 14:38
@paulrosca-snyk paulrosca-snyk force-pushed the feat/rechability-local-policy branch from ae9e382 to fde4e5d Compare August 4, 2025 14:49
@paulrosca-snyk paulrosca-snyk marked this pull request as ready for review August 4, 2025 14:57
@paulrosca-snyk paulrosca-snyk requested review from cmars and a team as code owners August 4, 2025 14:57
return nil, errFactory.NewFeatureNotPermittedError(FeatureFlagRiskScore)
}
return nil, errFactory.NewFeatureNotPermittedError(FeatureFlagRiskScoreInCLI)
}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Feature Flag Validation Scope Error

Moving the risk score feature flag validation from setupDefaultTestFlow to OSWorkflow introduced two bugs:

  1. The validation now incorrectly applies to the SBOM reachability flow, causing feature flag errors despite SBOM not using risk score thresholds.
  2. The moved logic in OSWorkflow references undefined variables (riskScoreThreshold, riskScoreFFsEnabled, ffRiskScore), which were not re-declared in the new scope.
Fix in Cursor Fix in Web

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. The validation should apply to the SBOM flow as well if the user provides the --risk-score-threshold.
  2. The variables are declared a few lines above.

Copy link
Contributor

@bsalomon-snyk bsalomon-snyk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm with followup question

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants