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

Require python 3.10 or newer #231

Merged
merged 1 commit into from
Dec 11, 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
3 changes: 2 additions & 1 deletion .github/workflows/tox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ jobs:
id: generate_matrix
uses: coactions/dynamic-matrix@v1
with:
min_python: "3.9"
min_python: "3.10"
default_python: "3.10"
max_python: "3.12"
other_names: |
lint
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ which are under
[active upstream support](https://docs.ansible.com/ansible/latest/reference_appendices/release_and_maintenance.html#release-schedule)
which currently translates to:

- Python 3.9 or newer
- Python 3.10 or newer
- Ansible-core 2.14 or newer

## Installation
Expand Down Expand Up @@ -63,7 +63,7 @@ To use `pytest-ansible-units`, follow these steps:
pip install pytest-ansible
```

2. Ensure you have Python 3.9 or greater, ansible-core, and pyyaml installed.
2. Ensure you have Python 3.10 or greater, ansible-core, and pyyaml installed.

3. Depending on your preferred directory structure, you can clone collections
into the appropriate paths.
Expand Down
2 changes: 1 addition & 1 deletion docs/getting_started.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ To use `pytest-ansible`, follow these steps:
pip install pytest-ansible
```

2. Ensure you have Python 3.9 or greater, ansible-core, and pytest installed.
2. Ensure you have Python 3.10 or greater, ansible-core, and pytest installed.

3. Depending on your preferred directory structure, you can clone collections
into the appropriate paths.
Expand Down
7 changes: 3 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,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 = "pytest-ansible"
description = "Plugin for pytest to simplify calling ansible modules from tests or fixtures"
Expand All @@ -26,7 +26,6 @@ classifiers = [
'Topic :: Utilities',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
'Programming Language :: Python :: 3.12',
Expand Down Expand Up @@ -63,7 +62,7 @@ parallel = true
source = ["pytest_ansible"]

[tool.mypy]
python_version = 3.9
python_version = 3.10
ignore_missing_imports = true
ignore_errors = true
strict = true
Expand Down Expand Up @@ -151,7 +150,7 @@ ignore = [
"T",
"TRY",
]
target-version = "py39"
target-version = "py310"
# Same as Black.
line-length = 88

Expand Down
2 changes: 1 addition & 1 deletion src/pytest_ansible/module_dispatcher/v2.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ def has_module(self, name):
# otherwise, only built-in modules will work.
if "module_path" in self.options:
paths = self.options["module_path"]
if isinstance(paths, (list, tuple, set)):
if isinstance(paths, list | tuple | set):
for path in paths:
module_loader.add_directory(path)
else:
Expand Down
2 changes: 1 addition & 1 deletion src/pytest_ansible/module_dispatcher/v212.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ def has_module(self, name):
# otherwise, only built-in modules will work.
if "module_path" in self.options:
paths = self.options["module_path"]
if isinstance(paths, (list, tuple, set)):
if isinstance(paths, list | tuple | set):
for path in paths:
module_loader.add_directory(path)
else:
Expand Down
2 changes: 1 addition & 1 deletion src/pytest_ansible/module_dispatcher/v213.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ def has_module(self, name):
# otherwise, only built-in modules will work.
if "module_path" in self.options:
paths = self.options["module_path"]
if isinstance(paths, (list, tuple, set)):
if isinstance(paths, list | tuple | set):
for path in paths:
module_loader.add_directory(path)
else:
Expand Down
2 changes: 1 addition & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ setenv =
COVERAGE_PROCESS_START={toxinidir}/pyproject.toml
FORCE_COLOR = 1
PIP_CONSTRAINT = {toxinidir}/.config/constraints.txt
devel,py39: PIP_CONSTRAINT = /dev/null
devel: PIP_CONSTRAINT = /dev/null
extras =
test
allowlist_externals =
Expand Down
Loading