Skip to content

Commit

Permalink
lint: remove Safety checks (not open source anymore)
Browse files Browse the repository at this point in the history
Safety (https://github.com/pyupio/safety) has become a purely commercial
platform for all practical puposes. Versions < 3.0.1 are unsupported and have
grave configurability issues. Let's remove the dependency altogether.

See: #82 (comment)
  • Loading branch information
AldoGl committed Sep 6, 2024
1 parent fb2e2bb commit 2a2d3d0
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 157 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,4 @@ jobs:
run: tox -e check-copyright
- name: Misc checks
run: |
tox -e bandit,safety
tox -e bandit
1 change: 0 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@ We have various commands which are helpful during development.
```
make lint-all
make static
make safety
make bandit
```

Expand Down
6 changes: 1 addition & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ clean-test: ## remove test and coverage artifacts
rm -fr coverage.xml

.PHONY: lint-all
lint-all: black check-copyright ruff static bandit safety vulture darglint ## run all linters
lint-all: black check-copyright ruff static bandit vulture darglint ## run all linters

.PHONY: lint-all-files
lint-all-files: black-files ruff-files static-files bandit-files vulture-files darglint-files ## run all linters for specific files (specified with files="file1 file2 somedir ...")
Expand Down Expand Up @@ -130,10 +130,6 @@ bandit-files: ## run bandit for specific files (specified with files="file1 file
$(call check_defined, files)
bandit $(files)

.PHONY: safety
safety: ## run safety
safety check

.PHONY: vulture
vulture: ## run vulture
vulture black_it scripts/whitelists/package_whitelist.py
Expand Down
143 changes: 1 addition & 142 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ pytest = "^7.4.2"
pytest-cov = "^4.1.0"
pytest-randomly = "^3.15.0"
ruff = "^0.0.290"
safety = "^2.4.0b1"
tox = "^4.4.12"
twine = "^4.0.2"
vulture = "^2.9.1"
Expand Down
8 changes: 1 addition & 7 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tox]
isolated_build = True
envlist = bandit, safety, check-copyright, black-check, vulture, mypy, py3{8,9,10,11}, docs
envlist = bandit, check-copyright, black-check, vulture, mypy, py3{8,9,10,11}, docs

[tox:.package]
# note tox will use the same python version as under what tox is installed to package
Expand Down Expand Up @@ -79,12 +79,6 @@ skip_install = True
deps = bandit==1.7.5
commands = bandit --configfile .bandit.yaml --recursive black_it tests scripts examples

[testenv:safety]
skipsdist = False
skip_install = False
deps = safety==2.4.0b1
commands = safety check

[testenv:vulture]
skipsdist = True
skip_install = True
Expand Down

0 comments on commit 2a2d3d0

Please sign in to comment.