Commit Graph

1039 Commits

Author SHA1 Message Date
Felix Fontein
ab24b14529
Merge 6f53ad9bd7 into d2947476f7 2025-11-23 21:25:40 -08:00
dependabot[bot]
d2947476f7
Bump actions/checkout from 5 to 6 in the ci group (#1211)
Bumps the ci group with 1 update: [actions/checkout](https://github.com/actions/checkout).


Updates `actions/checkout` from 5 to 6
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: ci
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-11-24 06:20:29 +01:00
Felix Fontein
6f53ad9bd7 Add ImageName helper class. 2025-11-23 13:19:17 +01:00
Felix Fontein
5d2b4085ec
Remove code that's not used. (#1209) 2025-11-23 09:48:34 +01:00
Felix Fontein
a869184ad4 Shut up pylint due to bugs. 2025-11-23 08:56:42 +01:00
Felix Fontein
a985e05482 The next expected release will be 5.1.0. 2025-11-16 13:54:23 +01:00
Felix Fontein
13e74e58fa Release 5.0.2. 2025-11-16 12:48:11 +01:00
Felix Fontein
c61c0e24b8
Improve error/warning messages w.r.t. YAML quoting (#1205)
* Remove superfluous conversions/assignments.

* Improve messages.
2025-11-16 12:32:51 +01:00
Felix Fontein
e42423b949 Forgot to update the version number. 2025-11-16 11:57:17 +01:00
Felix Fontein
0d37f20100 Prepare 5.0.2. 2025-11-16 11:56:18 +01:00
Felix Fontein
a349c5eed7
Fix connection tests. (#1202) 2025-11-16 10:55:07 +01:00
Felix Fontein
3da2799e03
Fix IP subnet and address idempotency. (#1201) 2025-11-16 10:47:35 +01:00
Felix Fontein
d207643e0c
docker_image(_push): fix push detection (#1199)
* Fix IP address retrieval for registry setup.

* Adjust push detection to Docker 29.

* Idempotency for export no longer works.

* Disable pull idempotency checks that play with architecture.

* Add more known image IDs.

* Adjust load tests.

* Adjust error message check.

* Allow for more digests.

* Make sure a new enough cryptography version is installed.
2025-11-16 10:09:23 +01:00
Felix Fontein
90c4b4c543
docker_image(_pull), docker_container: fix compatibility with Docker 29.0.0 (#1192)
* Add debug flag to failing task.

* Add more debug output.

* Fix pull idempotency.

* Revert "Add more debug output."

This reverts commit 64020149bf.

* Fix casing.

* Remove unreliable test.

* Add 'debug: true' to all tasks.

* Reformat.

* Fix idempotency problem for IPv6 addresses.

* Fix expose ranges handling.

* Update changelog fragment to also mention other affected modules.
2025-11-15 17:13:46 +01:00
Felix Fontein
68993fe353
docker_compose_v2: ignore result of build idempotency test since this seems like a hopeless case (#1196)
* Ignore result of idempotency test since this seems like a hopeless cause...

* And another one.
2025-11-15 17:06:21 +01:00
Felix Fontein
97314ec892
Move ansible-core 2.17 to EOL CI. (#1189) 2025-11-12 19:41:25 +01:00
Felix Fontein
ec14568b22
Work around Docker 29.0.0 bug. (#1187) 2025-11-12 19:21:55 +01:00
Felix Fontein
94d22f758b The next planned release will be 5.1.0. 2025-11-09 21:32:51 +01:00
Felix Fontein
aedf8f9674 Release 5.0.1. 2025-11-09 21:12:23 +01:00
Felix Fontein
86ea32b214 Prepare 5.0.1. 2025-11-08 10:02:08 +01:00
Nik Reiman
9d7dda7292
Fix error for "Cannot locate specified Dockerfile" (#1184)
In 3350283bcc, a subtle bug was introduced
by renaming this variable. For image builds that go down the `else`
branch, they never set this variable, which is then referenced below
when constructing the `params` dict. This results in a very confusing
bug from the Docker backend when trying to construct images:

> An unexpected Docker error occurred: 500 Server Error for
> http+docker://localhost/v1.51/build?t=molecule_local%2Fubuntu%3A24.04&q=False&nocache=False&rm=True&forcerm=True&pull=True&dockerfile=%2Fhome%2Fci%2F.ansible%2Ftmp%2Fmolecule.IaMj.install-github%2FDockerfile_ubuntu_24_04:
> Internal Server Error ("Cannot locate specified Dockerfile:
> /home/ci/.ansible/tmp/molecule.IaMj.install-github/Dockerfile_ubuntu_24_04")

Within the Docker daemon logs, the actual error presents itself like
this:

> level=debug msg="FIXME: Got an API for which error does not match any
> expected type!!!" error="Cannot locate specified Dockerfile:
> $HOME/.ansible/tmp/molecule.5DrS.install-package/Dockerfile_ubuntu_24_04"
> error_type="*errors.fundamental" module=api

Unfortunately, these are all red herrings and the actual cause of the
problem isn't Docker itself or the missing file, but in fact the
`docker_image` module not passing the correct parameter data here.
2025-11-08 10:01:05 +01:00
Felix Fontein
dee138bc4b
Fix typing info. (#1183) 2025-11-06 07:15:05 +01:00
Felix Fontein
00c480254d The next expected release will be 5.1.0. 2025-11-02 12:51:01 +01:00
Felix Fontein
02f787a930 Release 5.0.0. 2025-11-02 12:30:18 +01:00
Felix Fontein
ea76592af6 Prepare 5.0.0. 2025-10-29 21:15:29 +01:00
Felix Fontein
dbc7b0ec18
Cleanup with ruff check (#1182)
* Implement improvements suggested by ruff check.

* Add ruff check to CI.
2025-10-28 06:58:15 +01:00
Felix Fontein
3bade286f8 Fix mypy config. 2025-10-26 10:02:49 +01:00
Felix Fontein
3dcf394aa5 Remove stable-3 from weekly CI run. 2025-10-25 13:36:34 +02:00
Felix Fontein
7afd659459 Release 5.0.0-a1. 2025-10-25 11:29:02 +02:00
Felix Fontein
54084defd0 Prepare 5.0.0-a1. 2025-10-25 11:07:52 +02:00
Felix Fontein
95bdce75e6
Add ansible-lint to CI (#1181)
* Improve Ansible code.

* Add some ansible-lint ignores.

* Add ansible-lint to CI.
2025-10-25 11:07:40 +02:00
Felix Fontein
b24bce77b6
Use FQCNs. (#1180) 2025-10-25 10:12:21 +02:00
Felix Fontein
be000755fc
Python code modernization, 8/n (#1179)
* Use to_text instead of to_native.

* Remove no longer needed pylint ignores.

* Remove another pylint ignore.

* Remove no longer needed ignore.

* Address redefined-outer-name.

* Address consider-using-with.
2025-10-25 00:36:04 +00:00
Felix Fontein
6ad4bfcd40
Add typing information, 2/n (#1178)
* Add typing to Docker Stack modules. Clean modules up.

* Add typing to Docker Swarm modules.

* Add typing to unit tests.

* Add more typing.

* Add ignore.txt entries.
2025-10-25 01:16:04 +02:00
Felix Fontein
3350283bcc
Add typing information, 1/2 (#1176)
* Re-enable typing and improve config.

* Make mypy pass.

* Improve settings.

* First batch of types.

* Add more type hints.

* Fixes.

* Format.

* Fix split_port() without returning to previous type chaos.

* Continue with type hints (and ignores).
2025-10-23 07:05:42 +02:00
Felix Fontein
24f35644e3 Adjust checks. 2025-10-16 17:45:05 +02:00
Felix Fontein
6b5d76bdee
Adjust 'report this' messages to only report if the latest version still has this problem. (#1173) 2025-10-16 17:41:11 +02:00
Felix Fontein
3ff2cfe615
Drop support for docker-py. (#1171) 2025-10-15 21:55:07 +02:00
Felix Fontein
0646e52bae
Python code modernization, 7/n (#1170)
* Address abstract-method.

* Fix broken signature.
2025-10-15 21:27:20 +02:00
Felix Fontein
04fa3fe352
Ansible-core devel's version was bumped to 2.21.0.dev0, add stable-2.20 to CI (#1168)
* Ansible-core devel's version was bumped to 2.21.0.dev0.

* Add stable-2.20 to CI.
2025-10-15 11:39:45 +00:00
Felix Fontein
597162b153
Avoid Python 2 compat (conditional) imports. (#1167) 2025-10-13 22:31:59 +02:00
Felix Fontein
6f9ebc3f14 Fix issues with pylint 4.0. 2025-10-13 22:09:31 +02:00
Felix Fontein
16b5bfa27b Disable type checking for now. 2025-10-12 22:32:40 +02:00
Felix Fontein
17e30adb93
selectors is now part of stdlib. (#1166) 2025-10-12 22:00:51 +02:00
Felix Fontein
c75aa5dd64
Python code modernization, 5/n (#1165)
* Address raise-missing-from.

* Address simplifiable-if-expression.

* Address unnecessary-dunder-call.

* Address unnecessary-pass.

* Address use-list-literal.

* Address unused-variable.

* Address use-dict-literal.
2025-10-12 16:02:27 +02:00
Felix Fontein
cad22de628
Python code modernization, 4/n (#1162)
* Address attribute-defined-outside-init.

* Address broad-exception-raised.

* Address broad-exception-caught.

* Address consider-iterating-dictionary.

* Address consider-using-dict-comprehension.

* Address consider-using-f-string.

* Address consider-using-in.

* Address consider-using-max-builtin.

* Address some consider-using-with.

* Address invalid-name.

* Address keyword-arg-before-vararg.

* Address line-too-long.

* Address no-else-continue.

* Address no-else-raise.

* Address no-else-return.

* Remove broken dead code.

* Make consider-using-f-string changes compatible with older Python versions.

* Python 3.11 and earlier apparently do not like multi-line f-strings.
2025-10-11 23:06:50 +02:00
Felix Fontein
33c8a49191
Fix crashes due to wrong names. (#1161) 2025-10-11 15:29:14 +02:00
Felix Fontein
892e9d9cbd Reorganize imports due to https://github.com/ansible-community/antsibull-nox/pull/136. 2025-10-10 21:19:28 +02:00
Felix Fontein
f7e976f3da
Avoid losing data from events if multiple arrive at the same time. (#1158) 2025-10-10 20:21:21 +02:00
Felix Fontein
e8ec22d3b1
Python code modernization, 3/n (#1157)
* Remove __metaclass__ = type.

for i in $(grep -REl '__metaclass__ = type' plugins/ tests/); do
  sed -e '/^__metaclass__ = type/d' -i $i;
done

* Remove super arguments, and stop inheriting from object.
2025-10-10 08:11:58 +02:00