Skip to content

Commit 8ef850d

Browse files
audgirkassbarnea
andauthored
Avoid stdout pollution cause by ansible logging (#287)
* Remove debug information prior to json string * Update runtime.py --------- Co-authored-by: Sorin Sbarnea <ssbarnea@redhat.com>
1 parent c6aa776 commit 8ef850d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/ansible_compat/runtime.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -332,6 +332,9 @@ def run( # ruff: disable=PLR0913
332332
# from parsing its JSON output due to extra debug messages on stdout.
333333
env["ANSIBLE_DEBUG"] = "0"
334334

335+
# https://github.com/ansible/ansible-lint/issues/3522
336+
env["ANSIBLE_VERBOSE_TO_STDERR"] = "True"
337+
335338
for _ in range(self.max_retries + 1 if retry else 1):
336339
result = run_func(
337340
args,

0 commit comments

Comments
 (0)