Skip to content

Commit 5e867c4

Browse files
committed
ci: Add workflow for Windows
Signed-off-by: Julien Jerphanion <[email protected]>
1 parent 24dfb54 commit 5e867c4

File tree

3 files changed

+75
-11
lines changed

3 files changed

+75
-11
lines changed

.github/workflows/build_with_conda.yml

+66-4
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,10 @@ jobs:
4040
uses: SimenB/[email protected]
4141
id: cpu-cores
4242

43-
- name: Install Conda environment from environment_unix.yml
43+
- name: Install Conda environment from environment-dev.yml
4444
uses: mamba-org/[email protected]
4545
with:
46-
environment-file: environment_unix.yml
46+
environment-file: environment-dev.yml
4747
init-shell: >-
4848
bash
4949
cache-environment: true
@@ -124,10 +124,10 @@ jobs:
124124
uses: SimenB/[email protected]
125125
id: cpu-cores
126126

127-
- name: Install Conda environment from environment_unix.yml
127+
- name: Install Conda environment from environment-dev.yml
128128
uses: mamba-org/[email protected]
129129
with:
130-
environment-file: environment_unix.yml
130+
environment-file: environment-dev.yml
131131
environment-name: arcticdb
132132
init-shell: >-
133133
bash
@@ -175,3 +175,65 @@ jobs:
175175
env:
176176
ARCTICDB_USING_CONDA: 1
177177

178+
windows:
179+
runs-on: windows-latest
180+
env:
181+
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
182+
steps:
183+
- uses: actions/[email protected]
184+
# DONT use recursive submodules checkout to simulate conda feedstock build
185+
# with:
186+
# submodules: recursive
187+
188+
- name: Get number of CPU cores
189+
uses: SimenB/[email protected]
190+
id: cpu-cores
191+
192+
- name: Install Conda environment from environment-dev.yml
193+
uses: mamba-org/[email protected]
194+
with:
195+
environment-file: environment-dev.yml
196+
init-shell: >-
197+
cmd
198+
cache-environment: true
199+
post-cleanup: 'all'
200+
201+
- name: Build ArcticDB with conda (ARCTICDB_USING_CONDA=1)
202+
shell: cmd {0}
203+
run: |
204+
# Protocol buffers compilation require not using build isolation.
205+
python -m pip install --no-build-isolation --no-deps -v -e .
206+
env:
207+
ARCTICDB_USING_CONDA: 1
208+
ARCTICDB_BUILD_CPP_TESTS: 1
209+
ARCTIC_CMAKE_PRESET: windows-conda-release-build
210+
211+
- name: Build C++ Tests
212+
shell: cmd {0}
213+
run: |
214+
cd cpp\out\windows-conda-release-build
215+
msbuild arcticdb_rapidcheck_tests.vcxproj /p:Configuration=Release /p:Platform=x64 /m
216+
msbuild test_unit_arcticdb.vcxproj /p:Configuration=Release /p:Platform=x64 /m
217+
218+
- name: Run C++ Tests
219+
shell: cmd {0}
220+
run: |
221+
cd cpp\out\windows-conda-release-build
222+
ctest -C Release -T test
223+
224+
- name: Install npm
225+
uses: actions/[email protected]
226+
with:
227+
node-version: '16'
228+
229+
- name: Install azurite
230+
shell: cmd {0}
231+
run: |
232+
npm install -g azurite
233+
234+
- name: Test with pytest
235+
shell: cmd {0}
236+
run: |
237+
cd python
238+
set ARCTICDB_RAND_SEED=%RANDOM%
239+
python -m pytest --timeout=3600

docs/mkdocs/docs/technical/contributing.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -94,10 +94,10 @@ due to a linkage problems with libprotobuf.
9494
See: https://github.com/man-group/ArcticDB/pull/449**
9595

9696
- [Install `mamba`](https://mamba.readthedocs.io/en/latest/installation.html)
97-
- Create the `arcticdb` environment from its specification (`environment_unix.yml`):
97+
- Create the `arcticdb` environment from its specification (`environment-dev.yml`):
9898

9999
```bash
100-
mamba env create -f environment_unix.yml
100+
mamba env create -f environment-dev.yml
101101
```
102102

103103
- Activate the `arcticdb` environment (you will need to do this for every new shell session):
@@ -113,7 +113,7 @@ See: https://github.com/man-group/ArcticDB/pull/449**
113113
For instance:
114114

115115
- for debug build on Linux with mamba and conda-forge, use:
116-
116+
117117
```bash
118118
export ARCTICDB_USING_CONDA=1
119119
cmake -DTEST=off --preset linux-conda-debug cpp
@@ -395,7 +395,7 @@ If possible, a version number should also be added such that future changes in t
395395
### API
396396

397397
Any changes to the API (including when exceptions are thrown and the type of the exception) must be weighed up against the change breaking behaviour for existing users.
398-
Please make this as clear to reviewers as possible by ensuring **API changes are clearly described in the PR description**.
398+
Please make this as clear to reviewers as possible by ensuring **API changes are clearly described in the PR description**.
399399
If the change is breaking, please also ensure that that is appropriately highlighted in the PR description as well.
400400
This is particularly true of the `NativeVersionStore` API, as this has many users inside Man Group.
401401

environment_unix.yml environment-dev.yml

+5-3
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,8 @@ dependencies:
8282
- trustme
8383
- entt
8484
- psutil
85-
- memray
86-
- pytest-memray
87-
85+
# Use memray and pytest-memray only on Linux and MacOS
86+
- sel(linux): memray
87+
- sel(linux): pytest-memray
88+
- sel(osx): memray
89+
- sel(osx): pytest-memray

0 commit comments

Comments
 (0)