ansible/ansible — pull request #7473 by shirou (2014-05-21 14:49:56+00:00)
Title: fix UnicodeEncodeError when prompt is unicode.

UnicodeEncodeError is occured when prompt text is unicode.

```
File "/home/blah/Works/VEnvs/ansible/lib/python2.7/site-packages/ansible/callbacks.py", line 667, in on_vars_prompt
result = prompt(msg, private)
File "/home/blah/Works/VEnvs/ansible/lib/python2.7/site-packages/ansible/callbacks.py", line 655, in prompt
return getpass.getpass(prompt)
File "/usr/local/lib/python2.7/getpass.py", line 71, in unix_getpass
passwd = _raw_input(prompt, stream, input=input)
File "/usr/local/lib/python2.7/getpass.py", line 128, in _raw_input
prompt = str(prompt)
```

```
---
- hosts: local
gather_facts: no
vars_prompt:
- name: hello
prompt: "Ĥȅľľő Ŵőŕľď!"
tasks:
- debug: msg=hello
```

This PR fixes this using encode(sys.stdout.encoding).

related PR: #3042