Skip to content

Commit

Permalink
fix: run semgrep in rye
Browse files Browse the repository at this point in the history
  • Loading branch information
mbalunovic committed Jun 28, 2024
1 parent 4ceaa51 commit 54b4afb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion invariant/runtime/utils/code.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ def detect_all(self, code: str, lang: str) -> list[CodeIssue]:
else:
raise ValueError(f"Unsupported language: {lang}")

cmd = ["semgrep", "scan", "--json", "--config", config, "--metrics", "off", "--quiet", temp_file]
cmd = ["rye", "run", "semgrep", "scan", "--json", "--config", config, "--metrics", "off", "--quiet", temp_file]
out = subprocess.run(cmd, capture_output=True)
semgrep_res = json.loads(out.stdout.decode("utf-8"))
issues = []
Expand Down

0 comments on commit 54b4afb

Please sign in to comment.