fix upload error?! (#1454)

* use latest setuptools 
* clear indexes also if nothing was uploaded to dc/* branches
This commit is contained in:
holger krekel
2020-05-06 17:31:43 +02:00
committed by GitHub
parent 1b921cd533
commit 4724101e75
3 changed files with 11 additions and 4 deletions

View File

@@ -37,7 +37,7 @@ echo -----------------------
# Bundle external shared libraries into the wheels
pushd $WHEELHOUSEDIR
pip3 install -U pip
pip3 install -U pip setuptools
pip3 install devpi-client
devpi use https://m.devpi.net
devpi login dc --password $DEVPI_LOGIN

View File

@@ -48,7 +48,7 @@ def run():
projectnames = get_projectnames(baseurl, username, indexname)
if indexname == "master" or not indexname:
continue
assert projectnames == ["deltachat"]
clear_index = not projectnames
for projectname in projectnames:
dates = get_release_dates(baseurl, username, indexname, projectname)
if not dates:
@@ -60,8 +60,11 @@ def run():
date = datetime.datetime(*max(dates))
if (datetime.datetime.now() - date) > datetime.timedelta(days=MAXDAYS):
assert username and indexname
url = baseurl + username + "/" + indexname
subprocess.check_call(["devpi", "index", "-y", "--delete", url])
clear_index = True
break
if clear_index:
url = baseurl + username + "/" + indexname
subprocess.check_call(["devpi", "index", "-y", "--delete", url])