From c493e912631157554550dbc6db5785032a4f3a24 Mon Sep 17 00:00:00 2001 From: bwoodsend Date: Mon, 29 Mar 2021 16:53:13 +0100 Subject: [PATCH] Setup: Fix unicode path related installation errors (#5678). Pip prefers to install sdists by building a .whl then installing that. If the `wheel` package is not installed then it defaults to the older `python setup.py install` method. This older method breaks if it encounters unicode paths so ideally we want to `wheel` installed before attempting to install PyInstaller itself. PEP517's build-system.requires adds this option. Prevents errors like #5670. --- news/5678.bugfix.rst | 2 ++ pyproject.toml | 10 ++++++++++ 2 files changed, 12 insertions(+) create mode 100644 news/5678.bugfix.rst diff --git a/news/5678.bugfix.rst b/news/5678.bugfix.rst new file mode 100644 index 0000000000..6d881cf004 --- /dev/null +++ b/news/5678.bugfix.rst @@ -0,0 +1,2 @@ +Fix installation issues stemming from unicode characters in +file paths. diff --git a/pyproject.toml b/pyproject.toml index 69877c3dfe..1c105502fc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -64,3 +64,13 @@ directory = "build" name = "Bootloader build" showcontent = true + +[build-system] +# Tells pip to install wheel before trying to install PyInstaller +# from an sdist or from Github. +# Installing without wheel uses legacy `python setup.py install` +# which has issues with unicode paths. +requires = [ + "wheel", + "setuptools", +]