From b42840391a3ddb74122c35954a6f66238cd149e2 Mon Sep 17 00:00:00 2001 From: Clark Boylan Date: Tue, 26 May 2020 11:23:35 -0700 Subject: [PATCH] Update pip output parsing to fix wheel mirror builds It seem that pip has updated its verbose output to say "Downloading $filename" rather than "Downloading from url $URL". We need to update our wheel mirror processing to handle this change so that it can properly remove any pypi hosted wheels before publishing to our wheel mirrors. Make it more liberal so we match pretty much any line with "Downloading" and then eventually something which looks like a whl file, just in case they keep fiddling with it. Change-Id: I7965f296cdb1241c96293edd68e84e1d3d78b331 --- roles/build-wheels/files/wheel-build.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/roles/build-wheels/files/wheel-build.sh b/roles/build-wheels/files/wheel-build.sh index 564b73749e..eb1c833da0 100755 --- a/roles/build-wheels/files/wheel-build.sh +++ b/roles/build-wheels/files/wheel-build.sh @@ -61,8 +61,8 @@ done # Parse stdout from all the build logs to build up a unique list of all # wheels downloaded from PyPI and delete them from the wheelhouse, since # this is only meant to provide built wheels which are absent from PyPI. -find ${LOGS}/build/ -name stdout -exec grep 'Downloading from URL' {} \; \ - | sed -n 's,.*Downloading from URL .*/\([^/]*\.whl\)#.*,\1,p' \ +find ${LOGS}/build/ -name stdout -exec grep 'Downloading' {} \; \ + | sed -n 's,.*Downloading.*[ /]\([^ /]*\.whl\)\([ #].*\|$\),\1,p' \ | sort -u > ${LOGS}/remove-wheels.txt pushd ${WHEELHOUSE_DIR} cat ${LOGS}/remove-wheels.txt | xargs rm