Skip to content

Commit a0ba32d

Browse files
authored
Drop support for Python 3.6 (#869)
* Drop support for Python 3.6 * Fix docs build * Add changelog entry
1 parent 55652f0 commit a0ba32d

File tree

7 files changed

+10
-9
lines changed

7 files changed

+10
-9
lines changed

.github/workflows/main.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ concurrency:
1313
env:
1414
FORCE_COLOR: "1"
1515
TOX_TESTENV_PASSENV: "FORCE_COLOR"
16-
MIN_PYTHON_VERSION: "3.6"
16+
MIN_PYTHON_VERSION: "3.7"
1717
DEFAULT_PYTHON_VERSION: "3.9"
1818

1919
jobs:
@@ -33,7 +33,6 @@ jobs:
3333
strategy:
3434
matrix:
3535
python-version:
36-
- "3.6"
3736
- "3.7"
3837
- "3.8"
3938
- "3.9"

.readthedocs.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ formats:
1515

1616
python:
1717
# Mininum supported Python version
18-
version: "3.6"
18+
version: "3.7"
1919
# Install twine first, because RTD uses `--upgrade-strategy eager`,
2020
# which installs the latest version of docutils via readme_renderer.
2121
# However, Sphinx 4.2.0 requires docutils>=0.14,<0.18.

changelog/869.feature.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Drop support for Python 3.6.

docs/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@
286286

287287
# TODO: Try to add these to intersphinx_mapping
288288
nitpick_ignore_regex = [
289-
(r"py:.*", r"(pkginfo|IO).*"),
289+
(r"py:.*", r"pkginfo.*"),
290290
]
291291

292292
# -- Options for apidoc output ------------------------------------------------

setup.cfg

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ classifiers =
2323
Programming Language :: Python
2424
Programming Language :: Python :: 3
2525
Programming Language :: Python :: 3 :: Only
26-
Programming Language :: Python :: 3.6
2726
Programming Language :: Python :: 3.7
2827
Programming Language :: Python :: 3.8
2928
Programming Language :: Python :: 3.9
@@ -34,7 +33,7 @@ classifiers =
3433
packages =
3534
twine
3635
twine.commands
37-
python_requires = >=3.6
36+
python_requires = >=3.7
3837
install_requires=
3938
pkginfo >= 1.8.1
4039
readme-renderer >= 21.0

tox.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tox]
22
minversion = 3.3
3-
envlist = lint,types,py{36,37,38,39,310},integration,docs
3+
envlist = lint,types,py{37,38,39,310},integration,docs
44
isolated_build = True
55

66
[testenv]

twine/settings.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,13 @@
1111
# distributed under the License is distributed on an "AS IS" BASIS,
1212
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
1313
# See the License for the specific language governing permissions and
14+
from __future__ import annotations
15+
1416
# limitations under the License.
1517
import argparse
1618
import contextlib
1719
import logging
18-
from typing import Any, ContextManager, Optional, cast
20+
from typing import Any, Optional, cast
1921

2022
from twine import auth
2123
from twine import exceptions
@@ -136,7 +138,7 @@ def password(self) -> Optional[str]:
136138
# Workaround for https://github.com/python/mypy/issues/5858
137139
return cast(Optional[str], self.auth.password)
138140

139-
def _allow_noninteractive(self) -> ContextManager[None]:
141+
def _allow_noninteractive(self) -> contextlib.AbstractContextManager[None]:
140142
"""Bypass NonInteractive error when client cert is present."""
141143
suppressed = (exceptions.NonInteractive,) if self.client_cert else ()
142144
return contextlib.suppress(*suppressed)

0 commit comments

Comments
 (0)