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

fix(general): Custom Policies integration must run before Suppresion integration #3701

Merged
merged 6 commits into from
Oct 20, 2022
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

class CustomPoliciesIntegration(BaseIntegrationFeature):
def __init__(self, bc_integration: BcPlatformIntegration) -> None:
super().__init__(bc_integration=bc_integration, order=1) # must be after policy metadata
super().__init__(bc_integration=bc_integration, order=1) # must be after policy metadata and before suppression integration
self.platform_policy_parser = NXGraphCheckParser()
self.policies_url = f"{self.bc_integration.api_url}/api/v1/policies/table/data"
self.bc_cloned_checks: dict[str, list[dict[str, Any]]] = defaultdict(list)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

class SuppressionsIntegration(BaseIntegrationFeature):
def __init__(self, bc_integration: BcPlatformIntegration) -> None:
super().__init__(bc_integration=bc_integration, order=1) # must be after the policy metadata
super().__init__(bc_integration=bc_integration, order=2) # must be after the custom policies integration
self.suppressions: dict[str, list[dict[str, Any]]] = {}
self.suppressions_url = f"{self.bc_integration.api_url}/api/v1/suppressions"

Expand Down