Skip to content

Commit 5d42d9f

Browse files
committed
move travis-ci to tools, upload wheels
1 parent 5b76f89 commit 5d42d9f

14 files changed

+2742
-53
lines changed

.github/workflows/posix.yml

Lines changed: 17 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ jobs:
9393
export SDKROOT=/Applications/Xcode_12.5.1.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.3.sdk
9494
clang --version
9595
fi
96-
source travis-ci/build_steps.sh
96+
source tools/build_steps.sh
9797
echo "------ BEFORE BUILD ---------"
9898
before_build
9999
if [[ "$NIGHTLY" = "true" ]]; then
@@ -110,15 +110,20 @@ jobs:
110110
111111
- name: Build and test wheel
112112
run: |
113+
if [[ "$NIGHTLY" = "true" ]]; then
114+
# Set the pyproject.toml version
115+
version = $(cd OpenBLAS && git describe --tags --abbrev=8 | sed -e "s/^v\(.*\)-g.*/\1/")
116+
sed -e "s/^version = .*/version = ${version}/" -i.bak pyproject.toml
117+
fi
113118
if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then
114-
source travis-ci/build_wheel.sh
119+
source tools/build_wheel.sh
115120
else
116121
libc=${MB_ML_LIBC:-manylinux}
117122
docker_image=quay.io/pypa/${libc}${MB_ML_VER}_${PLAT}
118123
docker run --rm -e INTERFACE64="${INTERFACE64}" \
119124
-e MB_ML_LIBC="${MB_ML_LIBC}" \
120125
-v $(pwd):/openblas $docker_image \
121-
/bin/bash -xe /openblas/travis-ci/build_wheel.sh
126+
/bin/bash -xe /openblas/tools/build_wheel.sh
122127
fi
123128
124129
- uses: actions/upload-artifact@v3
@@ -131,32 +136,14 @@ jobs:
131136
name: wheels
132137
path: dist/scipy_openblas*.whl
133138

139+
- uses: conda-incubator/setup-miniconda@v2
140+
with:
141+
activate-environment: upload
142+
134143
- name: Upload
144+
env:
145+
ANACONDA_SCIENTIFIC_PYTHON_UPLOAD: ${{ secrets.ANACONDA_SCIENTIFIC_PYTHON_UPLOAD }}
135146
run: |
136-
set -ex
137-
TOKEN=${{ secrets.ANACONDA_SCIENTIFIC_PYTHON_UPLOAD }}
138-
if [ "$TOKEN" == "" ]; then
139-
# The token is available when under the MacPython org, not on forks
140-
echo "secrets.ANACONDA_SCIENTIFIC_PYTHON_UPLOAD is not defined: skipping";
141-
else
142-
# Pin urllib3<2 due to github.com/Anaconda-Platform/anaconda-client/issues/654
143-
pip install "urllib3<2.0.0"
144-
pip install git+https://github.com/Anaconda-Server/anaconda-client@1.8.0
145-
# The first -t option refers to the token, the second is the "type"
146-
# option to the "upload" command
147-
args=(
148-
-t ${TOKEN} upload
149-
--no-progress -u scientific-python-nightly-wheels
150-
-t file -p "openblas-libs"
151-
-d "OpenBLAS for multibuild wheels"
152-
-s "OpenBLAS for multibuild wheels"
153-
)
154-
if [[ "$NIGHTLY" = "true" ]]; then
155-
args+=(--force)
156-
args+=(-v "HEAD")
157-
else
158-
args+=(--skip)
159-
args+=(-v "$(cd OpenBLAS && git describe --tags --abbrev=8)")
160-
fi
161-
anaconda "${args[@]}" libs/openblas*.tar.gz
162-
fi
147+
# Pin urllib3<2 due to github.com/Anaconda-Platform/anaconda-client/issues/654
148+
conda install -y anaconda-client 'urllib3<2.0.0'
149+
source tools/upload_to_anaconda_staging.sh

.github/workflows/windows.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,7 @@ jobs:
109109
# of a pyproject.toml project
110110
sed -e "s/openblas64/openblas32/" -i pyproject.toml
111111
sed -e "s/openblas_get_config64_/openblas_get_config/" -i local/scipy_openblas32/__init__.py
112+
sed -e "s/openblas64/openblas32/" -i local/scipy_openblas32/__init__.py
112113
sed -e "s/openblas64/openblas32/" -i local/scipy_openblas32/__main__.py
113114
fi
114115
cat tools/LICENSE_win32.txt >> LICENSE.txt

.travis.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ matrix:
7676
- DOCKER_TEST_IMAGE=multibuild/xenial_{PLAT}
7777

7878
before_install:
79-
- source travis-ci/build_steps.sh
79+
- source tools/build_steps.sh
8080
- before_build
8181

8282
install:
@@ -91,8 +91,8 @@ script:
9191
- docker run --rm -e INTERFACE64="${INTERFACE64}" \
9292
-e MB_ML_LIBC="${MB_ML_LIBC}" \
9393
-v $(pwd):/openblas $docker_image \
94-
/bin/bash -xe /openblas/travis-ci/build_wheel.sh
94+
/bin/bash -xe /openblas/tools/build_wheel.sh
9595

9696
after_success:
9797
# Upload libraries to the shared staging area on anaconda.org
98-
- source tools/upload_to_anaconda_posix.sh
98+
- source tools/upload_to_anaconda_staging.sh

OpenBLAS

0 commit comments

Comments
 (0)