<!--- Verify first that your issue is not already reported on GitHub -->
<!--- Also test if the latest release and devel branch are affected too -->
<!--- Complete *all* sections as described, this form is processed automatically -->

##### SUMMARY

Ansible can't parse unicode correctly, when reading template

##### COMPONENT NAME

template

##### ANSIBLE VERSION

```
ansible 2.9.2
  config file = None
  configured module search path = [u'/home/home/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/lib/python2.7/site-packages/ansible
  executable location = /usr/bin/ansible
  python version = 2.7.5 (default, Aug  7 2019, 00:51:29) [GCC 4.8.5 20150623 (Red Hat 4.8.5-39)]
```

##### OS / ENVIRONMENT
 
CentOS Linux release 7.7.1908 (Core)

##### STEPS TO REPRODUCE

vars.yml

```yaml
some_var: "test"
```

templates/example.json.j2

```json
{
  "something": "test",
  "this-breaks-key": "This breaks the whole file, because of: ü§",
  "another-key": "{{ some_var }}"
}
```

```yaml
- hosts: test
  connection: local
  vars:
    reference: "{{ lookup('template', 'templates/example.json.j2') }}"
    delta: {}
  tasks:
    - name: Test | Get configuration changes
      set_fact:
        delta: "{{ delta | combine({item.key: item.value}, recursive=true) }}"
      loop: "{{ reference | dict2items }}"
```

##### EXPECTED RESULTS

The valid json file should be correctly parsed and unicode should not be a problem in 2020.

Everything works just as expected, when `unicode chars` are removed.

##### ACTUAL RESULTS
<!--- Describe what actually happened. If possible run with extra verbosity (-vvvv) -->

```json
{"msg": "dict2items requires a dictionary, got <type 'unicode'> instead."}
```

The underlying exception that causes this behavior:

```
Traceback (most recent call last):
  File "/Users/matt/projects/ansibledev/ansible/lib/ansible/template/safe_eval.py", line 142, in safe_eval
    compiled = compile(parsed_tree, expr, 'eval')
UnicodeEncodeError: 'ascii' codec can't encode characters in position 87-88: ordinal not in range(128)
```
"""Recursively convert dict keys and values to byte str
    Specialized for json return because this only handles, lists, tuples,
    and dict container types (the containers that the json module returns)
    """
    if isinstance(d, binary_type):
        
        return to_text(d, encoding=encoding, errors=errors)
    elif isinstance(d, dict):
        return dict(container_to_text(o, encoding, errors) for o in iteritems(d))
    elif isinstance(d, list):
        return [container_to_text(o, encoding, errors) for o in d]
    elif isinstance(d, tuple):
        return tuple(container_to_text(o, encoding, errors) for o in d)
    else:
        return d