-
Notifications
You must be signed in to change notification settings - Fork 366
453 lines (402 loc) · 13.6 KB
/
nightly.yml
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
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
name: Nightly
on:
workflow_dispatch:
schedule:
# https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#schedule
# 12:15 UTC, every day
- cron: "15 12 * * *"
defaults:
run:
shell: bash
permissions:
contents: "write"
id-token: "write"
deployments: "write"
jobs:
checks:
name: Checks
uses: ./.github/workflows/reusable_checks.yml
with:
CONCURRENCY: nightly
CHANNEL: nightly
secrets: inherit
checks-cpp:
name: Checks
uses: ./.github/workflows/reusable_checks_cpp.yml
with:
CONCURRENCY: nightly
CHANNEL: nightly
secrets: inherit
checks-rust:
name: Checks
uses: ./.github/workflows/reusable_checks_rust.yml
with:
CONCURRENCY: nightly
CHANNEL: nightly
secrets: inherit
checks-python:
name: Checks
uses: ./.github/workflows/reusable_checks_python.yml
with:
CONCURRENCY: nightly
secrets: inherit
# Check that a CLEAN container with just `cargo` on it can build rerun:
clean-build:
name: cargo build on clean container
strategy:
matrix:
os: [ubuntu-latest-16-cores, macos-latest, windows-latest-8-cores]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@master
with:
toolchain: 1.76.0
- run: cargo build -p rerun
build-web:
name: "Build web viewer"
uses: ./.github/workflows/reusable_build_web.yml
with:
CONCURRENCY: nightly
CHANNEL: nightly
secrets: inherit
upload-web:
name: "Upload Web"
needs: [build-web]
uses: ./.github/workflows/reusable_upload_web.yml
with:
CONCURRENCY: nightly
NIGHTLY: true
secrets: inherit
# -----------------------------------------------------------------------------------
# Build rerun_c library binaries:
build-rerun_c-and-upload-linux-arm64:
needs: [checks]
name: "Linux-Arm64: Build & Upload rerun_c"
uses: ./.github/workflows/reusable_build_and_upload_rerun_c.yml
with:
CONCURRENCY: nightly-linux-arm64
PLATFORM: linux-arm64
secrets: inherit
build-rerun_c-and-upload-linux-x64:
needs: [checks]
name: "Linux-x64: Build & Upload rerun_c"
uses: ./.github/workflows/reusable_build_and_upload_rerun_c.yml
with:
CONCURRENCY: nightly-linux-x64
PLATFORM: linux-x64
secrets: inherit
build-rerun_c-and-upload-macos-x64:
needs: [checks]
name: "Mac-Intel: Build & Upload rerun_c"
uses: ./.github/workflows/reusable_build_and_upload_rerun_c.yml
with:
CONCURRENCY: nightly-macos-x64
PLATFORM: macos-x64
secrets: inherit
build-rerun_c-and-upload-macos-arm64:
needs: [checks]
name: "Mac-Arm64: Build & Upload rerun_c"
uses: ./.github/workflows/reusable_build_and_upload_rerun_c.yml
with:
CONCURRENCY: nightly-macos-arm64
PLATFORM: macos-arm64
secrets: inherit
build-rerun_c-and-upload-windows-x64:
needs: [checks]
name: "Windows-x64: Build & Upload rerun_c"
uses: ./.github/workflows/reusable_build_and_upload_rerun_c.yml
with:
CONCURRENCY: nightly-windows-x64
PLATFORM: windows-x64
secrets: inherit
# -----------------------------------------------------------------------------------
# Build rerun-cli (rerun binaries):
build-rerun-cli-and-upload-linux-arm64:
needs: [checks]
name: "Linux-arm64: Build & Upload rerun-cli"
uses: ./.github/workflows/reusable_build_and_upload_rerun_cli.yml
with:
CONCURRENCY: nightly-linux-arm64
PLATFORM: linux-arm64
secrets: inherit
build-rerun-cli-and-upload-linux-x64:
needs: [checks]
name: "Linux-x64: Build & Upload rerun-cli"
uses: ./.github/workflows/reusable_build_and_upload_rerun_cli.yml
with:
CONCURRENCY: nightly-linux-x64
PLATFORM: linux-x64
secrets: inherit
build-rerun-cli-and-upload-macos-x64:
needs: [checks]
name: "Mac-x64: Build & Upload rerun-cli"
uses: ./.github/workflows/reusable_build_and_upload_rerun_cli.yml
with:
CONCURRENCY: nightly-macos-x64
PLATFORM: macos-x64
secrets: inherit
build-rerun-cli-and-upload-macos-arm64:
needs: [checks]
name: "Mac-arm64: Build & Upload rerun-cli"
uses: ./.github/workflows/reusable_build_and_upload_rerun_cli.yml
with:
CONCURRENCY: nightly-macos-arm64
PLATFORM: macos-arm64
secrets: inherit
build-rerun-cli-and-upload-windows-x64:
needs: [checks]
name: "Windows-x64: Build & Upload rerun-cli"
uses: ./.github/workflows/reusable_build_and_upload_rerun_cli.yml
with:
CONCURRENCY: nightly-windows-x64
PLATFORM: windows-x64
secrets: inherit
# ---------------------------------------------------------------------------
# Build wheels:
build-wheel-linux-arm64:
needs: [checks, build-rerun-cli-and-upload-linux-arm64]
name: "Linux-arm64: Build & Upload Wheels"
uses: ./.github/workflows/reusable_build_and_upload_wheels.yml
with:
CONCURRENCY: nightly-linux-arm64
PLATFORM: linux-arm64
WHEEL_ARTIFACT_NAME: linux-arm64-wheel
MODE: "pypi"
secrets: inherit
build-wheel-linux-x64:
needs: [checks, build-rerun-cli-and-upload-linux-x64]
name: "Linux-x64: Build & Upload Wheels"
uses: ./.github/workflows/reusable_build_and_upload_wheels.yml
with:
CONCURRENCY: nightly-linux-x64
PLATFORM: linux-x64
WHEEL_ARTIFACT_NAME: linux-x64-wheel
MODE: "pypi"
secrets: inherit
build-wheel-macos-arm64:
needs: [checks, build-rerun-cli-and-upload-macos-arm64]
name: "Macos-arm64: Build & Upload Wheels"
uses: ./.github/workflows/reusable_build_and_upload_wheels.yml
with:
CONCURRENCY: nightly-macos-arm64
PLATFORM: macos-arm64
WHEEL_ARTIFACT_NAME: macos-arm64-wheel
MODE: "pypi"
secrets: inherit
build-wheel-macos-x64:
needs: [checks, build-rerun-cli-and-upload-macos-x64]
name: "Macos-x64: Build & Upload Wheels"
uses: ./.github/workflows/reusable_build_and_upload_wheels.yml
with:
CONCURRENCY: nightly-macos-x64
PLATFORM: macos-x64
WHEEL_ARTIFACT_NAME: "macos-x64-wheel"
MODE: "pypi"
secrets: inherit
build-wheel-windows-x64:
needs: [checks, build-rerun-cli-and-upload-windows-x64]
name: "Windows-x64: Build & Upload Wheels"
uses: ./.github/workflows/reusable_build_and_upload_wheels.yml
with:
CONCURRENCY: nightly-windows-x64
PLATFORM: windows-x64
WHEEL_ARTIFACT_NAME: windows-x64-wheel
MODE: "pypi"
secrets: inherit
# ---------------------------------------------------------------------------
# Test wheels:
test-wheel-linux-arm64:
needs: [checks, build-wheel-linux-arm64]
name: "linux-arm64: Test Wheels"
uses: ./.github/workflows/reusable_test_wheels.yml
with:
CONCURRENCY: nightly-linux-arm64
PLATFORM: linux-arm64
WHEEL_ARTIFACT_NAME: linux-arm64-wheel
secrets: inherit
test-wheel-linux-x64:
needs: [checks, build-wheel-linux-x64]
name: "Linux-x64: Test Wheels"
uses: ./.github/workflows/reusable_test_wheels.yml
with:
CONCURRENCY: nightly-linux-x64
PLATFORM: linux-x64
WHEEL_ARTIFACT_NAME: linux-x64-wheel
secrets: inherit
test-wheel-macos-arm64:
needs: [checks, build-wheel-macos-arm64]
name: "macos-arm64: Test Wheels"
uses: ./.github/workflows/reusable_test_wheels.yml
with:
CONCURRENCY: nightly-macos-arm64
PLATFORM: macos-arm64
WHEEL_ARTIFACT_NAME: macos-arm64-wheel
secrets: inherit
test-wheel-macos-x64:
needs: [checks, build-wheel-macos-x64]
name: "macos-x64: Test Wheels"
uses: ./.github/workflows/reusable_test_wheels.yml
with:
CONCURRENCY: nightly-macos-x64
PLATFORM: macos-x64
WHEEL_ARTIFACT_NAME: macos-x64-wheel
secrets: inherit
test-wheel-windows-x64:
needs: [checks, build-wheel-windows-x64]
name: "Windows-x64: Test Wheels"
uses: ./.github/workflows/reusable_test_wheels.yml
with:
CONCURRENCY: nightly-windows-x64
PLATFORM: windows-x64
WHEEL_ARTIFACT_NAME: windows-x64-wheel
secrets: inherit
# ---------------------------------------------------------------------------
run-notebook:
name: "Run Notebook"
needs: [build-wheel-linux-x64]
uses: ./.github/workflows/reusable_run_notebook.yml
with:
CONCURRENCY: nightly
WHEEL_ARTIFACT_NAME: linux-x64-wheel
secrets: inherit
build-examples:
name: "Build Examples"
needs: [build-wheel-linux-x64]
uses: ./.github/workflows/reusable_build_examples.yml
with:
CONCURRENCY: nightly
CHANNEL: nightly
WHEEL_ARTIFACT_NAME: linux-x64-wheel
secrets: inherit
upload-examples:
name: "Upload Examples"
needs: [build-examples]
uses: ./.github/workflows/reusable_upload_examples.yml
with:
CONCURRENCY: nightly
NIGHTLY: true
secrets: inherit
benches:
name: Benchmarks
uses: ./.github/workflows/reusable_bench.yml
with:
CONCURRENCY: nightly
SAVE_BENCHES: true
BENCH_NAME: main # We currently only run benches nightly, but we used to run them on main
COMPARE_TO: main # We currently only run benches nightly, but we used to run them on main
secrets: inherit
# --------------------------------------------------------------------------
# Release:
generate-pip-index:
name: "Generate Pip Index"
needs:
[
build-wheel-linux-arm64,
build-wheel-linux-x64,
build-wheel-macos-arm64,
build-wheel-macos-x64,
build-wheel-windows-x64,
]
uses: ./.github/workflows/reusable_pip_index.yml
with:
CONCURRENCY: nightly
secrets: inherit
bundle-and-upload-rerun_cpp:
name: "Bundle and upload rerun_cpp_sdk.zip"
needs:
[
build-rerun_c-and-upload-linux-arm64,
build-rerun_c-and-upload-linux-x64,
build-rerun_c-and-upload-macos-arm64,
build-rerun_c-and-upload-macos-x64,
build-rerun_c-and-upload-windows-x64,
]
uses: ./.github/workflows/reusable_bundle_and_upload_rerun_cpp.yml
with:
CONCURRENCY: nightly
secrets: inherit
pre-release:
name: Pre Release
concurrency: nightly
needs:
[
build-rerun-cli-and-upload-linux-arm64,
build-rerun-cli-and-upload-linux-x64,
build-rerun-cli-and-upload-macos-arm64,
build-rerun-cli-and-upload-macos-x64,
build-rerun-cli-and-upload-windows-x64,
build-rerun_c-and-upload-linux-arm64,
build-rerun_c-and-upload-linux-x64,
build-rerun_c-and-upload-macos-arm64,
build-rerun_c-and-upload-macos-x64,
build-rerun_c-and-upload-windows-x64,
bundle-and-upload-rerun_cpp,
generate-pip-index,
upload-web,
]
runs-on: "ubuntu-latest"
steps:
- name: Add SHORT_SHA env property with commit short sha
run: echo "SHORT_SHA=`echo ${{github.sha}} | cut -c1-7`" >> $GITHUB_ENV
# First delete the old prerelease. If we don't do this, we don't get things like
# proper source-archives and changelog info.
# https://github.com/dev-drprasad/delete-tag-and-release
- uses: dev-drprasad/delete-tag-and-release@v0.2.1
with:
tag_name: prerelease
delete_release: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# Create the actual prerelease
# https://github.com/ncipollo/release-action
- name: GitHub Release
uses: ncipollo/release-action@v1.12.0
with:
body: |
This is a prerelease. It is not intended for production use.
Please report any issues you find.
## Example Hosted App
https://rerun.io/viewer/commit/${{ env.SHORT_SHA }}
## Wheels can be installed with:
```
pip install --pre --no-index -f https://build.rerun.io/commit/${{ env.SHORT_SHA }}/wheels --upgrade rerun-sdk
```
or
```
pip install --pre --no-index -f https://github.com/rerun-io/rerun/releases/download/prerelease --upgrade rerun-sdk
```
## CMake fetch-content for C++ SDK
```
include(FetchContent)
FetchContent_Declare(rerun_sdk URL https://build.rerun.io/commit/${{ env.SHORT_SHA }}/rerun_cpp_sdk.zip)
FetchContent_MakeAvailable(rerun_sdk)
```
or
```
include(FetchContent)
FetchContent_Declare(rerun_sdk URL https://github.com/rerun-io/rerun/releases/download/prerelease/rerun_cpp_sdk.zip)
FetchContent_MakeAvailable(rerun_sdk)
```
prerelease: true
# Be explicit about the commit we're releasing/tagging.
# Otherwise it can happen that there's a discrepancy between the tag and the commit for which we uploaded & linked artifacts.
# It seems to otherwise use the latest commit for the tag. From the actions's docs:
# > If the tag of the release you are creating does not yet exist, you should set both the tag and commit action inputs.
# We just deleted the previous tag, so this is the case!
commit: ${{github.sha}}
name: "Development Build"
tag: "prerelease"
token: ${{ secrets.GITHUB_TOKEN }}
generateReleaseNotes: false
allowUpdates: true
removeArtifacts: true
replacesArtifacts: true
sync-release-assets:
needs: [pre-release]
name: "Sync pre-release assets & build.rerun.io"
uses: ./.github/workflows/reusable_sync_release_assets.yml
with:
CONCURRENCY: nightly
RELEASE_VERSION: prerelease
secrets: inherit