Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix encoding errors on Windows guests (fixes: #156) #157

Merged
merged 2 commits into from
Sep 19, 2023

Conversation

leegarrett
Copy link

@leegarrett leegarrett commented Sep 1, 2023

On Windows guests the default encoding will be set to whatever default legacy encoding, not utf-8. This issue isn't apparent on English locale Windows guests, as there the encodings (ISO-8859-1, utf-8) happen to coincide.

However, on e.g. German Windows guests this will cause an encoding error when reading any output from there.

This patch ensures that the proper encoding is set on every command.

@csmart
Copy link
Collaborator

csmart commented Sep 3, 2023

@leegarrett looks good to me, thanks! Any chance you could add a changelog fragment as well at changelogs/fragments/156_fix_windows_encoding.yml or something, when you get a moment?

@Andersson007
Copy link
Contributor

@leegarrett
Copy link
Author

@leegarrett looks good to me, thanks! Any chance you could add a changelog fragment as well at changelogs/fragments/156_fix_windows_encoding.yml or something, when you get a moment?

Done!

@csmart
Copy link
Collaborator

csmart commented Sep 5, 2023

/rebuild

@Andersson007
Copy link
Contributor

/azp run CI (Remote 2.13 FreeBSD 13.0)

@azure-pipelines
Copy link

No pipelines are associated with this pull request.

@Andersson007
Copy link
Contributor

/azp run CI

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@csmart csmart mentioned this pull request Sep 5, 2023
@csmart
Copy link
Collaborator

csmart commented Sep 5, 2023

@leegarrett sorry for the noise, we were having trouble getting the pipeline to re-run.. The sanity checks are failing at the moment, I will take a look when I get some time and get back to you.

@csmart
Copy link
Collaborator

csmart commented Sep 16, 2023

@leegarrett I've fixed up the CI issues in another branch which has since merged #158, do you mind rebasing your branch when you get a moment? Thanks!

Lee Garrett added 2 commits September 18, 2023 12:49
On Windows guests the default encoding will be set to whatever
default legacy encoding, not utf-8. This issue isn't apparent on English locale
Windows guests, as there the encodings (ISO-8859-1, utf-8) happen to coincide.

However, on e.g. German Windows guests this will cause an encoding error when
reading any output from there.

This patch ensures that the proper encoding is set on every command.
@leegarrett
Copy link
Author

@leegarrett I've fixed up the CI issues in another branch which has since merged #158, do you mind rebasing your branch when you get a moment? Thanks!

And done!

@csmart csmart merged commit 69cee1d into ansible-collections:main Sep 19, 2023
@csmart
Copy link
Collaborator

csmart commented Sep 19, 2023

@leegarrett great thanks for the contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants