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
First of all thank you for providing this library!
.venv/lib/python3.12/site-packages/ansible_runner/config/runner.py line 74 sets self.runner_mode = "pexpect", without an apparent option to override it. What is the reason for doing it like this? In some of the other interface calls I do see the option to set subprocess instead.
The reason that I am asking this, is that in Python 3.12, I am getting Deprecation warnings on unit tests that use the ansible-runner: DeprecationWarning: This process (pid=xxxx) is multi-threaded, use of forkpty() may lead to deadlocks in the child.
I isolated this to this minimal example, that shows that this is due to pexpect calls:
And now my unit tests work as expected without the warning. However, I am not going to use this, as it seems like I am misusing the lib :). Can you perhaps clarify why it is that way? I searched through the latest docs, as well as for 2.4.0 (the version I am using), but could not find anything. Thank you in advance!
The text was updated successfully, but these errors were encountered:
Hi!
First of all thank you for providing this library!
.venv/lib/python3.12/site-packages/ansible_runner/config/runner.py
line 74 setsself.runner_mode = "pexpect"
, without an apparent option to override it. What is the reason for doing it like this? In some of the other interface calls I do see the option to setsubprocess
instead.The reason that I am asking this, is that in Python 3.12, I am getting Deprecation warnings on unit tests that use the ansible-runner:
DeprecationWarning: This process (pid=xxxx) is multi-threaded, use of forkpty() may lead to deadlocks in the child.
I isolated this to this minimal example, that shows that this is due to
pexpect
calls:I was able to "overwrite" the
running_mode
to usesubprocess
with this ugly hack:And now my unit tests work as expected without the warning. However, I am not going to use this, as it seems like I am misusing the lib :). Can you perhaps clarify why it is that way? I searched through the latest docs, as well as for 2.4.0 (the version I am using), but could not find anything. Thank you in advance!
The text was updated successfully, but these errors were encountered: