-
Notifications
You must be signed in to change notification settings - Fork 448
139 lines (115 loc) · 3.63 KB
/
Copy pathnightly.yml
File metadata and controls
139 lines (115 loc) · 3.63 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT license.
on:
schedule:
# Run nightly at 2 AM UTC.
- cron: "0 2 * * *"
workflow_dispatch:
name: Nightly
concurrency:
group: ${{ github.workflow }}
cancel-in-progress: true
env:
RUST_CONFIG: 'build.rustflags=["-Dwarnings"]'
RUST_BACKTRACE: 1
CARGO_TERM_COLOR: always
DISKANN_FEATURES: "virtual_storage,spherical-quantization,product-quantization,tracing,experimental_diversity_search,disk-index,flatbuffers,linalg,codegen"
defaults:
run:
shell: bash
permissions:
contents: read
jobs:
clippy-default-features:
name: clippy-default-features (macos)
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
- name: Install Rust
run: rustup show && rustup component add clippy
- uses: Swatinem/rust-cache@v2
- name: "clippy --workspace --all-targets"
run: cargo clippy --locked --workspace --all-targets --no-deps --config "$RUST_CONFIG" -- -Dwarnings
clippy-features:
name: clippy-features (macos)
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
- name: Install Rust
run: rustup show && rustup component add clippy
- uses: Swatinem/rust-cache@v2
- name: "clippy --workspace --all-targets --features"
run: |
set -euxo pipefail
cargo clippy --locked --workspace \
--all-targets \
--no-deps \
--features ${{ env.DISKANN_FEATURES }} \
--config "$RUST_CONFIG" \
-- -Dwarnings
test-workspace:
needs:
- clippy-default-features
- clippy-features
name: test workspace (macos)
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
with:
lfs: true
- name: Install Rust
run: rustup show
- name: Install cargo-nextest
uses: taiki-e/install-action@v2
with:
tool: cargo-nextest
- uses: Swatinem/rust-cache@v2
- name: test workspace with nextest
run: |
set -euxo pipefail
cargo nextest run --locked --workspace --cargo-profile ci --config "$RUST_CONFIG"
cargo test --locked --doc --workspace --profile ci --config "$RUST_CONFIG"
test-workspace-features:
needs:
- clippy-default-features
- clippy-features
name: test workspace (macos, all features)
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
with:
lfs: true
- name: Install Rust
run: rustup show
- name: Install cargo-nextest
uses: taiki-e/install-action@v2
with:
tool: cargo-nextest
- uses: Swatinem/rust-cache@v2
- name: test workspace with nextest
run: |
set -euxo pipefail
cargo nextest run --locked --workspace \
--cargo-profile ci \
--config "$RUST_CONFIG" \
--features ${{ env.DISKANN_FEATURES }}
cargo test --locked --doc --workspace --profile ci --config "$RUST_CONFIG"
miri:
name: miri-test
runs-on: ubuntu-latest
continue-on-error: true
steps:
- uses: actions/checkout@v4
with:
lfs: true
- name: Install Rust nightly with miri
run: rustup toolchain install nightly --component miri
- name: Install cargo-nextest
uses: taiki-e/install-action@v2
with:
tool: cargo-nextest
- uses: Swatinem/rust-cache@v2
- name: miri
run: cargo +nightly miri nextest run --locked --package diskann-quantization
env:
MIRIFLAGS: -Zmiri-disable-isolation -Zmiri-strict-provenance