File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 7171
7272 # 1) Strict scan: all tracked files except notebooks
7373 detect-secrets scan \
74- --exclude-files '*.ipynb' \
74+ --exclude-files '*\ .ipynb$ ' \
7575 > .secrets.strict.json
7676
77-
7877 - name : Fail if new secrets appear vs baseline
7978
8079 run : |
Original file line number Diff line number Diff line change 2222 hooks :
2323 - id : add-trailing-comma
2424- repo : https://github.com/ibm/detect-secrets.git
25- rev : 1f70358329b1f5dbe444df5c35c424b706bf8260
25+ rev : 0.13.1+ibm.62.dss
2626 hooks :
2727 - id : detect-secrets # pragma: whitelist secret
2828 # Add options for detect-secrets-hook binary. You can run `detect-secrets-hook --help` to list out all possible options.
Original file line number Diff line number Diff line change 1+
2+ # .semgrep.yaml
3+ # Goal: do not fail on torch.load(..)
4+
5+ rules :
6+
7+ - id : python.deserialization.pickle
8+
9+ # 👇 Exclude torch.load from this rule so it won't be reported as ERROR:
10+ pattern-not : |
11+ torch.load(...)
12+
13+ # --- record torch.load usage as INFO, non-blocking ---
14+ - id : python.deserialization.pytorch.torch-load
15+ message : " torch.load detected (accepted for trusted checkpoints). Prefer weights_only=True."
16+ languages : [python]
17+ severity : INFO
18+ pattern : |
19+
You can’t perform that action at this time.
0 commit comments