Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 11 additions & 5 deletions .github/workflows/main.yaml
Original file line number Diff line number Diff line change
@@ -1,17 +1,23 @@
name: CI

# Controls when the workflow will run.
#
# The only live job here (integration-tests) builds the trace_machina/nativelink
# OCI image from the docker-compose Dockerfile and runs run_integration_tests.sh.
# That is a per-PR OCI build — the same class of heavy work #image-off-pr moved
# off PRs for image.yaml and #2877 moved off PRs for the nix integration job.
# This lane fell in the crack between those two, so defer it the same way:
# nightly cross-check + on every merge to main, not on every PR. Per-PR
# build/test signal is carried by the Nix "Bazel Dev" lane.
on:
push:
branches: [ main ]
paths-ignore:
- '.github/styles/**'
- 'web/**'
pull_request:
branches: [ main ]
paths-ignore:
- '.github/styles/**'
- 'web/**'
schedule:
- cron: '0 7 * * *' # 07:00 UTC daily (off-peak)
workflow_dispatch:

permissions: read-all

Expand Down
8 changes: 7 additions & 1 deletion nativelink-store/tests/filesystem_store_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -241,11 +241,17 @@ async fn read_file_contents(file_name: &OsStr) -> Result<Vec<u8>, Error> {
}

async fn wait_for_no_open_files() -> Result<(), Error> {
// `get_open_files_for_test` reads a process-global open-handle counter, so
// this drains handles opened by *any* concurrently running test in the same
// binary. Under asan (and other slow-execution configs) a 1s budget is too
// tight and this spuriously times out even though the handles do close, so
// give the drain a generous ceiling — the loop still exits the instant the
// count reaches zero, so a healthy run pays nothing for the larger cap.
let mut counter = 0;
while fs::get_open_files_for_test() != 0 {
sleep(Duration::from_millis(1)).await;
counter += 1;
if counter > 1000 {
if counter > 10000 {
return Err(make_err!(
Code::Internal,
"Timed out waiting all files to close"
Expand Down
Loading