mirror of
https://github.com/certbot/certbot.git
synced 2026-06-06 15:22:38 -04:00
Add warnings about Python 3.5 deprecation in Certbot
This commit is contained in:
parent
ebf1349b15
commit
5a1ca05e08
4 changed files with 23 additions and 1 deletions
|
|
@ -20,3 +20,11 @@ for mod in list(sys.modules):
|
|||
# preserved (acme.jose.* is josepy.*)
|
||||
if mod == 'josepy' or mod.startswith('josepy.'):
|
||||
sys.modules['acme.' + mod.replace('josepy', 'jose', 1)] = sys.modules[mod]
|
||||
|
||||
|
||||
if sys.version_info[:2] == (3, 5):
|
||||
warnings.warn(
|
||||
"Python 3.5 support will be dropped in the next release of "
|
||||
"acme. Please upgrade your Python version.",
|
||||
PendingDeprecationWarning,
|
||||
) # pragma: no cover
|
||||
|
|
|
|||
|
|
@ -12,7 +12,8 @@ Certbot adheres to [Semantic Versioning](https://semver.org/).
|
|||
|
||||
### Changed
|
||||
|
||||
*
|
||||
* We deprecated support for Python 3.5 in Certbot and its ACME library.
|
||||
Support for Python 3.5 will be removed in the next major release of Certbot.
|
||||
|
||||
### Fixed
|
||||
|
||||
|
|
|
|||
|
|
@ -1,4 +1,13 @@
|
|||
"""Certbot client."""
|
||||
import warnings
|
||||
import sys
|
||||
|
||||
# version number like 1.2.3a0, must have at least 2 parts, like 1.2
|
||||
__version__ = '1.7.0.dev0'
|
||||
|
||||
if sys.version_info[:2] == (3, 5):
|
||||
warnings.warn(
|
||||
"Python 3.5 support will be dropped in the next release of "
|
||||
"acme. Please upgrade your Python version.",
|
||||
PendingDeprecationWarning,
|
||||
) # pragma: no cover
|
||||
|
|
@ -1343,6 +1343,10 @@ def main(cli_args=None):
|
|||
if config.func != plugins_cmd: # pylint: disable=comparison-with-callable
|
||||
raise
|
||||
|
||||
if sys.version_info[:2] == (3, 5):
|
||||
logger.warning("Python 3.5 support will be dropped in the next release "
|
||||
"of Certbot - please upgrade your Python version.")
|
||||
|
||||
set_displayer(config)
|
||||
|
||||
# Reporter
|
||||
|
|
|
|||
Loading…
Reference in a new issue