Set output to UTF8 on windows (on Python >= 3.7)

This commit is contained in:
Joe Rickerby
2020-11-13 18:57:07 +00:00
parent fba3248163
commit e8aef6962a
+5
View File
@@ -54,6 +54,11 @@ def strtobool(val: str) -> bool:
def main() -> None:
if sys.platform == 'win32' and hasattr(sys.stdout, 'reconfigure'):
# the encoding on Windows can be a 1-byte charmap, but all CIs support
# utf8, so we hardcode that
sys.stdout.reconfigure(encoding='utf8')
parser = argparse.ArgumentParser(
description='Build wheels for all the platforms.',
epilog='''