Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop py36 support #672

Merged
merged 3 commits into from
Mar 28, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python: ['3.6', '3.7', '3.8', '3.9']
python: ['3.7', '3.8', '3.9']
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
python: ['3.6', '3.7', '3.8', '3.9']
python: ['3.7', '3.8', '3.9']
steps:
- uses: actions/checkout@v2
- uses: actions/setup-python@v2
Expand Down
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,10 @@ sys 0m2.486s

### Running the Entire Test Suite

You can run the test suite in the interpreter of your choice (in this example, `py36`) by doing:
You can run the test suite in the interpreter of your choice (in this example, `py37`) by doing:

```bash
tox -e py36
tox -e py37
```

This will also run the code through our series of coverage tests, `mypy` rules and other linting
Expand Down
19 changes: 0 additions & 19 deletions detect_secrets/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,25 +9,6 @@
from .exceptions import SecretNotFoundOnSpecifiedLineError
from .util.code_snippet import CodeSnippet

try:
from typing import NoReturn # noqa: F811
except ImportError: # pragma: no cover
# NOTE: NoReturn was introduced in Python3.6.2. However, we need to support Python3.6.0.
# This section of code is inline imported from `typing-extensions`, so that we don't need
# to introduce an additional package for such an edge case.
from typing import _FinalTypingBase # type: ignore

class _NoReturn(_FinalTypingBase):
__slots__ = ()

def __instancecheck__(self, obj: Any) -> None:
raise TypeError('NoReturn cannot be used with isinstance().')

def __subclasscheck__(self, cls: Any) -> None:
raise TypeError('NoReturn cannot be used with issubclass().')

NoReturn = _NoReturn(_root=True)


class SelfAwareCallable:
"""
Expand Down
4 changes: 1 addition & 3 deletions requirements-dev-minimal.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
# coveragepy==5.0 fails with `Safety level may not be changed inside a transaction
# on python 3.6.0 (xenial)
coverage<5
coverage
flake8==3.5.0
gibberish-detector>=0.1.1
monotonic
Expand Down
4 changes: 2 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
[tox]
project = detect_secrets
# These should match the ci python env list
envlist = py{36,37,38,39},mypy
envlist = py{37,38,39},mypy
skip_missing_interpreters = true
tox_pip_extensions_ext_venv_update = true

[testenv]
passenv = SSH_AUTH_SOCK
# NO_PROXY is needed to call requests API within a forked process
# when using macOS and python version 3.6/3.7
# when using macOS and python version 3.7
setenv =
NO_PROXY = '*'
deps = -rrequirements-dev.txt
Expand Down