Skip to content

Commit 458c0f0

Browse files
Merge branch 'OpenWaterAnalytics:dev' into dev
2 parents 7530fc4 + c290f95 commit 458c0f0

3 files changed

Lines changed: 13 additions & 9 deletions

File tree

.github/workflows/build-wheels.yml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66
jobs:
77
build_wheels:
88
name: Build wheel for cp${{ matrix.python }}-${{ matrix.platform_id }}
9-
runs-on: ubuntu-latest
9+
runs-on: ${{ matrix.os }}
1010
strategy:
1111
fail-fast: false
1212
matrix:
@@ -47,7 +47,7 @@ jobs:
4747
if: startsWith(matrix.os, 'windows')
4848

4949
- name: Install cibuildwheel
50-
run: python -m pip install cibuildwheel==2.2.0a1
50+
run: python -m pip install cibuildwheel==2.3.1
5151

5252
- name: Build wheels
5353
run: python -m cibuildwheel --output-dir wheelhouse owa-epanet
@@ -61,6 +61,7 @@ jobs:
6161
CIBW_TEST_COMMAND: pytest {package}
6262
CIBW_BEFORE_TEST: pip install scikit-build==0.11.1 cmake==3.18.4
6363
CIBW_TEST_REQUIRES: pytest
64+
CIBW_TEST_SKIP: "*-win32 *-manylinux_i686"
6465

6566
- name: Store artifacts
6667
uses: actions/upload-artifact@v2
@@ -76,11 +77,9 @@ jobs:
7677
with:
7778
submodules: true
7879

79-
# Had issues with not all files being pulled and this somehow resolved it
8080
- name: Fix submodules
8181
run: |
8282
cd owa-epanet
83-
rm -rf EPANET
8483
git submodule update
8584
8685
- uses: actions/setup-python@v2
@@ -111,10 +110,9 @@ jobs:
111110
- uses: actions/download-artifact@v2
112111
with:
113112
name: artifact
114-
path: owa-epanet/dist
113+
path: dist
115114

116115
- uses: pypa/gh-action-pypi-publish@v1.4.2
117116
with:
118117
user: __token__
119118
password: ${{ secrets.PYPI_API_TOKEN }}
120-
repository_url: https://test.pypi.org/legacy/

owa-epanet/CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
cmake_minimum_required(VERSION 3.8)
22

33
project(owa-epanet)
4+
set(Python3_EXECUTABLE ${PYTHON_EXECUTABLE})
45

56
if(SKBUILD)
67
message(STATUS "The project is built using scikit-build")

owa-epanet/test/test_owa_epanet.py

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,17 @@
1515

1616

1717
def clean_dir():
18+
def safe_delete(filename):
19+
try:
20+
os.remove(filename)
21+
except PermissionError:
22+
pass
1823
if os.path.exists('report.rpt'):
19-
os.remove('report.rpt')
24+
safe_delete('report.rpt')
2025
if os.path.exists('output.out'):
21-
os.remove('output.out')
26+
safe_delete('output.out')
2227
if os.path.exists('saved_inp_file.inp'):
23-
os.remove('saved_inp_file.inp')
28+
safe_delete('saved_inp_file.inp')
2429

2530

2631
def test_create_project():

0 commit comments

Comments
 (0)