问题 Assuming the below tasks: shell: "some_script.sh" register: "some_script_result" debug: msg: "Output: {{ some_script_result.stdout_lines }} I receive the below output: "msg": "Output: [u'some_value',u'some_value2,u'some_value3]" How do I get the output to print as? "msg": Output: some_value some_value2 some_value3 Ansible version is 2.4.2. Thank you! 回答1: Try this option. You’ll love it. There's a new YAML callback plugin introduced with Ansible 2.5 — meaning any machine running Ansible 2.5.0