mirror of https://github.com/ansible/ansible.git
Fix arg splitting and key/value parsing (#80030)
* Improve readability of unit test output This drops the trailing `-expectedXXX` suffixes from test names generated by parametrize. * Add more splitter unit tests This fills in code coverage gaps in the exising unit tests. * Bug fixes and code cleanup - Fix IndexError exceptions caused by parsing a leading newline, space or escaped space. - Fix an AttributeError exception in `parse_args` when parsing `None`. - Fix incorrect parsing of multi-line Jinja2 blocks, which resulted in doubling newlines. - Remove unreachable exception handlers in the `parse_kv` function. The unreachable code was verified through analysis of the code as well as use of the `atheris` fuzzer. - Remove unnecessary code in the `split_args` function. - Add an optimization to `split_args` for the empty args case. * Add unit tests for bug fixes The splitter code is now fully covered by unit tests. * Add another issue ref in changelogpull/66430/merge
parent
98d1cf7aa2
commit
da2cd157f1
@ -0,0 +1,5 @@
|
||||
bugfixes:
|
||||
- Fix exceptions caused by various inputs when performing arg splitting or parsing key/value pairs.
|
||||
Resolves issue https://github.com/ansible/ansible/issues/46379
|
||||
and issue https://github.com/ansible/ansible/issues/61497
|
||||
- Fix incorrect parsing of multi-line Jinja2 blocks when performing arg splitting or parsing key/value pairs.
|
Loading…
Reference in New Issue