diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 041a61a932..8413eedb61 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -2,7 +2,7 @@ name: Bug report about: > Create a bug report. Ensure that it does reproduce on the main branch with - python >=3.9. For anything else, please use the discussion link below. + python >=3.10. For anything else, please use the discussion link below. labels: bug, new --- @@ -53,8 +53,8 @@ Possible security bugs should be reported via email to `security@ansible.com` -Please give some details of what is happening. -Include a [minimum complete verifiable example] with: +Please give some details of what is happening. Include a [minimum complete +verifiable example] with: - minimized playbook to reproduce the error - the output of running ansible-lint including the command line used diff --git a/.github/workflows/tox.yml b/.github/workflows/tox.yml index bc4adc6e5b..05037e2fbd 100644 --- a/.github/workflows/tox.yml +++ b/.github/workflows/tox.yml @@ -28,8 +28,9 @@ jobs: id: generate_matrix uses: coactions/dynamic-matrix@v1 with: - min_python: "3.9" + min_python: "3.10" max_python: "3.12" + default_python: "3.10" other_names: | lint pkg diff --git a/pyproject.toml b/pyproject.toml index 2821431a69..06eac3ae97 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -7,7 +7,7 @@ build-backend = "setuptools.build_meta" [project] # https://peps.python.org/pep-0621/#readme -requires-python = ">=3.9" +requires-python = ">=3.10" dynamic = ["version", "dependencies", "optional-dependencies"] name = "ansible-lint" description = "Checks playbooks for practices and behavior that could potentially be improved" @@ -26,7 +26,6 @@ classifiers = [ "Operating System :: POSIX", "License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)", "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", @@ -94,7 +93,7 @@ ensure_newline_before_comments = true line_length = 88 [tool.mypy] -python_version = 3.9 +python_version = "3.10" strict = true color_output = true error_summary = true @@ -108,7 +107,7 @@ disallow_any_generics = true # site-packages is here to help vscode mypy integration getting confused exclude = "(build|dist|test/local-content|site-packages|~/.pyenv|examples/playbooks/collections|plugins/modules)" # https://github.com/python/mypy/issues/12664 -no_incremental = true +incremental = false [[tool.mypy.overrides]] module = [ @@ -167,7 +166,7 @@ score = "n" [tool.pyright] # https://github.com/microsoft/pyright/blob/main/docs/configuration.md#sample-pyprojecttoml-file -pythonVersion = "3.9" +pythonVersion = "3.10" include = ["src"] # https://github.com/microsoft/pyright/issues/777 "stubPath" = "" diff --git a/src/ansiblelint/__main__.py b/src/ansiblelint/__main__.py index c567237a4d..ef71004b31 100755 --- a/src/ansiblelint/__main__.py +++ b/src/ansiblelint/__main__.py @@ -205,10 +205,10 @@ def _do_transform(result: LintResult, opts: Options) -> None: def support_banner() -> None: """Display support banner when running on unsupported platform.""" - if sys.version_info < (3, 9, 0): # pragma: no cover # noqa: UP036 + if sys.version_info < (3, 10, 0): # pragma: no cover prefix = "::warning::" if "GITHUB_ACTION" in os.environ else "WARNING: " console_stderr.print( - f"{prefix}ansible-lint is no longer tested under Python {sys.version_info.major}.{sys.version_info.minor} and will soon require 3.9. Do not report bugs for this version.", + f"{prefix}ansible-lint is no longer tested under Python {sys.version_info.major}.{sys.version_info.minor} and will soon require 3.10. Do not report bugs for this version.", style="bold red", ) diff --git a/src/ansiblelint/schemas/__store__.json b/src/ansiblelint/schemas/__store__.json index 09a46ee036..286adaed92 100644 --- a/src/ansiblelint/schemas/__store__.json +++ b/src/ansiblelint/schemas/__store__.json @@ -4,7 +4,7 @@ "url": "https://raw.githubusercontent.com/ansible/ansible-lint/main/src/ansiblelint/schemas/ansible-lint-config.json" }, "ansible-navigator-config": { - "etag": "815582d2c4b252906bf83d1da9667dedf16dbd9b6149cfceea205c4848c78f53", + "etag": "dba7cc2f4b1905e26673c66e15f01de8f9c7899da944d9a54ba6e684e27bd5d5", "url": "https://raw.githubusercontent.com/ansible/ansible-navigator/main/src/ansible_navigator/data/ansible-navigator.json" }, "changelog": { diff --git a/src/ansiblelint/schemas/ansible-navigator-config.json b/src/ansiblelint/schemas/ansible-navigator-config.json index 494a56d550..4f7a0e5ec8 100644 --- a/src/ansiblelint/schemas/ansible-navigator-config.json +++ b/src/ansiblelint/schemas/ansible-navigator-config.json @@ -10,7 +10,7 @@ "additionalProperties": false, "properties": { "cmdline": { - "description": "Extra parameters passed to the corresponding command", + "description": "Extra parameters passed to the underlying ansible command (e.g. ansible-playbook, ansible-doc, etc)", "type": "string" }, "config": { diff --git a/test/test_schemas.py b/test/test_schemas.py index cfa3bd17be..b2744a8481 100644 --- a/test/test_schemas.py +++ b/test/test_schemas.py @@ -101,7 +101,7 @@ def test_spdx() -> None: ) else: warnings.warn( - "test_spdx failure was ignored because constraints were not pinned (PIP_CONSTRAINTS). This is expected for py39 and py-devel jobs.", + "test_spdx failure was ignored because constraints were not pinned (PIP_CONSTRAINTS). This is expected for py310 and py-devel jobs.", category=pytest.PytestWarning, stacklevel=1, ) diff --git a/tox.ini b/tox.ini index 9290d6b2da..305af3660b 100644 --- a/tox.ini +++ b/tox.ini @@ -66,7 +66,7 @@ setenv = COVERAGE_FILE = {env:COVERAGE_FILE:{toxworkdir}/.coverage.{envname}} COVERAGE_PROCESS_START={toxinidir}/pyproject.toml PIP_CONSTRAINT = {toxinidir}/.config/constraints.txt - devel,pkg,pre,py39: PIP_CONSTRAINT = /dev/null + devel,pkg,pre,py310: PIP_CONSTRAINT = /dev/null PIP_DISABLE_PIP_VERSION_CHECK = 1 PRE_COMMIT_COLOR = always FORCE_COLOR = 1