diff --git a/packages/@jsii/python-runtime/src/jsii/__init__.py b/packages/@jsii/python-runtime/src/jsii/__init__.py index 9eaf7dd80b..20dcc97b43 100644 --- a/packages/@jsii/python-runtime/src/jsii/__init__.py +++ b/packages/@jsii/python-runtime/src/jsii/__init__.py @@ -37,12 +37,12 @@ stats = kernel.stats -if sys.version_info < (3, 7): +if sys.version_info < (3, 8): from platform import python_version import warnings warnings.warn( - f"WARNING: You are using python release {python_version()}, which has reached end-of-life! Support for EOL Python releases may be dropped in the future. Please consider upgrading to Python >= 3.7 as soon as possible.", + f"WARNING: You are using python release {python_version()}, which has reached end-of-life! Support for EOL Python releases may be dropped in the future. Please consider upgrading to Python >= 3.8 as soon as possible.", ) diff --git a/packages/@jsii/python-runtime/tests/test_invoke_bin.py b/packages/@jsii/python-runtime/tests/test_invoke_bin.py index 763afc56ac..8ff6a94271 100644 --- a/packages/@jsii/python-runtime/tests/test_invoke_bin.py +++ b/packages/@jsii/python-runtime/tests/test_invoke_bin.py @@ -44,7 +44,6 @@ def test_invoke_script(self, silence_node_deprecation_warnings) -> None: assert result.returncode == 0 assert result.stdout == b"Hello World!\n" - assert result.stderr == b"" @pytest.mark.skipif( platform.system() == "Windows", @@ -56,7 +55,6 @@ def test_invoke_script_with_args(self, silence_node_deprecation_warnings) -> Non assert result.returncode == 0 assert result.stdout == b"Hello World!\n arguments: arg1, arg2\n" - assert result.stderr == b"" @pytest.mark.skipif( platform.system() == "Windows", @@ -70,7 +68,7 @@ def test_invoke_script_with_failure( assert result.returncode == 3 assert result.stdout == b"Hello World!\n arguments: arg1, fail\n" - assert result.stderr == b"error message to stderr\n" + assert result.stderr.startswith(b"error message to stderr\n") @pytest.mark.skipif( platform.system() == "Windows",