Commit Graph

13034 Commits

Author SHA1 Message Date
Matt Clay
13496b9e11
ansible-test - Fix integration test code coverage (#86100) 2025-10-29 18:21:53 -07:00
Shion Ichikawa
f2a4d6de12
🚨 fix yaml syntax error on ./test/integration/targets/unarchive/tasks/test_missing_binaries.yml (#86099) 2025-10-29 22:55:26 +00:00
Martin Krizek
2e8a859477
Remove deprecated imports from basic.py (#86065)
Fixes #85997
2025-10-29 19:53:03 +01:00
Matt Clay
bb30a7fa1f
ansible-test - Update base/default containers (#86087) 2025-10-28 14:01:37 -07:00
Matt Clay
3bf54c8128
Remove obsolete incidental_ios_file test (#86086) 2025-10-28 10:44:36 -07:00
Matt Clay
12acd5c18f
ansible-test - Update sanity requirements (#86083) 2025-10-28 09:33:10 -07:00
Jason K Hall
8d07ed6318
Handle ValueError in run_command when parsing invalid args(shlex.split) (#85945) 2025-10-27 14:02:22 -07:00
Brian Coca
d9d11d6ff6
sanitize path symbols in inventory_hostname on file cache plugins (#41420)
* File based cache plugins filenames fix

File based cache plugins will now correctly handle inventory_hostnames
with 'path symbols' in their names. This should allow those using
chroot and jail connection plugins to use file based caches now.
2025-10-24 14:57:11 -04:00
Abhijeet Kasurde
7bd2475a70
file, stat: return disk_usage_bytes (#85909)
Fixes: #70834

Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>
2025-10-24 18:42:58 +00:00
Brian Coca
169e6bead3
generated inventory plugin, add extra vars option (#85372) 2025-10-24 07:39:07 -04:00
Patrick Kingston
087931546d
Remove deprecated safe_eval (#86019)
* Remove safe_eval from codebase

Resolves deprecations in 85996 and 85999

* Remove deprecations from sanity ignores

* Add changelog fragment

* Add newline to file

* Remove unused imports
2025-10-22 12:22:14 -04:00
Sloane Hertel
df34bf9e70
Update win_exec_wrapper integration test to match #86029 (#86052)
* Remove assertion now that there is no warning
2025-10-21 17:56:18 -04:00
sivel / Matt Martz
e4b4787c02
Soft deprecate ansible.module_utils.six (#86048) 2025-10-21 16:20:55 -05:00
Martin Krizek
6dd48814f2
Remove test/units/module_utils/compat/test_datetime.py (#86045)
Follow up on #86018
2025-10-21 14:17:47 -04:00
Abhijeet Kasurde
367de4498b
module_utils: remove deprecated compat.datetime APIs (#86018)
Fixes: #86000

Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>
2025-10-21 11:43:28 -04:00
Abhijeet Kasurde
9a350ff104
git: removed deprecated gpg_whitelist alias (#86011)
Fixes: #86004

Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>
2025-10-21 11:37:42 -04:00
Abhijeet Kasurde
9f1177a056
Removed parameter 'required' from get_bin_path API (#86009)
Fixes: #85998

Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>
2025-10-21 11:37:03 -04:00
Abhijeet Kasurde
790b66f383
interpreter_discovery: removed auto_silent* option (#86006)
* interpreter_discovery: removed auto_silent* option

* Removed deprecated auto_silent* option from interpreter_discovery_python

Fixes: #85995

Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>

* Make CI green

Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>

* Make CI green I

Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>

---------

Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>
2025-10-21 11:35:53 -04:00
Jason K Hall
192948434c
galaxy: handle missing 'results' key in cached Galaxy API responses. (#85972)
* galaxy: handle missing 'results' key in cached Galaxy API responses.

* galaxy: clarified AnsibleError message for missing cache results.

* Modified AnsibleError message and added a regression test.

* Fixed formatting issue in test/units/galaxy/test_api.py

* Added a changelog entry.

* Modified changelog.
2025-10-21 11:27:24 -04:00
sivel / Matt Martz
d6051b18dd
Add support for crypt/libxcrypt via ctypes, as an alternative to passlib (#85970)
* Add support for crypt/libxcrypt via ctypes, as an alternative to passlib

* move verbosity message to BaseHash

* Don't require DYLD_LIBRARY_PATH mods for standard homebrew installs on macos

* improve crypt_gensalt error handling
2025-10-21 11:24:57 -04:00
sivel / Matt Martz
f1f5b934c2
Update DataLoader to deal almost exclusively in str (#85941)
* Update DataLoader to deal almost exclusively in str

* source can be None as well

Co-authored-by: David Shrewsbury <Shrews@users.noreply.github.com>
2025-10-21 11:06:15 -04:00
Brian Coca
ccfb7b1364
Fix include_role error consitency and add rescueable option (#86012)
* include_role now behaves more like task on error

changes _from errors from syntax to task failures, by default
which makes it more consistent with other existing errors
 * also force 'missing role' to behave as syntax error when false
 * also error when subdir does not exist, previouslly we ignored missing
   file
 * add 'rescuable' toggle to allow user to chose error type

Co-authored-by: Abhijeet Kasurde <akasurde@redhat.com>
Co-authored-by: Sloane Hertel <19572925+s-hertel@users.noreply.github.com>
2025-10-20 19:19:11 -04:00
Brian Coca
1cb2932c95
config lookup, fix 'show_origin' and variables (#85356)
show_origin and variable sources were broken for base config when 'forked' from plugins
---------
Co-authored-by: 🇺🇦 Sviatoslav Sydorenko (Святослав Сидоренко) <wk.cvs.github@sydorenko.org.ua>
2025-10-20 19:15:00 -04:00
Brian Coca
22721b5d63
Slurp armor option (#85986)
* slurp, add option to deactivate the armor

Co-authored-by: Abhijeet Kasurde <akasurde@redhat.com>
2025-10-17 18:09:30 -04:00
Martin Krizek
05d5b0f168
Avoid the ssh-agent exiting before tests end (#85979)
There were couple of occurrences where the hard 30 seconds limit on
running ssh-agent was not enough for the test to run and the ssh-agent
was killed resulting in the test failing with "Connection refused". This
change just lets the agent run in the background and kills it
manually after the tests finish.
2025-10-15 08:23:31 +02:00
sivel / Matt Martz
726e8d6548
Bump devel to 2.21 (#85992) 2025-10-14 15:35:21 -05:00
sivel / Matt Martz
c02f59ca3a
fix urls in additional ansible-doc test (#85988) 2025-10-14 13:05:39 -05:00
Matt Clay
83c79240ec
ansible-test - Update base/default/distro containers (#85985) 2025-10-13 16:39:17 -07:00
Matt Clay
7c2311d547
ansible-test - Upgrade coverage to 7.10.7 (#85981) 2025-10-13 14:30:14 -07:00
Matt Clay
de7dd5bbb2
ansible-test - Update pinned pip to 25.2 (#85982) 2025-10-13 21:00:17 +00:00
sivel / Matt Martz
5a9afe4409
Fix signal propagation (#85907) 2025-10-13 15:38:12 -05:00
Matt Clay
9ee667030f
ansible-test - Update sanity test requirements (#85980) 2025-10-13 12:32:39 -07:00
Matt Clay
82b64d4b69
ansible-test - Update base/default containers (#85967) 2025-10-09 20:58:50 +00:00
Matt Clay
06456c68ec
Use bcrypt < 5 for unit tests (#85969) 2025-10-09 19:32:27 +00:00
Sviatoslav Sydorenko
53afc6f203 Mention pkg name in package-data sanity output
The logs were displaying a series of numbers in parens like `(66.1.0)`
at the end of each error line. its unintuitive what that means. I had
to look into the source code to confirm my suspicion of it being the
version of `setuptools`. This patch spells it out.
2025-10-09 00:40:59 +02:00
Sviatoslav Sydorenko
0cd36ce6d0 Use strict_optional @ ansible.galaxy.dependency_resolution
This patch drops unnecessary default for
`CollectionDependencyProvider`'s `concrete_artifacts_manager` argument
as it is always passed, in every place across the code base where the
provider is constructed.

It was also causing MyPy violations on calls to
`_ComputedReqKindsMixin.from_requirement_dict()` in the "strict
optional" mode which is now enforced for $sbj, while remaining
disabled globally.

It is a #85545 follow-up.
2025-10-07 22:11:58 +02:00
Sviatoslav Sydorenko
c9131aa847 Type-annotate ansible.galaxy.dependency_resolution
This patch is a combination of `pyrefly autotype` and manual
post-processing. Parts of it migrate pre-existing comment-based
annotations, fixing incorrect ones where applicable.

The change also configures MyPy to run checks against actual
`resolvelib` annotations and includes a small tweak of
`ansible.galaxy.collection._resolve_depenency_map` to make it
compatible with those.

Co-Authored-By: Jordan Borean <jborean93@gmail.com>
Co-Authored-By: Matt Clay <matt@mystile.com>
Co-Authored-By: Sloane Hertel <19572925+s-hertel@users.noreply.github.com>
2025-10-07 09:55:10 +02:00
David Shrewsbury
feda8fc564
Fix flakey get_url test (#85953) 2025-10-06 18:42:03 -07:00
sivel / Matt Martz
6673a14a9e
Update DataLoader.get_basedir to be an abspath (#85940) 2025-10-06 09:22:47 -05:00
s-hamann
0c7dcb65cf
fetch - return file in result when changed is true (#85729)
Set the (source) file attribute in the return value if the file changed
(e.g. on initial fetch). The attribute is already set in all other
cases.
2025-10-03 08:28:41 -04:00
Martin Krizek
686c3658ae
Deprecate ansible.module_utils.six (#85934)
* Deprecate `ansible.module_utils.six`

Fixes #85920
2025-10-02 13:17:03 -05:00
Sloane Hertel
cb2ecda514
Remove support for resolvelib < 0.8.0 (#85936)
* Remove support for resolvelib < 0.8.0

Remove code handling differences between resolvelib 0.5.3 and 0.8.0

Drop some versions from the test to reduce the time it takes to run

Co-authored-by: Sviatoslav Sydorenko <wk@sydorenko.org.ua>

* Remove type annotation

---------

Co-authored-by: Sviatoslav Sydorenko <wk@sydorenko.org.ua>
2025-10-01 14:33:21 -07:00
Martin Krizek
313c6f6b4d
Don't special case implicit meta tasks when filtering on tags (#85805)
* Don't special case implicit meta tasks when filtering on tags

Fixes #85475
2025-10-01 17:44:53 +00:00
Abhijeet Kasurde
6bee84318d
known_hosts: return rc and stderr in fail_json (#85871)
* When ssh-keygen fails, return rc and stderr in fail_json
  in order to help debugging.

Fixes: #85850

Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>
2025-10-01 16:07:29 +00:00
Martin Krizek
c3f87b31d1
import_tasks processing closer to include_tasks (#85877)
Fixes #69882
Closes #83853
Fixes #85855
Fixes #85856
2025-10-01 09:56:14 +02:00
Felix Fontein
c6d8d206af
Make sure ansible-doc doesn't crash when scanning collections whose path contains ansible_collections twice (#85361)
Ref: https://github.com/ansible/ansible/issues/84909#issuecomment-2767335761

Co-authored-by: s-hertel <19572925+s-hertel@users.noreply.github.com>
Co-authored-by: Brian Coca <bcoca@users.noreply.github.com>
2025-09-30 10:08:43 -04:00
Matt Clay
58bad71859
Move display internals into _internal (#85889) 2025-09-22 16:07:10 -07:00
Sloane Hertel
27a56a34df
Add feature preview play argument spec validation (#85763)
* Add new play keyword validate_argspec

Set to True to use the play name as the argument spec identifier. A play name is required (i.e. a host pattern is not supported as an argument spec name).

Alternatively, set to a specific argument spec name.

A valid argument spec for the play is required. Example:

# playbook.meta.yml
argument_specs:
  name of the play:
    options: {}

* Play argument spec validation runs after fact gathering

Play keywords like tags are inherited and work similarly to fact gathering
2025-09-18 15:13:07 -04:00
Brian Coca
c87dc6ed7d
script inventory plugin correct error message (#85765)
type was reflecting 'converted' type, not 'pre conversion' of the data
now message points at specific data keys
add deprecation tests
2025-09-17 09:59:37 -04:00
Sloane Hertel
5e8815b823
Fix ansible-doc -l/-F/--metadata-dump for relative imports in filter/test plugins (#85801)
* Add test for sidecar documentation for filter plugin in a subdirectory

Fix ansible-doc --list/--list_files/--metadata-dump for relative imports in nested filter/test plugin files
2025-09-15 18:15:55 -04:00