Skip to content

armgit / kwant

Public Imported from GitHub
0

Your own team of AI bots in one self-hosted binary: spaces, every account you have, handoffs, approvals and routines. Open-source, self-hosted alternative to Grok Bot, Claude Duet and OpenAI dots. Rust + React.

CI: build Rust tests without debug info (#4)

Oleksandr Ivanchenko5b0ce9505497
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 033a8019..f7b4b9e8 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -15,6 +15,10 @@ concurrency:
env:
CARGO_TERM_COLOR: always
CARGO_INCREMENTAL: 0
+ # Debug info makes each of the ~70 test binaries hundreds of MB, which
+ # fills the runner's disk and crashes the linker. CI doesn't need it.
+ CARGO_PROFILE_DEV_DEBUG: 0
+ CARGO_PROFILE_TEST_DEBUG: 0
jobs:
frontend:
@@ -59,4 +63,7 @@ jobs:
- name: Clippy
run: cargo clippy --all-targets --locked -- -D warnings
- name: Tests
- run: cargo test --locked
+ run: cargo test --locked --no-fail-fast
+ - name: Disk usage
+ if: always()
+ run: df -h / && du -sh target || true
diff --git a/src/sandbox/computer.rs b/src/sandbox/computer.rs
index f5f58368..b81794a8 100644
--- a/src/sandbox/computer.rs
+++ b/src/sandbox/computer.rs
@@ -680,7 +680,15 @@ mod tests {
if let Some(profile) = chrome_on {
cmd.arg("chrome").arg(format!("--user-data-dir={}", profile.display()));
}
- Self(cmd.stdin(std::process::Stdio::piped()).spawn().unwrap())
+ let child = cmd.stdin(std::process::Stdio::piped()).spawn().unwrap();
+ // just after the spawn its command line can still read as empty, which made
+ // `profile_owner` miss it on busy machines; wait until `sh` shows up there
+ let started = std::time::Instant::now();
+ while !command_line(child.id()).is_some_and(|line| line.contains("read _")) {
+ assert!(started.elapsed() < Duration::from_secs(5), "test process did not start");
+ std::thread::sleep(Duration::from_millis(5));
+ }
+ Self(child)
}
fn id(&self) -> u32 { self.0.id() }
}