Skip to content

Commit

Permalink
Merge pull request #472 from camptocamp/fix
Browse files Browse the repository at this point in the history
Audi: No error then there is no fixable vulnerabilities
  • Loading branch information
sbrunner authored Aug 8, 2024
2 parents 9687f1c + 7121647 commit c62067b
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 3 additions & 1 deletion github_app_geo_project/module/audit/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,9 @@ async def snyk(
if npm_audit_fix_message:
assert isinstance(fix_message, module_utils.HtmlMessage)
fix_message.html = f"{fix_message.html}<br>\n<br>\n{npm_audit_fix_message}"
fix_success = snyk_fix_success and npm_audit_fix_success
fix_success = (
True if len(fixable_vulnerabilities_summary) == 0 else (snyk_fix_success and npm_audit_fix_success)
)

diff_proc = subprocess.run( # nosec # pylint: disable=subprocess-run-check
["git", "diff", "--quiet"], timeout=30
Expand Down
3 changes: 2 additions & 1 deletion github_app_geo_project/module/standard/changelog.py
Original file line number Diff line number Diff line change
Expand Up @@ -489,7 +489,8 @@ def get_actions(self, context: module.GetActionContext) -> list[module.Action[di
)
and event_data.get("pull_request", {}).get("state") == "closed"
and event_data.get("pull_request", {}).get("milestone")
and event_data.get("sender", {}).get("login") != context.github_application.name + "[bot]"
and event_data.get("sender", {}).get("login")
!= context.github_application.integration.get_app().slug + "[bot]"
):
return [module.Action(priority=module.PRIORITY_CRON, data={"type": "pull_request"})]
if event_data.get("action") == "edited" and "milestone" in event_data:
Expand Down

0 comments on commit c62067b

Please sign in to comment.