Skip to content

Commit

Permalink
Safety: use API key
Browse files Browse the repository at this point in the history
  • Loading branch information
inducer committed Jan 10, 2025
1 parent 06fe726 commit 3624c78
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 16 deletions.
36 changes: 20 additions & 16 deletions .ci/run-safety.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,23 @@
# 67599: pip issue, utter nonsense
# 70612: Jinja2 SSTI, as of https://github.com/inducer/relate/pull/1053
# there is no longer a direct Jinja dependency, and no known path to SSTI.
safety check \
-i 38678 \
-i 39253 \
-i 39535 \
-i 40291 \
-i 44715 \
-i 44716 \
-i 44717 \
-i 51159 \
-i 51549 \
-i 51499 \
-i 51457 \
-i 65213 \
-i 67599 \
-i 70612 \
--full-report
if test "$SAFETY_API_KEY" != ""; then
safety --stage cicd --key "$SAFETY_API_KEY" scan \
-i 38678 \
-i 39253 \
-i 39535 \
-i 40291 \
-i 44715 \
-i 44716 \
-i 44717 \
-i 51159 \
-i 51549 \
-i 51499 \
-i 51457 \
-i 65213 \
-i 67599 \
-i 70612 \
--full-report
else
echo ":warning::Skipped running safety, no API key."
fi
2 changes: 2 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ jobs:
run: poetry run ./.ci/run-mypy.sh
- name: "Safety"
run: poetry run ./.ci/run-safety.sh
env:
SAFETY_API_KEY: ${{ secrets.SAFETY_API_KEY }}
- name: "Sphinx"
run: |
(cd doc; poetry run make html SPHINXOPTS="-W --keep-going -n")
Expand Down

0 comments on commit 3624c78

Please sign in to comment.