From 24ad788d3c149a7f72f69fe2ffcc000b49655abc Mon Sep 17 00:00:00 2001 From: Christian Kellner Date: Wed, 3 Aug 2022 19:06:08 +0200 Subject: [PATCH] stages/gcp.guest-agent.conf: specify encoding When opening files, always specify the encoding as this will become a linter warning in the near future. --- stages/org.osbuild.gcp.guest-agent.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stages/org.osbuild.gcp.guest-agent.conf b/stages/org.osbuild.gcp.guest-agent.conf index 74af1311..afe1bfd1 100755 --- a/stages/org.osbuild.gcp.guest-agent.conf +++ b/stages/org.osbuild.gcp.guest-agent.conf @@ -266,7 +266,7 @@ def main(tree, options): for section_id, section_content in config.items(): make_section(parser, section_id, section_content) - with open(filepath, "w") as f: + with open(filepath, "w", encoding="utf-8") as f: parser.write(f) return 0