From 18b4251bf4f689923a19bf7fbc50d5c2ea422b21 Mon Sep 17 00:00:00 2001 From: Ian Wienand Date: Mon, 31 Aug 2020 16:22:57 +1000 Subject: [PATCH] Use SETUPTOOLS_USE_DISTUTILS=stdlib for global pip installs A new setuptools release has changed the way pip installs are done, see [0]. With this change we switch back to using the distro method for global pip installs. Temporarily make grenade jobs non-voting in order to allow this patch to be backported. [0] http://lists.openstack.org/pipermail/openstack-discuss/2020-August/016905.html Change-Id: I5d8aa0e58e0409c54451b51de5eb70ba9a68d849 --- .zuul.yaml | 18 ++++++++++-------- inc/python | 8 +++++++- 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/.zuul.yaml b/.zuul.yaml index d387b0dd50..acf26e2ca8 100644 --- a/.zuul.yaml +++ b/.zuul.yaml @@ -705,10 +705,12 @@ voting: false irrelevant-files: *dsvm-irrelevant-files - grenade: + voting: false irrelevant-files: - ^.*\.rst$ - ^doc/.*$ - neutron-grenade-multinode: + voting: false irrelevant-files: - ^.*\.rst$ - ^doc/.*$ @@ -750,18 +752,18 @@ - devstack-multinode - devstack-unit-tests - openstack-tox-bashate - - neutron-grenade-multinode: - irrelevant-files: - - ^.*\.rst$ - - ^doc/.*$ + # - neutron-grenade-multinode: + # irrelevant-files: + # - ^.*\.rst$ + # - ^doc/.*$ - neutron-tempest-linuxbridge: irrelevant-files: - ^.*\.rst$ - ^doc/.*$ - - grenade: - irrelevant-files: - - ^.*\.rst$ - - ^doc/.*$ + # - grenade: + # irrelevant-files: + # - ^.*\.rst$ + # - ^doc/.*$ - openstacksdk-functional-devstack: irrelevant-files: - ^.*\.rst$ diff --git a/inc/python b/inc/python index f98d28d995..8941fd038d 100644 --- a/inc/python +++ b/inc/python @@ -170,7 +170,13 @@ function pip_install { local sudo_pip="env" else local cmd_pip="python$PYTHON3_VERSION -m pip" - local sudo_pip="sudo -H LC_ALL=en_US.UTF-8" + # See + # https://github.com/pypa/setuptools/issues/2232 + # http://lists.openstack.org/pipermail/openstack-discuss/2020-August/016905.html + # this makes setuptools >=50 use the platform distutils. + # We only want to do this on global pip installs, not if + # installing in a virtualenv + local sudo_pip="sudo -H LC_ALL=en_US.UTF-8 SETUPTOOLS_USE_DISTUTILS=stdlib " echo "Using python $PYTHON3_VERSION to install $package_dir" fi