b197db0c2d
Bandersnatch and pypi have a failure case where uploading two files to pypi very closely to each other results in bandersnatch thinking it has synced serial X+1 which includes both the sdist and wheel but it really has only synced serial X. But since X+1 is what bandersnatch thinks it has done it will never sync the actual contents of the X+1 serial (the second file uploaded). To make matters worse the index.html for the project is synced assuming both artifacts at serial X+1 were synced. This means any fetches for the second artifact fail. We can work around this by always uploading the wheel first. Pip prefers wheels to sdists so uploading the wheel first ensures that the wheel is synced properly, pip will prefer it, and our jobs should continue running. Eventually upstream pypi and bandersnatch will need to fix this bugs properly but this is a reasonable thing we can do locally. Change-Id: I26062b9fefa5ce484b63e2d0ee02e0ecbe64555f
39 lines
1013 B
YAML
39 lines
1013 B
YAML
- job-template:
|
|
name: '{name}-pypi-both-upload'
|
|
node: pypi
|
|
|
|
builders:
|
|
- revoke-sudo
|
|
- gerrit-git-prep
|
|
- shell: |
|
|
# Note we upload the wheel first because pip prefers wheels
|
|
# and there is a mirroring issue where sometimes the first
|
|
# artifact uploaded is the only one you get. Since pip prefers
|
|
# wheels it is best to make the wheel the one we get.
|
|
/usr/local/jenkins/slave_scripts/pypi-wheel-upload.sh {name} {tarball-site}
|
|
/usr/local/jenkins/slave_scripts/pypi-tarball-upload.sh {name} {tarball-site}
|
|
|
|
publishers:
|
|
- console-log
|
|
|
|
|
|
- job-template:
|
|
name: '{name}-pypi-wheel-upload'
|
|
node: pypi
|
|
|
|
builders:
|
|
- revoke-sudo
|
|
- gerrit-git-prep
|
|
- shell: |
|
|
/usr/local/jenkins/slave_scripts/pypi-wheel-upload.sh {name} {tarball-site}
|
|
|
|
publishers:
|
|
- console-log
|
|
|
|
|
|
- job-group:
|
|
name: pypi-jobs
|
|
jobs:
|
|
- '{name}-pypi-both-upload'
|
|
- '{name}-pypi-wheel-upload'
|