patchback[bot]
b5846a3d05
[PR #11567/9b72d954 backport][stable-12] Add missing __future__ imports ( #11569 )
...
Add missing __future__ imports (#11567 )
Add missing __future__ imports.
(cherry picked from commit 9b72d95452 )
Co-authored-by: Felix Fontein <felix@fontein.de>
2026-03-11 07:10:34 +01:00
patchback[bot]
25c475a7ef
[PR #11561/7436c0c9 backport][stable-12] replace literal HTTP codes with http.HTTPStatus ( #11568 )
...
replace literal HTTP codes with `http.HTTPStatus` (#11561 )
* replace literal HTTP codes with http.HTTPStatus
* add changelog frag
(cherry picked from commit 7436c0c9ba )
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2026-03-10 22:14:27 +01:00
patchback[bot]
b769b0bc01
[PR #11400/236b9c0e backport][stable-12] Sort imports with ruff check --fix ( #11409 )
...
Sort imports with ruff check --fix (#11400 )
Sort imports with ruff check --fix.
(cherry picked from commit 236b9c0e04 )
Co-authored-by: Felix Fontein <felix@fontein.de>
2026-01-09 19:36:52 +01:00
patchback[bot]
f648dca84a
[PR #11189/1c678f5c backport][stable-12] fix ruff case UP030 ( #11195 )
...
fix ruff case UP030 (#11189 )
* fix ruff case UP030
* add changelog frag
* formatting
* suggestion from review
(cherry picked from commit 1c678f5c07 )
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2025-11-23 08:58:57 +01:00
patchback[bot]
5ae8d2ccec
[PR #11107/e20e32bb backport][stable-12] Extend failure message for merge_variables type detection ( #11166 )
...
Extend failure message for merge_variables type detection (#11107 )
merge_variables: extend type detection failure message
Update the error message for the merge_variables lookup plugin in case an unsupported type is passed.
(cherry picked from commit e20e32bb87 )
Co-authored-by: Roy Lenferink <lenferinkroy@gmail.com>
2025-11-17 06:47:04 +01:00
patchback[bot]
93d23cfef6
[PR #11119/41923e43 backport][stable-12] fix ruff case SIM103 ( #11132 )
...
fix ruff case SIM103 (#11119 )
* fix ruff case SIM103
* add changelog frag
(cherry picked from commit 41923e43bd )
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2025-11-12 21:32:10 +01:00
patchback[bot]
cc93dab0fd
[PR #11095/2b4333a0 backport][stable-12] Use raise from in plugins ( #11129 )
...
Use raise from in plugins (#11095 )
* Use raise from.
* Add changelog fragment.
(cherry picked from commit 2b4333a033 )
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-11-12 21:00:39 +01:00
patchback[bot]
a78d0d2263
[PR #11031/3cbe44e2 backport][stable-12] Update TSS lookup plugin documentation and add Delinea Platform authentication examples ( #11074 )
...
Update TSS lookup plugin documentation and add Delinea Platform authentication examples (#11031 )
* - Update documentation from Thycotic to Delinea branding
- Add comprehensive Platform authentication examples
- Enhance existing examples with clearer task names
- Improve RETURN section documentation
- Fix AccessTokenAuthorizer initialization with base_url parameter
- Add support for both Secret Server and Platform authentication methods
* Fixed lintitng issue and added changelog fragment file.
* Removed documentation changes from changelog file.
(cherry picked from commit 3cbe44e269 )
Co-authored-by: delinea-sagar <131447653+delinea-sagar@users.noreply.github.com>
2025-11-10 06:47:46 +01:00
patchback[bot]
8cd80d94a0
[PR #11049/396f467b backport][stable-12] Improve Python code: address unused variables ( #11058 )
...
Improve Python code: address unused variables (#11049 )
* Address F841 (unused variable).
* Reformat.
* Add changelog fragment.
* More cleanup.
* Remove trailing whitespace.
* Readd removed code as a comment with TODO.
(cherry picked from commit 396f467bbb )
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-11-09 09:59:42 +01:00
Felix Fontein
340ff8586d
Reformat everything.
2025-11-01 13:46:53 +01:00
Felix Fontein
74c2c804e5
Cleanup: use super() instead of super(__class__, self) ( #11016 )
...
* Address UP008: Use super() instead of super(__class__, self).
* Linting.
2025-10-30 20:17:26 +01:00
Felix Fontein
0c5466de47
Cleanup: remove unicode prefix, remove explicit inheritance from object ( #11015 )
...
* Address UP025: remove unicode literals from strings.
* Address UP004: class inherits from 'object'.
2025-10-30 20:17:10 +01:00
Felix Fontein
6088b0cff5
CI: add type checking ( #10997 )
...
* Set up type checking with mypy.
* Make mypy pass.
* Use list() instead of sorted().
2025-10-29 17:13:38 +00:00
Alexey Langer
831787619a
Add exclude option to filetree module ( #10966 )
...
* Added excludes option to filetree module
* Renamed option 'excludes' to 'exclude'
* Corrected issue and PR links
Co-authored-by: Felix Fontein <felix@fontein.de>
* Added version for documentation
Co-authored-by: Felix Fontein <felix@fontein.de>
* Fixed example of using exclude option
Co-authored-by: Felix Fontein <felix@fontein.de>
* Fixed regular expression in example
Co-authored-by: Felix Fontein <felix@fontein.de>
---------
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-10-29 17:46:26 +01:00
Matthew
ce0d06b306
onepassword: extend CLI class initialization with additional parameters ( #10965 )
...
* onepassword: extend CLI class initialization with additional parameters
* add changelog fragment 10965-onepassword-bugfix.yml
* Update changelogs/fragments/10965-onepassword-bugfix.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
---------
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-10-28 21:25:45 +01:00
Alexei Znamensky
3734f471c1
use f-strings ( #10899 )
...
* use f-strings
* add changelog frag
* Apply suggestions from code review
Co-authored-by: Felix Fontein <felix@fontein.de>
---------
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-10-11 11:59:28 +02:00
Felix Fontein
8f8a0e1d7c
Fix __future__ imports, __metaclass__ = type, and remove explicit UTF-8 encoding statement for Python files ( #10886 )
...
* Adjust all __future__ imports:
for i in $(grep -REl "__future__.*absolute_import" plugins/ tests/); do
sed -e 's/from __future__ import .*/from __future__ import annotations/g' -i $i;
done
* Remove all UTF-8 encoding specifications for Python source files:
for i in $(grep -REl '[-][*]- coding: utf-8 -[*]-' plugins/ tests/); do
sed -e '/^# -\*- coding: utf-8 -\*-/d' -i $i;
done
* Remove __metaclass__ = type:
for i in $(grep -REl '__metaclass__ = type' plugins/ tests/); do
sed -e '/^__metaclass__ = type/d' -i $i;
done
2025-10-10 19:52:04 +02:00
Alexei Znamensky
5f471b8e5b
refactor dict from literal list ( #10891 )
...
* refactor dict from literal list
* add changelog frag
2025-10-10 19:09:10 +02:00
Thomas Sjögren
14a858fd9c
random_string: replace random.SystemRandom() with secrets.SystemRandom() ( #10893 )
...
* random_string: replace random.SystemRandom() with secrets.SystemRandom()
Signed-off-by: Thomas Sjögren <konstruktoid@users.noreply.github.com>
* add the forgotten blank line
Signed-off-by: Thomas Sjögren <konstruktoid@users.noreply.github.com>
* Update changelogs/fragments/replace-random-with-secrets.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
* readd the description
Signed-off-by: Thomas Sjögren <konstruktoid@users.noreply.github.com>
* Update changelogs/fragments/replace-random-with-secrets.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
---------
Signed-off-by: Thomas Sjögren <konstruktoid@users.noreply.github.com>
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-10-10 19:08:16 +02:00
Chris
30894f4144
github_app_access_token: add support for GitHub Enterprise Server ( #10880 )
...
* github_app_access_token: add support for GitHub Enterprise Server (#10879 )
Add option to specify api endpoint for a GitHub Enterprise Server.
If option is not specified, defaults to https://api.github.com .
* refactor: apply changes as suggested by felixfontein
* docs: fix nox check error and type-o
nox check: plugins/lookup/github_app_access_token.py:57:1: DOCUMENTATION: error: too many blank lines (1 > 0) (empty-lines)
* refactor: apply changes as suggested by russoz
* refactor: apply changes as suggested by felixfontein
2025-10-06 18:14:24 +02:00
Felix Fontein
6cd4665412
Avoid six in plugin code ( #10873 )
...
Avoid six in plugin code.
2025-10-05 06:56:32 +02:00
Sebastian Damm
9d0150b2c3
[doc] update requirements for all consul modules/lookups ( #10863 )
...
* [doc] update requirements for consul_kv module
python-consul has been unmaintained for a while. It uses a legacy way of passing the Consul token when sending requests. This leads to warning messages in Consul log, and will eventually break communication. Using the maintained py-consul library ensures compatibility to newer Consul versions.
* [doc] replace all python-consul occurrences with py-consul
* [fix] tests and possible pip server errors
* [chore] remove referencce to python-consul in comment
---------
Co-authored-by: Sebastian Damm <sebastian.damm@pascom.net>
2025-10-03 07:09:20 +02:00
Felix Fontein
c1e877d254
github_app_access_token: fix compatibility import of jwt ( #10810 )
...
Fix compatibility import of jwt.
2025-09-13 09:17:16 +02:00
Felix Fontein
4a70d4091d
Deprecate hiera lookup ( #10779 )
...
Deprecate hiera lookup.
2025-08-31 16:15:20 +02:00
Abhijeet Kasurde
b5a2c5812c
random_string: Specify seed while generating random string ( #10710 )
...
* random_string: Specify seed while generating random string
* Allow user to specify seed to generate random string
Fixes : #5362
Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>
* Apply suggestions from code review
Co-authored-by: Felix Fontein <felix@fontein.de>
---------
Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-08-27 22:00:44 +02:00
weisheng-p
65bc47068e
GitHub app access token lookup: allow to use PyJWT + cryptography instead of jwt ( #10664 )
...
* Fix issue #10299
* Fix issue #10299
* Fix blank lines
* Fix blank lines
* Add compatibility changes for jwt
* Bump to a higher magic number
* Update change log fragment
* Update changelogs/fragments/10299-github_app_access_token-lookup.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update changelogs/fragments/10299-github_app_access_token-lookup.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update changelogs/fragments/10299-github_app_access_token-lookup.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update plugins/lookup/github_app_access_token.py
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update plugins/lookup/github_app_access_token.py
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update requirement document
* Remove a whitespace
---------
Co-authored-by: Bruno Lavoie <bruno.lavoie@dti.ulaval.ca>
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-08-23 18:36:53 +02:00
Felix Fontein
47e8a3c193
ansible-core 2.20: avoid deprecated functionality ( #10687 )
...
Avoid deprecated functionality.
2025-08-18 06:25:23 +02:00
Felix Fontein
8960a57d53
Add binary_file lookup ( #10616 )
...
* Add binary_file lookup.
* Remove sentence on deprecation.
2025-08-10 13:32:35 +02:00
Abhijeet Kasurde
9155bc2e53
random_string: add docs to use min_* ( #10610 )
...
* random_string: add docs to use min_*
* Update docs for min_* usage
Fixes : #10576
Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>
* Review requests
Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>
---------
Signed-off-by: Abhijeet Kasurde <Akasurde@redhat.com>
2025-08-06 20:44:26 +02:00
Felix Fontein
14f706c5dd
merge_variables lookup: avoid deprecated Templar.set_temporary_context ( #10566 )
...
Avoid deprecated Templar.set_temporary_context.
2025-08-03 12:54:14 +02:00
Felix Fontein
16d6e4a8e5
dependent lookup: avoid deprecated ansible-core 2.19 functionality ( #10359 )
...
* Avoid deprecated ansible-core 2.19 functionality.
* Adjust unit tests.
2025-07-08 06:40:54 +02:00
Alexei Znamensky
329c2222fc
fix style in plugins ( #10303 )
2025-07-02 01:15:01 +12:00
Felix Fontein
d032de3b16
Adjust YAML in plugin docs ( #10234 )
...
* Adjust YAML in plugin docs.
* Update ignore.txt.
* Forgot two indents.
* adjust connection plugins
adjust filter plugins
adjust inventory plugins
adjust lookup plugins
* Re-add YAML document start.
---------
Co-authored-by: Alexei Znamensky <russoz@gmail.com>
2025-06-16 17:46:01 +02:00
Felix Fontein
acbb59d3d8
Add changes by russoz ( #10192 )
...
* remove references/test for ansible-core<2.16
* Add/update changelog fragment.
* Undo change to ansible_galaxy_install.
* Remove unnecessary import.
---------
Co-authored-by: Alexei Znamensky <russoz@gmail.com>
2025-06-02 20:10:42 +02:00
Felix Fontein
387ed81cdf
Drop support for ansible-core 2.15; update CI to move ansible-core 2.16 to EOL CI; remove compat code for ansible-core < 2.14 ( #10160 )
...
* Drop support for ansible-core 2.15. Move 2.16 to EOL CI.
* Remove compatibility code for older ansible-core versions.
* Remove commented out parts.
2025-06-02 06:24:34 +02:00
Felix Fontein
9d7b3f13bd
Remove deprecated features and plugins for 11.0.0 ( #10126 )
...
* Bump version to 11.0.0.
* Removed deprecated plugins/modules.
* Remove _init_session().
* Remove ack_venv_creation_deprecation.
* Change behavior of state.
* Remove value reading.
* Remove list_all.
* Remove various deprecated module helper things.
* Change default of proxmox's update parameter.
* Fix constructor command order.
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
* MH: adjust guide
---------
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
Co-authored-by: Alexei Znamensky <russoz@gmail.com>
2025-05-19 18:11:39 +02:00
Alexei Znamensky
299172d27b
fixed hidden warnings from extra tests - batch 2 ( #10027 )
...
* fixed hidden warnings from extra tests - batch 2
* remove multiple yaml doc markers from EXAMPLE blocks
* Apply suggestions from code review
Co-authored-by: Felix Fontein <felix@fontein.de>
* Apply suggestions from code review
* Apply suggestions from code review
* dig: adjust markup for return suboptions
* Update plugins/lookup/dig.py
---------
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-05-04 14:05:32 +02:00
Alexei Znamensky
e9997e08ed
deprecation: manifold ( #10028 )
...
* deprecation: manifold
* add changelog frag
* restore test file
2025-04-21 12:23:35 +02:00
Felix Fontein
04cfce78ea
Make ready for data tagging ( #9833 )
...
* Fix dependent lookup.
* Fix ansible_type plugin utils and adjust documentation of reveal_ansible_type filter and ansible_type test.
* Fix diy callback plugin.
* Adjust to Data Tagging.
* Vendor and use internal code from ansible-core to fix YAML callback.
Ref: https://github.com/ansible/ansible/issues/84781
2025-04-14 19:04:26 +02:00
Manuel Luzarreta
105ae0566a
bugfix - Prevent passwordstore lookup to create subkey when create == false ( #9106 )
...
Fixes #9105
Apply suggestion
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-02-19 21:36:29 +01:00
Jonas
410999dffa
bitwarden lookup: add options to filter by collection_name and validate number of results ( #9728 )
...
* feat(lookups/bitwarden): add collection_name filter
* feat(lookups/bitwarden): add result_count check
* docs(lookups/bitwarden): add changelog fragment
* Update changelogs/fragments/9728-bitwarden-collection-name-filter.yml
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update plugins/lookup/bitwarden.py
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update plugins/lookup/bitwarden.py
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update plugins/lookup/bitwarden.py
Co-authored-by: Felix Fontein <felix@fontein.de>
* Update plugins/lookup/bitwarden.py
Co-authored-by: Felix Fontein <felix@fontein.de>
* fix(lookups/bitwarden): fix result_count check for multiple terms
* fix(lookups/bitwarden): Enforce mutual exclusion of 'collection_name' and 'collection_id'
* formatting(lookups/bitwarden): remove trailing whitespace
* Update plugins/lookup/bitwarden.py
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
* Update plugins/lookup/bitwarden.py
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
* Update plugins/lookup/bitwarden.py
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
* formatting(lookups/bitwarden): remove trailing whitespace
---------
Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2025-02-16 12:11:04 +01:00
Felix Fontein
4e0de41a85
onepassword_doc: fix 1Password Connect support ( #9625 )
...
Fix 1Password Connect support for onepassword_doc.
2025-02-10 21:54:51 +01:00
Felix Fontein
8749da7756
onepassword_ssh_key: avoid inheriting from OnePassCLIv2 ( #9633 )
...
* Avoid inheriting from OnePassCLIv2.
* Add changelog fragment.
2025-01-27 07:24:14 +01:00
Mohammed Babelly
25a262bdcf
Create onepassword_ssh_key plugin ( #9580 )
...
* add 1password_ssh_key lookup
* refactor
* Delete onepassword_ssh_key.py
* Revert "Delete onepassword_ssh_key.py"
This reverts commit e17ff7e232 .
* Delete onepassword_ssh_key.py
* add tests
* add test license
* cleanup
* refactor
* Apply suggestions from code review
Co-authored-by: Felix Fontein <felix@fontein.de>
* fix indentation
* fix RETURN indentation
* use get_option to get ssh_format
* linting
* update project year in copyright
* add plugin to BOTMETA.yml
* use OnePassCLIv2's get_raw and use OnePass's token
---------
Co-authored-by: Felix Fontein <felix@fontein.de>
2025-01-26 15:24:17 +01:00
Felix Fontein
ec585392e5
Docs: fix its vs. it's ( #9442 )
...
* Fix its vs. it's.
* Improvements from review.
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
* Improve formulations.
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
---------
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2024-12-29 13:29:58 +01:00
Felix Fontein
2203560867
plugins: replace to_native(), to_text(), str() with str() where possible or leave it away in f-string formatting ( #9379 )
...
* Replace to_native(), to_text(), str() with str() where possible or leave it away in f-string formatting.
* Improve formulation.
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
* Use more f-strings.
* Remove unicode prefix for strings.
---------
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2024-12-28 22:47:18 +01:00
Felix Fontein
61b2304f4d
dig: handle NoNameservers exception ( #9363 )
...
Handle NoNameservers.
2024-12-26 17:01:35 +01:00
Alexei Znamensky
6cd3f79e19
lookup plugins: use f-strings ( #9324 )
...
* lookup plugins: use f-strings
* add changelog frag
* manual change for few occurrences
* Update plugins/lookup/dependent.py
Co-authored-by: Felix Fontein <felix@fontein.de>
* adjustment from review
* no f-string for you
* Update plugins/lookup/dependent.py
Co-authored-by: Felix Fontein <felix@fontein.de>
---------
Co-authored-by: Felix Fontein <felix@fontein.de>
2024-12-25 09:48:06 +01:00
Ian Richardson
5a9715874a
Update docs for github_app_access_token.py ( #9152 )
...
* Update github_app_access_token.py
updating docs - github_token missing {{ }}
* Update plugins/lookup/github_app_access_token.py
Co-authored-by: Felix Fontein <felix@fontein.de>
---------
Co-authored-by: Felix Fontein <felix@fontein.de>
2024-11-20 19:07:06 +01:00
Felix Fontein
9553dd9ddf
Stop using ansible.module_utils.compat.importlib ( #9085 )
...
Stop using ansible.module_utils.compat.importlib.
2024-10-31 06:49:11 +01:00