mitogen
mitogen copied to clipboard
RuntimeWarning: line buffering (buffering=1) isn't supported in binary mode
environment:
Ubuntu 20.04 Python 3.8.2 Ansible 2.9.6 Mitogen 0.2.9 (also tried latest prerelease zip from github)
playbook:
- name: foo
hosts: localhost
connection: local
gather_facts: 'true'
result:
TASK [Gathering Facts] *********************************************************************************************************************************************************************** /usr/lib/python3.8/os.py:1023: RuntimeWarning: line buffering (buffering=1) isn't supported in binary mode, the default buffer size will be used return io.open(fd, *args, **kwargs) ok: [localhost]
This warning did not show before I upgraded to Ubuntu 20.04. I assume the change is due to a newer python version?
Frankly it's just a warning so I don't mind it. But I thought the mitogen devs may want to know about it.
Thanks for the ticket!
This is still an issue in the latest Mitogen release candidate, Ansible 2.10:
- name: File Synchronisation
ansible.posix.synchronize:
src: .
dest: /path/to/dest
TASK [File Synchronisation] *************************************************************************************************
/usr/local/Cellar/[email protected]/3.9.9/Frameworks/Python.framework/Versions/3.9/lib/python3.9/os.py:1023: RuntimeWarning: line buffering (buffering=1) isn't supported in binary mode, the default buffer size will be used
return io.open(fd, *args, **kwargs)
changed: [SFM-VPS-2]
Edit: I just switched to Mitogen master and it no longer shows. Thanks a lot.