From 1e0f1830f71cc62ec0986f555a2b253562771756 Mon Sep 17 00:00:00 2001 From: Ojas Joshi Date: Mon, 31 Aug 2020 16:14:48 -0700 Subject: [PATCH 1/9] Blacklisting setuptools v50.0.0 --- ros_bootstrap.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ros_bootstrap.sh b/ros_bootstrap.sh index 51f700c..b671b54 100755 --- a/ros_bootstrap.sh +++ b/ros_bootstrap.sh @@ -3,7 +3,7 @@ set -xe # Set up ROS APT and install basic dependencies (rosdep, rosinstall). Must have ROS_VERSION set when called. sudo apt-get update && sudo apt-get install -q -y dirmngr curl gnupg2 lsb-release zip python3-pip python3-apt dpkg -sudo -H pip3 install -U setuptools +sudo -H pip3 install -U setuptools!=50.0.0 if [ "${ROS_VERSION}" == "1" ]; then echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/ros-latest.list From d2f56511dab42fa4d273f8c4c7a50e5a689e796b Mon Sep 17 00:00:00 2001 From: Ojas Joshi Date: Mon, 31 Aug 2020 17:47:57 -0700 Subject: [PATCH 2/9] blacklisting setuptools==50.0.0 in non-sa ros1 ros2 docker env build scripts --- ros1_build.sh | 2 +- ros2_build.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ros1_build.sh b/ros1_build.sh index ad74c3e..1bb5786 100755 --- a/ros1_build.sh +++ b/ros1_build.sh @@ -3,7 +3,7 @@ set -xe # install dependencies sudo apt-get update && sudo apt-get install -y lcov python3-pip python-rosinstall libgtest-dev cmake && rosdep update -sudo apt-get update && sudo apt-get install -y python3-colcon-common-extensions && sudo -H pip3 install -U setuptools +sudo apt-get update && sudo apt-get install -y python3-colcon-common-extensions && sudo -H pip3 install -U setuptools!=50.0.0 # nosetests needs coverage for Python 2 sudo apt-get install python-pip -y && sudo -H pip install -U coverage # enable Python coverage "https://github.com/ros/catkin/blob/kinetic-devel/cmake/test/nosetests.cmake#L59" diff --git a/ros2_build.sh b/ros2_build.sh index 4a86671..9102067 100755 --- a/ros2_build.sh +++ b/ros2_build.sh @@ -3,7 +3,7 @@ set -xe # install dependencies sudo apt-get update && sudo apt-get install -y python3 python3-pip lcov cmake && rosdep update -sudo apt-get update && sudo apt-get install -y python3-rosinstall python3-colcon-common-extensions && sudo -H pip3 install -U setuptools coverage pytest +sudo apt-get update && sudo apt-get install -y python3-rosinstall python3-colcon-common-extensions && sudo -H pip3 install -U setuptools!=50.0.0 coverage pytest apt list --upgradable 2>/dev/null | awk {'print $1'} | sed 's/\/.*//g' | grep ${ROS_DISTRO} | xargs sudo apt-get install -y REPO_NAME=$(basename -- ${TRAVIS_BUILD_DIR}) From c5d525403be620a843b120e9c14e6faa15132e39 Mon Sep 17 00:00:00 2001 From: Ojas Joshi Date: Tue, 1 Sep 2020 09:15:00 -0700 Subject: [PATCH 3/9] Adding blacklisted 50.0.0 installation after colcon-bundle pip installation --- ros1_sa_build.sh | 2 ++ ros_bootstrap.sh | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/ros1_sa_build.sh b/ros1_sa_build.sh index 623b839..dd49f73 100755 --- a/ros1_sa_build.sh +++ b/ros1_sa_build.sh @@ -8,6 +8,8 @@ ROS_BOOTSTRAP_SCRIPT=${SCRIPT_DIR}/ros_bootstrap.sh "${ROS_BOOTSTRAP_SCRIPT}" sudo apt-get update && sudo apt-get install --no-install-recommends -y python3-colcon-common-extensions ros-${ROS_DISTRO}-ros-base sudo -H pip3 install -U colcon-bundle colcon-ros-bundle +# colcon-bundle setup requirements reinstalls the latest version(50.0.0) of setuptools. +sudo -H pip3 install -U setuptools!=50.0.0 --force-reinstall COMMON_SA_BUILD_SCRIPT=${SCRIPT_DIR}/common_sa_build.sh . "${COMMON_SA_BUILD_SCRIPT}" diff --git a/ros_bootstrap.sh b/ros_bootstrap.sh index b671b54..2eea2fb 100755 --- a/ros_bootstrap.sh +++ b/ros_bootstrap.sh @@ -3,7 +3,7 @@ set -xe # Set up ROS APT and install basic dependencies (rosdep, rosinstall). Must have ROS_VERSION set when called. sudo apt-get update && sudo apt-get install -q -y dirmngr curl gnupg2 lsb-release zip python3-pip python3-apt dpkg -sudo -H pip3 install -U setuptools!=50.0.0 +# sudo -H pip3 install -U setuptools!=50.0.0 if [ "${ROS_VERSION}" == "1" ]; then echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/ros-latest.list From 6ceae3c05cd86457551ddbb4042d4e8708c04a4e Mon Sep 17 00:00:00 2001 From: Anson Wong Date: Tue, 1 Sep 2020 11:27:37 -0700 Subject: [PATCH 4/9] Remove comment --- ros_bootstrap.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/ros_bootstrap.sh b/ros_bootstrap.sh index 2eea2fb..95b369b 100755 --- a/ros_bootstrap.sh +++ b/ros_bootstrap.sh @@ -3,7 +3,6 @@ set -xe # Set up ROS APT and install basic dependencies (rosdep, rosinstall). Must have ROS_VERSION set when called. sudo apt-get update && sudo apt-get install -q -y dirmngr curl gnupg2 lsb-release zip python3-pip python3-apt dpkg -# sudo -H pip3 install -U setuptools!=50.0.0 if [ "${ROS_VERSION}" == "1" ]; then echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/ros-latest.list From 952dbd9d21e48c3683d310cb6f1292832c97193f Mon Sep 17 00:00:00 2001 From: Anson Wong Date: Tue, 1 Sep 2020 13:11:55 -0700 Subject: [PATCH 5/9] Use recommended workaround --- ros1_sa_build.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/ros1_sa_build.sh b/ros1_sa_build.sh index dd49f73..2da4ed8 100755 --- a/ros1_sa_build.sh +++ b/ros1_sa_build.sh @@ -10,6 +10,8 @@ sudo apt-get update && sudo apt-get install --no-install-recommends -y python3-c sudo -H pip3 install -U colcon-bundle colcon-ros-bundle # colcon-bundle setup requirements reinstalls the latest version(50.0.0) of setuptools. sudo -H pip3 install -U setuptools!=50.0.0 --force-reinstall +# temp workaround for setuptools 50.0.0 issue +export SETUPTOOLS_USE_DISTUTILS=stdlib COMMON_SA_BUILD_SCRIPT=${SCRIPT_DIR}/common_sa_build.sh . "${COMMON_SA_BUILD_SCRIPT}" From c33990d0b6526c4a8124034cca90bd43f7225ed0 Mon Sep 17 00:00:00 2001 From: Ojas Joshi Date: Tue, 1 Sep 2020 13:13:09 -0700 Subject: [PATCH 6/9] Adding force-reinstall for setuptools installation --- ros1_build.sh | 2 +- ros1_sa_build.sh | 2 -- ros_bootstrap.sh | 1 + 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/ros1_build.sh b/ros1_build.sh index 1bb5786..761ba0d 100755 --- a/ros1_build.sh +++ b/ros1_build.sh @@ -3,7 +3,7 @@ set -xe # install dependencies sudo apt-get update && sudo apt-get install -y lcov python3-pip python-rosinstall libgtest-dev cmake && rosdep update -sudo apt-get update && sudo apt-get install -y python3-colcon-common-extensions && sudo -H pip3 install -U setuptools!=50.0.0 +sudo apt-get update && sudo apt-get install -y python3-colcon-common-extensions && sudo -H pip3 install -U setuptools!=50.0.0 --force-reinstall # nosetests needs coverage for Python 2 sudo apt-get install python-pip -y && sudo -H pip install -U coverage # enable Python coverage "https://github.com/ros/catkin/blob/kinetic-devel/cmake/test/nosetests.cmake#L59" diff --git a/ros1_sa_build.sh b/ros1_sa_build.sh index dd49f73..623b839 100755 --- a/ros1_sa_build.sh +++ b/ros1_sa_build.sh @@ -8,8 +8,6 @@ ROS_BOOTSTRAP_SCRIPT=${SCRIPT_DIR}/ros_bootstrap.sh "${ROS_BOOTSTRAP_SCRIPT}" sudo apt-get update && sudo apt-get install --no-install-recommends -y python3-colcon-common-extensions ros-${ROS_DISTRO}-ros-base sudo -H pip3 install -U colcon-bundle colcon-ros-bundle -# colcon-bundle setup requirements reinstalls the latest version(50.0.0) of setuptools. -sudo -H pip3 install -U setuptools!=50.0.0 --force-reinstall COMMON_SA_BUILD_SCRIPT=${SCRIPT_DIR}/common_sa_build.sh . "${COMMON_SA_BUILD_SCRIPT}" diff --git a/ros_bootstrap.sh b/ros_bootstrap.sh index 95b369b..b8ad7e2 100755 --- a/ros_bootstrap.sh +++ b/ros_bootstrap.sh @@ -3,6 +3,7 @@ set -xe # Set up ROS APT and install basic dependencies (rosdep, rosinstall). Must have ROS_VERSION set when called. sudo apt-get update && sudo apt-get install -q -y dirmngr curl gnupg2 lsb-release zip python3-pip python3-apt dpkg +sudo -H pip3 install -U setuptools!=50.0.0 --force-reinstall if [ "${ROS_VERSION}" == "1" ]; then echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/ros-latest.list From 1414f0f8ae20b2722ad1459eb77ffae73b6b60fd Mon Sep 17 00:00:00 2001 From: Anson Wong Date: Tue, 1 Sep 2020 13:48:27 -0700 Subject: [PATCH 7/9] Pin 49.3.0 for setuptools --- ros1_sa_build.sh | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/ros1_sa_build.sh b/ros1_sa_build.sh index 2da4ed8..5370a97 100755 --- a/ros1_sa_build.sh +++ b/ros1_sa_build.sh @@ -9,9 +9,8 @@ ROS_BOOTSTRAP_SCRIPT=${SCRIPT_DIR}/ros_bootstrap.sh sudo apt-get update && sudo apt-get install --no-install-recommends -y python3-colcon-common-extensions ros-${ROS_DISTRO}-ros-base sudo -H pip3 install -U colcon-bundle colcon-ros-bundle # colcon-bundle setup requirements reinstalls the latest version(50.0.0) of setuptools. -sudo -H pip3 install -U setuptools!=50.0.0 --force-reinstall -# temp workaround for setuptools 50.0.0 issue -export SETUPTOOLS_USE_DISTUTILS=stdlib +# pin the latest tested version (49.3.0) +sudo -H pip3 install -U setuptools==49.3.0 --force-reinstall COMMON_SA_BUILD_SCRIPT=${SCRIPT_DIR}/common_sa_build.sh . "${COMMON_SA_BUILD_SCRIPT}" From c5060f123ae1285ab5a3f625ead56a57cabe32ac Mon Sep 17 00:00:00 2001 From: Anson Wong Date: Tue, 1 Sep 2020 13:58:01 -0700 Subject: [PATCH 8/9] Pin <50.0.0 for setuptools --- ros1_sa_build.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ros1_sa_build.sh b/ros1_sa_build.sh index 5370a97..951e895 100755 --- a/ros1_sa_build.sh +++ b/ros1_sa_build.sh @@ -9,8 +9,7 @@ ROS_BOOTSTRAP_SCRIPT=${SCRIPT_DIR}/ros_bootstrap.sh sudo apt-get update && sudo apt-get install --no-install-recommends -y python3-colcon-common-extensions ros-${ROS_DISTRO}-ros-base sudo -H pip3 install -U colcon-bundle colcon-ros-bundle # colcon-bundle setup requirements reinstalls the latest version(50.0.0) of setuptools. -# pin the latest tested version (49.3.0) -sudo -H pip3 install -U setuptools==49.3.0 --force-reinstall +sudo -H pip3 install -U setuptools<50.0.0 --force-reinstall COMMON_SA_BUILD_SCRIPT=${SCRIPT_DIR}/common_sa_build.sh . "${COMMON_SA_BUILD_SCRIPT}" From 42a48727646e3b53e8ed6c0f779407e757915764 Mon Sep 17 00:00:00 2001 From: Ojas Joshi Date: Tue, 1 Sep 2020 14:55:13 -0700 Subject: [PATCH 9/9] removing --for-install tag from setuptools --- ros1_build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ros1_build.sh b/ros1_build.sh index 5f14206..f07e24e 100755 --- a/ros1_build.sh +++ b/ros1_build.sh @@ -3,7 +3,7 @@ set -xe # install dependencies sudo apt-get update && sudo apt-get install -y lcov python3-pip python-rosinstall libgtest-dev cmake && rosdep update -sudo apt-get update && sudo apt-get install -y python3-colcon-common-extensions && sudo -H pip3 install -U setuptools --force-reinstall +sudo apt-get update && sudo apt-get install -y python3-colcon-common-extensions && sudo -H pip3 install -U setuptools # NOTE: Workaround for setuptools 50.0.* (see https://github.com/pypa/setuptools/issues/2352) export SETUPTOOLS_USE_DISTUTILS=stdlib