You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Runner's stdout sampling is subject to a child process shutdown race when pexpect is in the mix, arguably because it's misusing the pexpect logfile_read callback:
If the child shuts down between a timed-out child.expect() and the next loop iteration's child.isalive(), any output sent by the child in the meantime will be lost. A final stdout stream pump via child.expect() until EOF is reached is necessary to ensure all data is fed through the stdout interposer. This can result in missing events- usually playbook_on_stats. The problem is exacerbated by delays longer than the pexpect timeout (default 5s) near the end of playbook execution (eg, profiling callback aggregation).
The text was updated successfully, but these errors were encountered:
EDIT: proposed fix at #1331
Runner's stdout sampling is subject to a child process shutdown race when pexpect is in the mix, arguably because it's misusing the pexpect
logfile_read
callback:ansible-runner/src/ansible_runner/runner.py
Lines 316 to 342 in e0371d6
If the child shuts down between a timed-out
child.expect()
and the next loop iteration'schild.isalive()
, any output sent by the child in the meantime will be lost. A final stdout stream pump viachild.expect()
until EOF is reached is necessary to ensure all data is fed through the stdout interposer. This can result in missing events- usuallyplaybook_on_stats
. The problem is exacerbated by delays longer than the pexpect timeout (default 5s) near the end of playbook execution (eg, profiling callback aggregation).The text was updated successfully, but these errors were encountered: