Implement Language
/WorkerType
enums
#17
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: | |
- main | |
tags: ['*'] | |
pull_request: | |
concurrency: | |
# Skip intermediate builds: always. | |
# Cancel intermediate builds: only if it is a pull request build. | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }} | |
jobs: | |
test: | |
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }} | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
version: | |
- "1.8" # Version used with MVP | |
- "1.9" # Latest release | |
os: | |
- ubuntu-latest | |
arch: | |
- x64 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Clone Ray repository | |
uses: actions/checkout@v3 | |
with: | |
repository: beacon-biosignals/ray | |
path: deps/ray | |
- name: Determine Ray commit | |
id: ray-commit | |
run: | | |
cd deps/ray | |
head_sha="$(git rev-parse HEAD)" | |
echo "head_sha=$head_sha" | tee -a "$GITHUB_OUTPUT" | |
- uses: julia-actions/setup-julia@v1 | |
with: | |
version: ${{ matrix.version }} | |
arch: ${{ matrix.arch }} | |
- uses: julia-actions/cache@v1 | |
# TODO: We shouldn't require separate caches per Julia version but allow cache restores to work | |
# https://docs.github.com/en/actions/using-workflows/caching-dependencies-to-speed-up-workflows#matching-a-cache-key | |
- uses: actions/cache/restore@v3 | |
id: bazel-cache | |
with: | |
key: bazel-cache.${{ matrix.os }}.${{ matrix.arch }}.julia-${{ matrix.version }}.ray-${{ steps.ray-commit.outputs.head_sha }}.hash-${{ hashFiles('deps/WORKSPACE.bazel.tpl', 'deps/BUILD.bazel') }} | |
path: ~/.cache/bazel | |
restore-keys: | | |
bazel-cache.${{ matrix.os }}.${{ matrix.arch }}.julia-${{ matrix.version }}.ray-${{ steps.ray-commit.outputs.head_sha }}. | |
bazel-cache.${{ matrix.os }}.${{ matrix.arch }}.julia-${{ matrix.version }}. | |
bazel-cache.${{ matrix.os }}.${{ matrix.arch }}. | |
# TODO: Takes an hour to build with the existing cache setup | |
# - name: Build Ray CLI | |
# run: | | |
# cd deps/ray/python | |
# pip install -e . --verbose | |
- name: Install Ray CLI | |
run: pip install -U "ray[default]==2.5.1" "pydantic<2" | |
- uses: julia-actions/julia-buildpkg@v1 | |
- uses: julia-actions/julia-runtest@v1 | |
# https://github.com/actions/cache/tree/main/save#always-save-cache | |
- uses: actions/cache/save@v3 | |
if: always() | |
with: | |
key: ${{ steps.bazel-cache.outputs.cache-primary-key }} | |
path: ~/.cache/bazel |