### Summary

Problem detected on community.grafana collection.
The CI fails because of the following error:
```
ERROR: Ansible could not initialize the preferred locale: unsupported locale setting
```

[Link to the github actions logs](https://github.com/ansible-collections/community.grafana/runs/7376131642?check_suite_focus=true).

Edit: I edited my workflow to let all the job run and disable fail-fast. It makes it visible that issue only happens on devel:
https://github.com/ansible-collections/community.grafana/runs/7376236257?check_suite_focus=true

### Issue Type

Bug Report

### Component Name

core ?

### Ansible Version

```console
devel

(`pip install https://github.com/ansible/ansible/archive/devel.tar.gz`)
```


### Configuration

```console
N/A
```


### OS / Environment

ubuntu 20.04.4

### Steps to Reproduce

<!--- Paste example playbooks or commands between quotes below -->
On `community.grafana` collection
```yaml (paste below)
ansible-test integration -v --color --retry-on-error --requirements --python 3.8 --continue-on-error --diff --coverage
```



### Expected Results

No error related to locale.

### Actual Results

```console
ERROR: Ansible could not initialize the preferred locale: unsupported locale setting
```


### Code of Conduct

- [X] I agree to follow the Ansible Code of Conduct
"""Create and return a list of tuples associating generic_base_type derived types with a corresponding base_type derived type."""
    return [item for item in [(get_generic_type(sc_type, generic_base_type), sc_type) for sc_type in get_subclasses(base_type)] if item[1]]
def get_type_map(base_type, generic_base_type):  
    """Create and return a mapping of generic_base_type derived types to base_type derived types."""
    return {item[0]: item[1] for item in get_type_associations(base_type, generic_base_type)}
def verify_sys_executable(path):  
    """Verify that the given path references the current Python interpreter. If not, return the expected path, otherwise return None."""
    if path == sys.executable:
        return None
    if os.path.realpath(path) == os.path.realpath(sys.executable):
        return None
    expected_executable = raw_command([path, '-c', 'import sys; print(sys.executable)'], capture=True)[0]
    if expected_executable == sys.executable:
        return None
    return expected_executable
def type_guard(sequence: t.Sequence[t.Any], guard_type: t.Type[C]) -> TypeGuard[t.Sequence[C]]:
    """
    Raises an exception if any item in the given sequence does not match the specified guard type.
    Use with assert so that type checkers are aware of the type guard.
    """
    invalid_types = set(type(item) for item in sequence if not isinstance(item, guard_type))
    if not invalid_types:
        return True
    invalid_type_names = sorted(str(item) for item in invalid_types)
    raise Exception(f'Sequence required to contain only {guard_type} includes: {", ".join(invalid_type_names)}')
display = Display()