Commit Graph
100 Commits
Author SHA1 Message Date
f4e2e206b3 Add basic validation for action_groups (#83965)
Co-authored-by: Sloane Hertel <19572925+s-hertel@users.noreply.github.com>
2024-09-24 17:15:43 +02:00
Felix FonteinandGitHub faf446a895 runtime-metadata sanity test: do not fail deprecation version checks if galaxy.yml has empty version (#83831)
* Do not create invalid SemanticVersion objects.
* Fix SemanticVersion.parse().
* Add basic runtime-metadata tests.
2024-08-26 13:59:34 -04:00
Felix FonteinandGitHub 3d4bd79574 validate-modules: detect names set mismatch between argument spec and documentation (#83599) 2024-07-28 15:39:01 +00:00
e5309ba29f validate-modules: reject option/alias names equal up to casing belonging to different options (#83530)
* Reject option/alias names equal up to casing belonging to different options.

* Update test/lib/ansible_test/_util/controller/sanity/validate-modules/validate_modules/main.py

Co-authored-by: Sloane Hertel <19572925+s-hertel@users.noreply.github.com>
2024-07-05 19:35:54 -04:00
Felix FonteinandGitHub 7d678cbd96 Fix require_only_one. (#83511) 2024-07-02 09:36:23 -04:00
Felix FonteinandGitHub 1b42af5004 ansible-test: update http-test-container to 3.2.0 (#83469) 2024-06-18 13:46:52 -07:00
Felix FonteinandGitHub 585ef6c55e Show examples in role entrypoint argument specs. (#82671) 2024-05-01 11:27:50 -04:00
Felix FonteinandGitHub e3d4c20f6e Correctly treat separate paragraphs in top-level descriptions as separate paragraphs. (#83155) 2024-04-30 17:15:35 +02:00
Felix FonteinandGitHub c0821346fc Do not mangle plugin names in collections that start with an underscore. (#82574) 2024-03-21 19:40:46 -04:00
11d69e065f ansible-doc: restore role attributes (#82678)
* Restore role attributes.

* Add a deprecation warning for role argument specs containing attributes

Co-authored-by: Felix Fontein <felix@fontein.de>
Co-authored-by: s-hertel <19572925+s-hertel@users.noreply.github.com>
Co-authored-by: Brian Coca <bcoca@users.noreply.github.com>
2024-03-21 17:06:15 -04:00
Felix FonteinandGitHub e659c23bf2 blockinfile: do not crash when filename has no path (#81638)
* Do not crash when filename has no path.

* Clean up file after test.
2024-03-20 18:39:19 -05:00
Felix FonteinandMatt Clay 0c9f1989a7 Do not treat leading underscore in plugin names as attempted deprecation. 2024-03-20 14:01:50 -07:00
Felix FonteinandGitHub 6c647aa263 Interpret double newlines as paragraph breaks in documentation strings. (#82465) 2024-01-09 10:23:08 -05:00
Felix FonteinandGitHub 479949aad2 Fix broken docs RST reference. (#82286) 2023-11-27 10:02:20 -05:00
Felix FonteinandGitHub 7f0baabbe0 blockinfile: avoid crash on Python 3 when creating directory fails (#81662)
* Avoid crash on Python 3.

* Add a test for the crash on Python 3
2023-09-12 15:46:44 -04:00
b1b029c6b5 ansible-doc: allow to filter by more than one collection (#81450)
Make collection filters more flexible for listing collections.
Co-authored-by: Maxwell G <maxwell@gtmx.me>
2023-09-11 09:31:52 -04:00
Felix FonteinandGitHub 5dc3a2ee6d mode is a module option. (#81590) 2023-08-29 18:42:43 +01:00
Felix FonteinandGitHub b771e59793 The split filter was added in ansible-core 2.11. (#81275)
I thought it was 'hysterical' ...
2023-07-17 10:00:08 -04:00
Felix FonteinandGitHub 3e3fb26b35 Use semantic markup for modules. (#81190) 2023-07-12 10:06:32 -04:00
Felix FonteinandGitHub dce51f4ff4 Module docs fixes. (#81213) 2023-07-11 12:10:16 -04:00
Felix FonteinandGitHub 7cf15d0732 Use semantic markup for remaining plugins. (#81189)
also change  `ansible_psrp_protocol` for `protocol`  as what matters is the option itself, not what was used to set it
2023-07-10 09:30:33 -04:00
Felix FonteinandGitHub 5cf58f9a15 Use semantic markup for docs fragments (#81152) 2023-07-06 09:41:24 -04:00
Felix FonteinandGitHub 440b5fd040 Make sure that values that should be strings are actually strings. (#81029) 2023-06-13 11:19:40 -04:00
Felix FonteinandGitHub 6e137433ae Ansible 9 roadmap (#80851) 2023-06-08 09:08:52 +01:00
Felix FonteinandGitHub a5bb4c7dee ansible-test - local change detection without --fork-point (#79734) 2023-05-26 14:07:20 -07:00
Felix FonteinandGitHub 9526338273 validate-modules and docsite build: bump antsibull-docs(-parser) dependencies to new major versions (#80846)
* Bump antsibull-docs-parser version to 1.0.0.

There are no functional changes that affect the functionality used in validate-modules.

* Bump antsibull-docs to 2.0.0.
2023-05-19 16:18:59 -07:00
Felix FonteinandGitHub 70e0b1f544 docsite build: upgrade sphinx-ansible-theme and antsibull-core (#80734) 2023-05-08 15:31:53 +01:00
4029da9a9f Semantic markup docs (#80240)
Co-authored-by: Alicia Cozine <acozine@users.noreply.github.com>
Co-authored-by: Don Naro <dnaro@redhat.com>
Co-authored-by: Sandra McCann <samccann@redhat.com>
Co-authored-by: Matt Clay <matt@mystile.com>
2023-04-06 16:46:03 +01:00
Felix FonteinandGitHub 92c694372b Replace validate-modules's semantic markup parser with antsibull-docs-parser (#80406) 2023-04-05 17:45:44 -07:00
Felix FonteinandGitHub 96f7fd5539 Extend ansible-doc test with more classic markup. (#80407) 2023-04-05 16:14:35 -07:00
Felix FonteinandGitHub 2f647e9617 Implement semantic markup support for Ansible documentation in validate-modules. (#80243) 2023-03-31 14:14:35 -07:00
Felix FonteinandGitHub 0e509ecf25 Support role extension for semantic markup. (#80305) 2023-03-31 10:52:10 -04:00
Felix FonteinandGitHub cf44c84396 Add antsibull-changelog and antsibull-docs to other tools and programs page. (#80340) 2023-03-29 11:06:18 -04:00
Felix FonteinandGitHub 8600a1b927 Bump antsibull-docs version in docs-build sanity test (#80326)
* Bump antsibull-docs to 1.11.0.

* Update all requirements for the docs-build sanity test.

* Run again with Python 3.9.
2023-03-27 15:23:47 -07:00
Felix FonteinandGitHub 086ae42209 Fix URL processing. (#80295) 2023-03-27 13:54:29 -07:00
Felix FonteinandGitHub b398613120 Add support for plugin field in seealso. (#80212) 2023-03-23 17:37:09 -07:00
Felix FonteinandGitHub fafb23094e ansible-doc: fix broken seealso links in text output (#80280)
* Fix broken URLs.

* Also remove auto-generated description for modules outside ansible.builtin.
2023-03-23 13:28:05 -04:00
4ea50cef23 validate-modules: check_mode attribute and compare with supports_check_mode parameter (#80090)
Co-authored-by: Brian Scholer <1260690+briantist@users.noreply.github.com>
2023-03-23 09:59:33 -07:00
Felix FonteinandGitHub 5388f6020a validate-modules: support plugin see-also (#80244) 2023-03-23 09:48:22 -07:00
Felix FonteinandGitHub a2dc5fcc7d Implement semantic markup support for Ansible documentation in ansible-doc. (#80242) 2023-03-21 11:29:45 -04:00
Felix FonteinandGitHub 4ca3a29cd2 Bump antsibull-docs version to 1.10.0 to support semantic markup. (#80201) 2023-03-21 10:21:54 -04:00
Felix FonteinandGitHub 0793833847 ansible-test - Fix collection delegation (#79947) 2023-02-08 00:24:20 -08:00
Felix FonteinandGitHub 07f1a1b7dc docsite: bump antsibull-docs, reference collection env var index (#79666) 2023-02-02 13:17:32 -05:00
Felix FonteinandGitHub 5fb8bc3ddb Bump acme test container. (#79783) 2023-01-25 08:53:23 -08:00
Felix FonteinandGitHub 8a7185c224 Argument spec alias handling: actually report deprecated aliases in suboptions, and fix warning message in suboptions when two aliases of the same option are used (#79740)
* Normalize deprecation records.

* Fix alias deprecations in suboptions.

* Report in which option an alias warning happened for suboptions.

* Add deprecation tests for suboptions.

* Also test deprecation in list of dicts.

* Adjust unit tests for toplevel alias deprecation field name change.
2023-01-19 11:58:02 -05:00
Felix FonteinandGitHub 1852f9fab4 Support test and filter plugins in ansible-doc sanity test (#77737)
* Support test and filter plugins in ansible-doc sanity test.

* Move integration target non-filter file check_pylint.py from filter/ to plugin_utils/.
2023-01-16 14:15:55 -05:00
Felix FonteinandGitHub 1a47a21b65 Fix reporting of deprecated arguments for modules. (#79681) 2023-01-13 16:55:48 -05:00
Felix FonteinandGitHub 50a673f9e7 normal action plugin: remove superfluous code (#79690)
* Remove obsolete 'if'

The result dict returned by super.run() will never have a 'skipped' entry.
Without the if, it is more clear that wrap_async is actually defined at the end of the function.

* Remove more dead code.

The result dict will also not contain invocation.

* Remove notes.
2023-01-11 15:07:00 +01:00
Felix FonteinandGitHub 51bddd862b Document callback types in documentation (#79651) 2023-01-03 14:32:37 -05:00
Felix FonteinandGitHub 1705ec98cd ansible-doc and validate-modules: remove underscore deprecation handling for collections (#79362)
* Remove underscore deprecation handling for collections.

* Also consider ansible.legacy.
2022-11-15 10:03:47 -05:00
Felix FonteinandGitHub e0118d9d03 The attribute was renamed to 'action' and the extra data was not used anymore. (#79317) 2022-11-08 10:16:52 -05:00
Felix FonteinandGitHub 2a03c8028e Fix typo 'Ansbile'. (#79318) 2022-11-07 09:06:10 +00:00
Felix FonteinandGitHub 6e379e5d65 validate-modules: do not treat falsy non-False defaults as None (#79267)
* Do not treat falsy non-False defaults as None.

* Fix various instances of this in modules.

* Add changelog fragment.
2022-11-01 11:12:59 -04:00
Felix FonteinandGitHub bc83da9a1b Communication docs: note that editing Matrix messages causes IRC spam (#79238) 2022-10-27 11:02:56 +01:00
Felix FonteinandGitHub 9545f2e0de stable docs build: do not use YAML parsing/serialization for .deps files (#79233)
* Do not use YAML parsing/serialization for .deps files.

* Prevent crash.
2022-10-26 14:54:00 -07:00
Felix FonteinandGitHub 74b80c3193 Bump antsibull-docs version from 1.6.1 to 1.7.0. (#79071) 2022-10-26 15:26:34 -04:00
6d0aeac1e1 Do not crash templating when filter/test name is not a valid Ansible plugin name (#78913)
* Do not crash templating when filter/test name is not a valid Ansible plugin name.
* Store and re-raise KeyError if there was one.

Co-authored-by: s-hertel <19572925+s-hertel@users.noreply.github.com>
2022-10-04 09:44:00 -04:00
Felix FonteinandGitHub d93883645c Upgrade antsibull-docs to 1.6.1 (#78872)
* Bump antsibull-docs version to 1.6.0 to fully support filter docs.

* known_good_reqs.txt no longer exists.

* Bump version to 1.6.1.
2022-09-29 11:54:00 -04:00
Felix FonteinandGitHub 3423a6609f Fix docs for new commonpath and normpath filters (#78897) 2022-09-28 14:41:01 -04:00
Felix FonteinandGitHub 9aa9b4eac0 Improve filter docs (#78839) 2022-09-26 14:28:37 -04:00
Felix FonteinandGitHub 50dae8087e runtime-metadata sanity test: ensure redirects are FQCRs (#78802)
* Ensure that meta/runtime.yml redirects are FQCRs.

* Avoid crash when YAML errors without context mark happen, for example if file starts with 'foo---' instead of '---'.
2022-09-26 07:35:43 -04:00
Felix FonteinandGitHub 813c25eed1 plugin docs: look at all potential sidecar docs extensions before giving up (#78788)
* Look at all potential sidecar docs extensions before giving up.

* Do not process Python files twice.
2022-09-19 11:50:27 -04:00
Felix FonteinandGitHub 9b8e60c36d While the Python function is called ismount, the filter has the names mount and is_mount. (#78792) 2022-09-19 10:50:31 -04:00
Felix FonteinandGitHub cbffb77f57 Document some more filters (#78548) 2022-09-15 14:00:52 -04:00
Felix FonteinandGitHub 695c48957d Fix test docs (#78756) 2022-09-14 13:32:28 -04:00
fa093d8adf ansible-doc: remove manual formatting (#78668)
* remove manual formatting and make the output align closer with the original YAML

Co-authored-by: Brian Coca <brian.coca+git@gmail.com>
2022-09-08 16:02:58 -04:00
Felix FonteinandGitHub 2218b63aef Fix typo: missing 'install'. (#78448) 2022-08-04 14:26:32 -04:00
Felix FonteinandGitHub 7e634f54c3 Module/plugin docs: (#78380) 2022-08-04 12:30:38 -04:00
Felix FonteinandGitHub 733a767948 Add basic docs on how to create a collection docsite with antsibull-docs. (#78387) 2022-08-04 12:28:48 -04:00
Felix FonteinandGitHub 51f94570a6 Fix default value documentation for pipelining. (#78441) 2022-08-04 12:19:24 -04:00
614dc10ef0 With antsibull-changelog >= 0.14.0 and the sidecar docs feature, test and filter plugins are detected if they have version_added (#77871)
Co-authored-by: Brian Scholer <1260690+briantist@users.noreply.github.com>
2022-06-09 14:18:48 -04:00
Felix FonteinandGitHub 570379ef98 Do not crash callbacks if exception is not a string. (#77781) 2022-06-09 05:58:55 +10:00
Felix FonteinandGitHub ca9be6e27e Fix docs links for the steering committee (#77974) 2022-06-07 15:04:11 -04:00
Felix FonteinandGitHub 6fbc8bd2bc Fix boolean condition so that ansible-galaxy collection install works when a valid resolvelib is installed. (#77906) 2022-05-25 08:37:51 -04:00
Felix FonteinandGitHub 201aba3d0f Update PSF-license.txt to version from CPython 3.9.5. (#77805) 2022-05-17 11:46:36 -05:00
Felix FonteinandGitHub 836683a082 Stop making core docs build talk of (ansible-)'base' when meaning (ansible-)'core'. (#77728) 2022-05-11 14:04:43 -04:00
Felix FonteinandGitHub 841bdb74eb Replace antsibull with antsibull-docs (#77504) 2022-04-22 09:33:32 -04:00
Felix FonteinandMatt Clay 6216c9fc93 Fix sanity test crash. 2022-04-06 09:36:23 -07:00
Felix FonteinandGitHub 7075fa36a1 Bump requirements for antsibull to 0.42.0 (which depends on antsibull-changelog >= 0.14.0). (#77362) 2022-03-28 16:24:29 -04:00
Felix FonteinandGitHub babc26adc1 Handle errors during ansible-doc --metadata-dump more gracefully (#77035)
* Add option --no-fail-on-errors to return errors for ansible-doc --metadata-dump in JSON result instead of failing.

* Adjust changelog fragment.

* Add basic tests.
2022-03-26 09:14:57 -04:00
Felix FonteinandGitHub 4baf18c573 Remove more Python 2.x compatibility code from controller. (#77320) 2022-03-22 16:19:53 +01:00
Felix FonteinandGitHub 4d984613f5 validate-modules for plugins: do some more schema validations so that some issues that are currently reported for modules are also reported for plugins (#77268)
* Add more sanity tests on schema level (so they also work for plugins).

* Fix various issues the sanity test reported.

* Add changelog fragment.

* Fix function name.
2022-03-18 05:16:40 +10:00
Felix FonteinandGitHub e3c72230cd unarchive: fix io_buffer_size option, remove ignore.txt entry (#77271)
* Fix io_buffer_size option.

* Remove ignore.txt entry by adding action plugin only options to module's argument spec.

* Add changelog fragment.

* Adjust unit tests.
2022-03-18 05:15:13 +10:00
Felix FonteinandGitHub 0990c4ca7c Extend validate-modules to also validate plugins (#71734)
* Let validate-modules also validate plugins.

* Support 'option' in 'cli'.

* Use DOCUMENTABLE_PLUGINS instead of UNDOCUMENTED_PLUGIN_TYPES.

* Support 'keyword', clean up error codes.

* Call settings.process_errors only once; remove __version__.

* Add changelog fragment.
2022-03-04 09:08:34 -05:00
Felix FonteinandGitHub ff25b51178 Fix example return value in docstring. (#77076) 2022-02-22 10:20:39 -05:00
1f4e50f178 Ansible 6 roadmap: simplify collection inclusion process (#76932)
Co-authored-by: Andrew Klychkov <aaklychkov@mail.ru>
2022-02-03 14:30:49 -05:00
Felix FonteinandGitHub bc1e29d722 Bump antsibull version from 0.40.1 to 0.41.0 and ansible sphinx theme version to fix HTML generation in return value tables (#76759)
* Use Jinja2 comment instead of HTML comment to avoid W3C validator warning (-- inside comment).

(For those interested in the history of this: http://www.howtocreate.co.uk/SGMLComments.html#doubledash)
2022-02-03 13:53:22 -05:00
Felix FonteinandGitHub ee80e856c2 Remove more whitelist and blacklist occurances (docs only). (#76845) 2022-01-26 14:08:20 -05:00
Felix FonteinGitHubJohn R Barker <john@johnrbarker.com
ebea751805 Roadmap for Ansible 6 (#76772)
Co-authored-by: John R Barker <john@johnrbarker.com
2022-01-26 13:26:20 -05:00
Felix FonteinandGitHub c53e6d94e9 Use antsibull 0.40.1 for docsite build (#76675) 2022-01-10 16:30:47 -05:00
Felix FonteinandMatt Clay c24c479061 Fix markup. 2022-01-10 12:36:19 -08:00
Felix FonteinandGitHub 9d1898b1ef Use correct markup in documentation (#76545) 2021-12-14 15:30:58 -05:00
Felix FonteinandGitHub a734da5e82 Restore documentation on M() and R() (#76284)
* Undo most of bf9944266c, add note on where R() does not work.
Co-authored-by: Brian Scholer <1260690+briantist@users.noreply.github.com>
2021-11-11 15:26:26 -05:00
fe77bc9e3c Validate some markup in documentation in validate-modules (#76262)
* Validate some markup in documentation.

* Add changelog fragment.

* Use urlparse instead of URL regex.

* Document new error code.

Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
2021-11-11 13:44:15 -05:00
Felix FonteinandGitHub a861cb5607 ansible-core 2.12 dropped support for galaxy.yaml. (#76179) 2021-11-04 15:15:22 -04:00
Felix FonteinandGitHub c56d98e738 Fix broken M() refs. (#76202) 2021-11-02 15:22:16 -04:00
Felix FonteinandGitHub 227f4398c2 Fix choices for return values. (#76070) 2021-10-19 17:22:32 +02:00
Felix FonteinandGitHub 7a28246248 validate_modules: allow 'choices' for return values (#76009)
* Allow 'choices' for return values.
2021-10-12 11:29:27 -04:00
Felix FonteinandGitHub 8643db5ac3 Bump antsibull version to get support for attributes and CLI options (#75787)
* Bump antsibull version to get support for attributes and CLI options.

* Include fix for attributes.

* Include fix for rst_epilog collision and for #75799.
2021-09-27 16:52:05 -04:00
Felix FonteinandGitHub 67ca455829 attributes: support extra value 'not applicable' for support (#75751)
* Support two extra values 'unknown' and 'not applicable' for support.

* Simplify to only one new state: 'n/a'

* Adhere to the IBM style guide.
2021-09-23 15:02:59 -04:00