Commit Graph

3565 Commits (5e903ab1e14dac79fa8579479d37f0dcbb9fc630)
 

Author SHA1 Message Date
Alex Willmer 5e903ab1e1
Merge pull request #1093 from moreati/release-v0.3.8
Release v0.3.8
4 months ago
Alex Willmer d0d39cccf2 Merge commit 'e334b50d9d5bc5174d1e07c83c6617db6406193e' into release-v0.3.8 4 months ago
Alex Willmer e334b50d9d Prepare v0.3.8 4 months ago
Alex Willmer 8bec30d97c
Merge pull request #1091 from moreati/issue1090
ci: Summer 2024 test fixups
4 months ago
Alex Willmer fe435bb7d0 CI: Workaround "No module named 'setuptools.command.test'"
Pip 72 was released yesterday (2024-07-28), dropping `setup.py test` support.
hdrhistogram 0.6.1 requires it to install.

For now constrain Pip to earlier releases, so our tests can be run.

refs #1090
4 months ago
Alex Willmer 924dbd6f0c CI: Migrate macOS integration tests to macOS 12, drop Python 2.7 jobs
macOS 11 is not longer an available runner on Azure Devops. The minimum is now
macOS 12. This runner does not have Python 2.7 installed, so running them
would require a custom install - which I'm declaring too much effort for too
little gain.

refs #1090
4 months ago
Alex Willmer f5a8840668 CI: Use archived RPMs on CentOS 8
CentOS 8 has reached EOL. Packages are no longer mirrored or maintained. A
historic snapshot of the packages is kept on vault.centos.org.

refs #1088, #1090
4 months ago
Alex Willmer 23d9d0bc82
Merge pull request #1060 from moreati/issue1059
Speed up test suite
6 months ago
Alex Willmer 7079a07a15 tests: Fix duplicate local task executions
integration/ssh/timeouts.yml is noteworthy. It was an accidental N**2 in time
-  executing num hosts * num hosts tasks.
6 months ago
Alex Willmer 65c8a42c13 tests: Use same verbosity when re-executing Ansible inside a playbook 6 months ago
Alex Willmer 05d98e5b49 tests: Speed up ssh timeout tests 6 months ago
Alex Willmer 0ce9ffc464
Merge pull request #1067 from philfry/host_key_checking
Fix add_hosts when ansible_host_key_checking is passed to the new host
7 months ago
Alex Willmer 60f868290d
tests: Remove --limit when running Ansible localhost CI
Some tests were being incorrectly excluded. Including those that use
`add_host`.
refs #1066, #1069
7 months ago
Alex Willmer d2eefc06aa
tests: Add regression for add_host with host_key_checking
refs #1066
7 months ago
Philippe Kueck ec05e542b4
Fix 'ansible_host_key_checking' and 'ansible_ssh_host_key_checking' for
adding new hosts to the inventory using 'add_hosts'

Co-authored-by: Alex Willmer <alex@moreati.org.uk>
7 months ago
Alex Willmer 0f34e2505b
Merge pull request #1065 from moreati/issue957
ansible_mitogen: Fix "filedescriptor out of range in select()" in WorkerProcess
7 months ago
Alex Willmer 4996ec2f09 ansible_mitogen: Fix "filedescriptor out of range in select()" in WorkerProcess
`mitogen.parent.POLLER_LIGHTWEIGHT` will normally be `PollPoller`, falling
back to `EpollPoller`, `KqueuePoller`, or `Poller`.

Fixes #957

Co-authored-by: Luca Berruti <nadirio@gmail.com>
Co-authored-by: Philippe Kueck <bqobccy6ejnq2bqvmebqiwqha4cs4@protected32.unixadm.org>
7 months ago
Alex Willmer efdd82d1ab mitogen: Streamline Poller classes and Latch.poller_class selection
This
- Clarifies and corrects docstrings and comments based on investigation for #957
- Removes unused `Poller*._repr` attributes
- Eliminates some uses of `getattr()`
- Introduces `mitogen.parent.POLLERS` & `mitogen.parent.POLLER_LIGHTWEIGHT`

Preamble size change
```
@@ -1,7 +1,7 @@
 SSH command size: 759
-Bootstrap (mitogen.core) size: 17862 (17.44KiB)
+Bootstrap (mitogen.core) size: 17934 (17.51KiB)

                               Original          Minimized           Compressed
-mitogen.parent            98171 95.9KiB  50569 49.4KiB 51.5%  12742 12.4KiB 13.0%
+mitogen.parent            96979 94.7KiB  49844 48.7KiB 51.4%  12697 12.4KiB 13.1%
 mitogen.fork               8436  8.2KiB   4130  4.0KiB 49.0%   1648  1.6KiB 19.5%
 mitogen.ssh               10892 10.6KiB   6952  6.8KiB 63.8%   2113  2.1KiB 19.4%
```
7 months ago
Alex Willmer bb9c51b3e9
Merge pull request #1007 from moreati/ask-become-pass
Fix --ask-become-pass
8 months ago
Alex Willmer 8c93973f98 tests: Use Android portal to check get_url
Should have higher uptime, and make us less of a burden. Refs #1058
8 months ago
Alex Willmer d5e9186289 ansible_mitogen: Fix --ask-become-pass, add test coverage
Previously f1503874de fixed the priority of
ansible_become_pass over ansible_become_password, but broke --ask-become-pass.
Fixes #952.
8 months ago
Alex Willmer 3f7a0f74a5
Merge pull request #1057 from moreati/release-v0.3.7
Release v0.3.7
8 months ago
Alex Willmer f6ed546c38 Merge commit 'a3644963c40f117b2bef819cc8617bbd395c7f95' into release-v0.3.7 8 months ago
Alex Willmer c4cf0d5ba2 ci: Use profile_tasks callback as rough benchmark of Ansible tests 8 months ago
Alex Willmer a3644963c4 Prepare v0.3.7 8 months ago
Alex Willmer e1b2f38c8e tox: Add python2 & python3 to adhoc install hint 8 months ago
Alex Willmer 37ebce7e6e Begin 0.3.8dev 8 months ago
Alex Willmer cca651da1f ansible_mitogen: Ansible 9 (ansible-core 2.16) support 8 months ago
Alex Willmer 45c42d386a tests: Replace uses of ``include:``, unify skipping of mitogen only tests
The tag mitogen_only is only informational for now. It may be possible to use
it with ANSIBLE_SKIP_TAGS in the future.
8 months ago
Alex Willmer fa1d21747f ansible_mitogen: Declare Ansible 8 (ansible-core 2.15) support
refs #1021
8 months ago
Alex Willmer 2333b9aced ci: Exclude docs-master branch 8 months ago
Alexandre Detiste fe54b0ac3f prefer newer unittest.mock from the standad library 8 months ago
Alexandre Detiste 58235e3675 add Python3 compatibility 8 months ago
Alex Willmer b488baed25 Prepare 0.3.6 8 months ago
Alex Willmer d70ec4e540 ansible_mitogen: Handle AnsibleUnsafeText et al in Ansible >= 7
Follwing fixes in Ansible 7-9 for CVE-2023-5764 cating `AnsibleUnsafeBytes` &
`AnsibleUnsafeText` to `bytes()` or `str()` requires special handling. The
handling is Ansible specific, so it shouldn't go in the mitogen package but
rather the ansible_mitogen package.

`ansible_mitogen.utils.unsafe.cast()` is most like `mitogen.utils.cast()`.
During development it began as `ansible_mitogen.utils.unsafe.unwrap_var()`,
closer to an inverse of `ansible.utils.unsafe_procy.wrap_var()`. Future
enhancements may move in this direction.

refs #977, refs #1046

See also
- https://github.com/advisories/GHSA-7j69-qfc3-2fq9
- https://github.com/ansible/ansible/pull/82293
- https://github.com/mitogen-hq/mitogen/wiki/AnsibleUnsafe-notes
8 months ago
Alex Willmer 8059be7160 ansible_mitogen: Make ansible_mitogens.utils a package
Prep work for ansible_mitogen.utils.unsafe
8 months ago
Alex Willmer 1c0253f201 mitogen: Raise TypeError on `mitogen.utils.cast(custom_str)` failures
If casting a string fails then raise a TypeError. This is potentially an API
breaking change; chosen as the lesser evil vs. allowing silent errors.

`cast()` relies on `bytes(obj)` & `str(obj)` returning the respective
supertype. That's no longer the case for `AnsibleUnsafeBytes` &
`AnsibleUnsafeText`; since fixes/mitigations for  CVE-2023-5764.

fixes #1046, refs #977

See also
- https://github.com/advisories/GHSA-7j69-qfc3-2fq9
- https://github.com/ansible/ansible/pull/82293
8 months ago
Orion Poplawski 11e5529e44 ansible_mitogen: Add Ansible 7 support
Co-authored-by: Orion Poplawski <orion@nwra.com>
8 months ago
Alex Willmer 1fbf93203c Start v0.3.6 development 8 months ago
Alex Willmer 933477fcbe Begin 0.3.7dev 8 months ago
Alex Willmer 5d789faee5 Prepare 0.3.6 8 months ago
Alex Willmer b822f20007 ansible_mitogen: Handle AnsibleUnsafeText et al in Ansible >= 7
Follwing fixes in Ansible 7-9 for CVE-2023-5764 cating `AnsibleUnsafeBytes` &
`AnsibleUnsafeText` to `bytes()` or `str()` requires special handling. The
handling is Ansible specific, so it shouldn't go in the mitogen package but
rather the ansible_mitogen package.

`ansible_mitogen.utils.unsafe.cast()` is most like `mitogen.utils.cast()`.
During development it began as `ansible_mitogen.utils.unsafe.unwrap_var()`,
closer to an inverse of `ansible.utils.unsafe_procy.wrap_var()`. Future
enhancements may move in this direction.

refs #977, refs #1046

See also
- https://github.com/advisories/GHSA-7j69-qfc3-2fq9
- https://github.com/ansible/ansible/pull/82293
- https://github.com/mitogen-hq/mitogen/wiki/AnsibleUnsafe-notes
8 months ago
Alex Willmer 813f253d6b ansible_mitogen: Make ansible_mitogens.utils a package
Prep work for ansible_mitogen.utils.unsafe
8 months ago
Alex Willmer d7979c3597 mitogen: Raise TypeError on `mitogen.utils.cast(custom_str)` failures
If casting a string fails then raise a TypeError. This is potentially an API
breaking change; chosen as the lesser evil vs. allowing silent errors.

`cast()` relies on `bytes(obj)` & `str(obj)` returning the respective
supertype. That's no longer the case for `AnsibleUnsafeBytes` &
`AnsibleUnsafeText`; since fixes/mitigations for  CVE-2023-5764.

fixes #1046, refs #977

See also
- https://github.com/advisories/GHSA-7j69-qfc3-2fq9
- https://github.com/ansible/ansible/pull/82293
8 months ago
Orion Poplawski dfc3c7d516 ansible_mitogen: Add Ansible 7 support
Co-authored-by: Orion Poplawski <orion@nwra.com>
8 months ago
Alex Willmer 541f7c3247
Merge pull request #1044 from moreati/stable-0.3.5
Release v0.3.5
8 months ago
Alex Willmer 1572da1563 docs: Correct PEP 451 hyperlink
(cherry picked from commit 50efa53f8f)
8 months ago
Alex Willmer 21e874e60c
Merge pull request #1047 from mitogen-hq/changlog-pep451
docs: Correct PEP 451 hyperlink
8 months ago
Alex Willmer 50efa53f8f
docs: Correct PEP 451 hyperlink 8 months ago
Alex Willmer d83cfd6bed Merge v0.3.5 preperation 8 months ago