Skip to content
This repository was archived by the owner on Aug 30, 2024. It is now read-only.

Commit 74d5f79

Browse files
committed
remove NIGHTLY_BUILD, clean up scripts
1 parent 7f0076a commit 74d5f79

File tree

3 files changed

+19
-59
lines changed

3 files changed

+19
-59
lines changed

azure-pipelines.yml

+1-9
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
schedules:
22
- cron: "27 3 */1 * *"
33
# 3:27am UTC everyday
4-
displayName: Nighthly build
4+
displayName: Nightly build
55
branches:
66
include:
77
- master
@@ -30,21 +30,17 @@ jobs:
3030
py_3.7_32:
3131
PYTHON_VERSION: "3.7.x"
3232
PYTHON_ARCH: "x86"
33-
NIGHTLY_BUILD: "true"
3433
BITS: 32
3534
py_3.7_64:
3635
PYTHON_VERSION: "3.7.x"
37-
NIGHTLY_BUILD: "true"
3836
PYTHON_ARCH: 'x64'
3937
BITS: 64
4038
py_3.8_32:
4139
PYTHON_VERSION: "3.8.x"
4240
PYTHON_ARCH: "x86"
43-
NIGHTLY_BUILD: "true"
4441
BITS: 32
4542
py_3.8_64:
4643
PYTHON_VERSION: "3.8.x"
47-
NIGHTLY_BUILD: "true"
4844
PYTHON_ARCH: 'x64'
4945
BITS: 64
5046

@@ -65,24 +61,20 @@ jobs:
6561
py_3.7_32:
6662
MB_PYTHON_VERSION: "3.7"
6763
PLAT: "i686"
68-
NIGHTLY_BUILD: "true"
6964
MB_ML_VER: "2010"
7065
ENV_VARS_PATH: "env_vars_32.sh"
7166
DOCKER_TEST_IMAGE: "multibuild/xenial_{PLAT}"
7267
py_3.7_64:
7368
MB_PYTHON_VERSION: "3.7"
74-
NIGHTLY_BUILD: "true"
7569
MB_ML_VER: "2010"
7670
py_3.8_32:
7771
MB_PYTHON_VERSION: "3.8"
7872
PLAT: "i686"
79-
NIGHTLY_BUILD: "true"
8073
MB_ML_VER: "2010"
8174
ENV_VARS_PATH: "env_vars_32.sh"
8275
DOCKER_TEST_IMAGE: "multibuild/xenial_{PLAT}"
8376
py_3.8_64:
8477
MB_PYTHON_VERSION: "3.8"
85-
NIGHTLY_BUILD: "true"
8678
MB_ML_VER: "2010"
8779

8880
- template: azure/posix.yml

azure/posix.yml

+1-20
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ jobs:
1313
PLAT: "x86_64"
1414
CYTHON_BUILD_DEP: "cython==0.29.16"
1515
NIGHTLY_BUILD_COMMIT: "master"
16-
NIGHTLY_BUILD: "false"
1716
TEST_DEPENDS: "pytest hypothesis cffi pytz"
1817
JUNITXML: "test-data.xml"
1918
TEST_DIR: "tmp_for_test"
@@ -33,16 +32,11 @@ jobs:
3332
- bash: |
3433
set -e
3534
36-
SKIP_BUILD="false"
3735
if [ "$BUILD_REASON" == "Schedule" ]; then
3836
BUILD_COMMIT=$NIGHTLY_BUILD_COMMIT
39-
if [ "$NIGHTLY_BUILD" != "true" ]; then
40-
SKIP_BUILD="true"
41-
fi
4237
fi
4338
echo "Building numpy@$BUILD_COMMIT"
4439
echo "##vso[task.setvariable variable=BUILD_COMMIT]$BUILD_COMMIT"
45-
echo "##vso[task.setvariable variable=SKIP_BUILD]$SKIP_BUILD"
4640
4741
# Platform variables used in multibuild scripts
4842
if [ `uname` == 'Darwin' ]; then
@@ -60,7 +54,7 @@ jobs:
6054
6155
- bash: |
6256
set -e
63-
pip install virtualenv wheel
57+
pip install virtualenv wheel anaconda
6458
BUILD_DEPENDS="$CYTHON_BUILD_DEP"
6559
6660
source multibuild/common_utils.sh
@@ -74,7 +68,6 @@ jobs:
7468
./patch_code.sh $REPO_DIR
7569
build_wheel $REPO_DIR $PLAT
7670
displayName: Build wheel
77-
condition: eq(variables['SKIP_BUILD'], 'false')
7871
7972
- bash: |
8073
set -xe
@@ -85,17 +78,6 @@ jobs:
8578
install_run $PLAT
8679
teardown_test_venv
8780
displayName: Install wheel and test
88-
condition: eq(variables['SKIP_BUILD'], 'false')
89-
90-
- bash: |
91-
echo "##vso[task.prependpath]$CONDA/bin"
92-
sudo chown -R $USER $CONDA
93-
displayName: Add conda to PATH
94-
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'))
95-
96-
- bash: conda install -q -y anaconda-client
97-
displayName: Install anaconda-client
98-
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'))
9981
10082
- bash: |
10183
set -e
@@ -112,7 +94,6 @@ jobs:
11294
echo "##vso[task.setvariable variable=TOKEN]$TOKEN"
11395
echo "##vso[task.setvariable variable=ANACONDA_ORG]$ANACONDA_ORG"
11496
displayName: Retrieve secret upload token
115-
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'))
11697
env:
11798
# Secret variables need to mapped to env variables explicitly:
11899
NUMPY_NIGHTLY_UPLOAD_TOKEN: $(NUMPY_NIGHTLY_UPLOAD_TOKEN)

azure/windows.yml

+17-30
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ jobs:
88
pool:
99
vmImage: ${{ parameters.vmImage }}
1010
variables:
11-
BUILD_COMMIT: "v1.18.2"
11+
BUILD_COMMIT: "master"
1212
NIGHTLY_BUILD_COMMIT: "master"
1313
JUNITXML: "test-data.xml"
1414
TEST_DIR: '$(Agent.WorkFolder)/tmp_for_test'
@@ -36,16 +36,11 @@ jobs:
3636
displayName: Check that we have the expected version and architecture for Python
3737
- bash: |
3838
set -e
39-
SKIP_BUILD="false"
4039
if [ "$BUILD_REASON" == "Schedule" ]; then
4140
BUILD_COMMIT=$NIGHTLY_BUILD_COMMIT
42-
if [ "$NIGHTLY_BUILD" != "true" ]; then
43-
SKIP_BUILD="true"
44-
fi
4541
fi
4642
echo "Building numpy@$BUILD_COMMIT"
4743
echo "##vso[task.setvariable variable=BUILD_COMMIT]$BUILD_COMMIT"
48-
echo "##vso[task.setvariable variable=SKIP_BUILD]$SKIP_BUILD"
4944
# Store original Python path to be able to create test_venv pointing
5045
# to same Python version.
5146
PYTHON_EXE=`which python`
@@ -54,11 +49,11 @@ jobs:
5449
- bash: |
5550
set -e
5651
cd numpy
52+
git fetch origin HEAD
5753
git checkout $BUILD_COMMIT
5854
git clean -fxd
5955
git reset --hard
6056
displayName: Checkout numpy commit
61-
condition: eq(variables['SKIP_BUILD'], 'false')
6257
6358
- powershell: |
6459
choco install -y mingw --forcex86 --force --version=5.3.0
@@ -68,35 +63,37 @@ jobs:
6863
refreshenv
6964
displayName: 'Install 32-bit mingw for 32-bit builds'
7065
condition: eq(variables['BITS'], 32)
71-
- powershell: |
72-
pip install twine wheel urllib3
66+
- bash: |
67+
pushd numpy
68+
pip install twine wheel urllib3 anaconda
7369
# a bit overkill, all we really need is cython
7470
pip install --timeout=60 -r numpy/test_requirements.txt
7571
7672
# handle license
77-
cp LICENSE_win32.txt numpy/LICENSE.txt
73+
cp ../LICENSE_win32.txt LICENSE.txt
7874
79-
# Download and copy static "openblas.a", put it into LIB
80-
$libdir = Join-Path $PSScriptRoot "OPENBLAS_LIB"
81-
mkdir $libdir
82-
$openblas_lib=$( python numpy/tools/openblas_support.py )
83-
echo Copying $openblas_lib to $libdir
84-
cp $openblas_lib $libdir/openblas.a
85-
$env:LIB = $libdir + ";" + $env:LIB
75+
# handle _distributor_init.py
76+
PYTHONPATH=tools python -c "import openblas_support; openblas_support.make_init('numpy')"
77+
78+
# Download and get the path to "openblas.a". We cannot copy it
79+
# to $PYTHON_EXE's directory since that is on a different drive which
80+
# mingw does not like. Instead copy it to a directory and set OPENBLAS
81+
target=$(python tools/openblas_support.py)
82+
mkdir -p openblas
83+
echo Copying $target to openblas
84+
cp $target openblas
85+
echo "##vso[task.setvariable variable=OPENBLAS]openblas"
8686
displayName: Prepare the build
87-
condition: eq(variables['SKIP_BUILD'], 'false')
8887
8988
- bash: |
9089
# Build the wheel
9190
set -e
9291
pushd numpy
9392
python setup.py build
9493
python setup.py bdist_wheel
95-
ls dist
9694
twine check dist/*
9795
popd
9896
displayName: Build wheel
99-
condition: eq(variables['SKIP_BUILD'], 'false')
10097
- bash: |
10198
set -ex
10299
source extra_functions.sh
@@ -107,15 +104,6 @@ jobs:
107104
run_tests
108105
teardown_test_venv
109106
displayName: Install wheel and test
110-
condition: eq(variables['SKIP_BUILD'], 'false')
111-
112-
- bash: echo "##vso[task.prependpath]$CONDA/Scripts"
113-
displayName: Add conda to PATH
114-
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'))
115-
116-
- bash: conda install -q -y anaconda-client
117-
displayName: Install anaconda-client
118-
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'))
119107
120108
- bash: |
121109
set -e
@@ -132,7 +120,6 @@ jobs:
132120
echo "##vso[task.setvariable variable=TOKEN]$TOKEN"
133121
echo "##vso[task.setvariable variable=ANACONDA_ORG]$ANACONDA_ORG"
134122
displayName: Retrieve secret upload token
135-
condition: and(succeeded(), eq(variables['SKIP_BUILD'], 'false'), ne(variables['Build.Reason'], 'PullRequest'))
136123
env:
137124
# Secret variables need to mapped to env variables explicitly:
138125
NUMPY_NIGHTLY_UPLOAD_TOKEN: $(NUMPY_NIGHTLY_UPLOAD_TOKEN)

0 commit comments

Comments
 (0)