{"action":"created","issue":{"url":"https://api.github.com/repos/ansible/ansible/issues/10714","labels_url":"https://api.github.com/repos/ansible/ansible/issues/10714/labels{/name}","comments_url":"https://api.github.com/repos/ansible/ansible/issues/10714/comments","events_url":"https://api.github.com/repos/ansible/ansible/issues/10714/events","html_url":"https://github.com/ansible/ansible/pull/10714","id":68501553,"number":10714,"title":"Fix #10698 by forcing the use C as a locale.","user":{"login":"mscherer","id":230335,"avatar_url":"https://avatars.githubusercontent.com/u/230335?v=3","gravatar_id":"","url":"https://api.github.com/users/mscherer","html_url":"https://github.com/mscherer","followers_url":"https://api.github.com/users/mscherer/followers","following_url":"https://api.github.com/users/mscherer/following{/other_user}","gists_url":"https://api.github.com/users/mscherer/gists{/gist_id}","starred_url":"https://api.github.com/users/mscherer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mscherer/subscriptions","organizations_url":"https://api.github.com/users/mscherer/orgs","repos_url":"https://api.github.com/users/mscherer/repos","events_url":"https://api.github.com/users/mscherer/events{/privacy}","received_events_url":"https://api.github.com/users/mscherer/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-04-14T21:23:53Z","updated_at":"2015-04-15T04:56:33Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/ansible/ansible/pulls/10714","html_url":"https://github.com/ansible/ansible/pull/10714","diff_url":"https://github.com/ansible/ansible/pull/10714.diff","patch_url":"https://github.com/ansible/ansible/pull/10714.patch"},"body":"This might have side effect on command line UI who will be in\r\nenglish, and this might cause issue to people, but I think\r\nthat's a lesser problem that having silent breakage and corruption\r\nof filename.\r\n\r\nI did minimal testing with the code ( IE, verify it doesn't break regular ansible ), and i am gonna do more test, but want to push the code to be discussed as a start."},"comment":{"url":"https://api.github.com/repos/ansible/ansible/issues/comments/93188311","html_url":"https://github.com/ansible/ansible/pull/10714#issuecomment-93188311","issue_url":"https://api.github.com/repos/ansible/ansible/issues/10714","id":93188311,"user":{"login":"ringerc","id":274337,"avatar_url":"https://avatars.githubusercontent.com/u/274337?v=3","gravatar_id":"","url":"https://api.github.com/users/ringerc","html_url":"https://github.com/ringerc","followers_url":"https://api.github.com/users/ringerc/followers","following_url":"https://api.github.com/users/ringerc/following{/other_user}","gists_url":"https://api.github.com/users/ringerc/gists{/gist_id}","starred_url":"https://api.github.com/users/ringerc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ringerc/subscriptions","organizations_url":"https://api.github.com/users/ringerc/orgs","repos_url":"https://api.github.com/users/ringerc/repos","events_url":"https://api.github.com/users/ringerc/events{/privacy}","received_events_url":"https://api.github.com/users/ringerc/received_events","type":"User","site_admin":false},"created_at":"2015-04-15T04:56:33Z","updated_at":"2015-04-15T04:56:33Z","body":"This would be a major BC break - anyone who's been using a utf-8 `LC_CTYPE` will see different, mangled filenames and file contents after this change.\r\n\r\nI don't think it's safe to do this hard-coded and by default. If you did, it'd be a little better to use `C.UTF-8` because UTF-8 locales are more common, but you'd still break lots of systems that *aren't* using UTF-8.\r\n\r\nI'd be better for Ansible to *clear* all the `LC_` env vars and `LANG` before invoking ssh, so it doesn't have them in its environment to copy them to the remote end. It would thus use the remote end's default locale. This would be a safer change to make the default, because it'd only change anything in situations where the Ansible management box's locale already differs from the remote's locale. Can you do that by setting `None` as the value of:\r\n\r\n```\r\nLANG\r\nLC_ALL\r\nLC_CTYPE\r\nLC_NUMERIC\r\nLC_TIME\r\nLC_COLLATE\r\nLC_MONETARY\r\nLC_MESSAGES\r\nLC_PAPER\r\nLC_NAME\r\nLC_ADDRESS\r\nLC_TELEPHONE\r\nLC_MEASUREMENT\r\nLC_IDENTIFICATION\r\n```\r\n\r\n?\r\n\r\nA config option to set `ansible_locale` (or whatever) to override the locale used would be handy, but it'd have to be available on a per-host basis, because you might be managing some hosts that're using UTF-8 encodings, some that're using ISO-8859-1, and some with other single byte encodings. This is common when you have a fleet of modern Linux machines plus some other UNIXes. The ability to set a default locale in ansible.cfg would make sense too, though.\r\n\r\n"}}