Ensure benchmarks use real SpacetimeDB 2.0 (official Rust crate), not SQLite#5
Ensure benchmarks use real SpacetimeDB 2.0 (official Rust crate), not SQLite#5
Conversation
Adding CLAUDE.md with task information for AI processing. This file will be removed when the task is complete. Issue: #4
|
Ensure all changes are correct, consistent, validated, tested, logged and fully meet all discussed requirements (check issue description and all comments in issue and in pull request). Ensure all CI/CD checks pass. |
|
🤖 AI Work Session Started Starting automated work session at 2026-02-26T10:01:47.490Z The PR has been converted to draft mode while work is in progress. This comment marks the beginning of an AI work session. Please wait for the session to finish, and provide your feedback. |
- Fix rustfmt errors in rust/src/lib.rs (remove extra blank line) - Fix rustfmt errors in rust/src/spacetimedb_impl.rs (expand struct literal and reformat if-let method chain per nightly rustfmt rules) - Exclude vendored bumpalo-patched and doublets-patched dirs from file size check (they are third-party libraries, not project code) - Update changelog fragment to accurately describe real SpacetimeDB 2.0 engine usage (no SQLite, uses RelationalDB/TestDB in-memory) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
Fixed all 4 failing CI checks: Formatting failures (3) —
File size check failure (1) —
Also updated the changelog fragment to accurately describe the real SpacetimeDB 2.0 engine usage (no SQLite). |
This reverts commit f112ad9.
🤖 Solution Draft LogThis log file contains the complete execution trace of the AI solution draft process. 💰 Cost estimation:
Now working session is ended, feel free to review and add any feedback on the solution draft. |
🔄 Auto-restart triggeredReason: CI failures detected Starting new session to address the issues. Auto-restart-until-mergeable mode is active. Will continue until PR becomes mergeable. |
The rust/doublets-patched directory was registered as a git submodule
(mode 160000) but without a .gitmodules file, making CI unable to check
out the doublets source. This caused all three CI Test jobs to fail with:
failed to read doublets-patched/doublets/Cargo.toml
No such file or directory (os error 2)
Root cause: doublets-patched was committed as a git submodule without
the required .gitmodules configuration.
Fix: Remove the broken submodule entry and vendor the doublets source
directly into the repository as regular files. Apply patches to make
doublets compile with modern nightly Rust (>= 1.93.0):
- doublets/src/lib.rs: Remove removed nightly features
(generators, default_free_fn, bench_black_box, maybe_uninit_uninit_array)
and add impl_trait_in_assoc_type
- doublets/src/data/traits.rs: Replace default::default() with
Default::default(), fix ImplIter/ImplIterSmall opaque type aliasing
that errors with impl_trait_in_assoc_type
- doublets/tests/dyn.rs: Replace removed box syntax with Box::new()
- dev-deps/data-rs: Remove const_trait_impl, const_convert, const_deref,
const_refs_to_cell, const_result_drop feature flags; convert const trait
impls and ~const bounds to regular non-const equivalents
- dev-deps/mem-rs: Remove const_nonnull_slice_from_raw_parts,
default_free_fn, layout_for_ptr, slice_ptr_len, io_error_other,
const_trait_impl feature flags; fix const Default impl; fix
LayoutError/AllocError/io::Error conversion in try{} blocks
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
… mode Replace actions/cache@v4 with Swatinem/rust-cache@v2 which saves the build cache even on job cancellation/timeout (cache-on-failure: "true"). This ensures SpacetimeDB's compiled artifacts are preserved across runs so subsequent CI runs use the cached build instead of recompiling from scratch. Also change `cargo test --release` to `cargo test` (debug mode) to avoid the very slow LTO + codegen-units=1 release profile during testing, which was causing the initial cold-build to exceed GitHub Actions' 6-hour limit. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Summary
Fixes #4
This PR ensures that benchmarks use the real SpacetimeDB 2.0 engine via the official
spacetimedb-coreRust crate, not SQLite or any mock storage layer.What was implemented
rust/src/spacetimedb_impl.rs): Usesspacetimedb-corewithTestDB(in-memoryRelationalDB, the same engine SpacetimeDB uses internally for its own benchmarks). No SQLite involved.Linkstrait (rust/src/lib.rs): Shared interface for SpacetimeDB and Doublets backends.rust/src/doublets_impl.rs): United Volatile and Split Volatile implementations.rust/benches/bench.rs): 21 benchmark functions (7 operations × 3 backends)..github/workflows/rust-benchmark.yml): Tests on Ubuntu/macOS/Windows; generates charts on push to main.bumpalo-patched(required by SpacetimeDB internals), excluded from file size check.Acceptance criteria met
RelationalDBin-memory only)This PR was created automatically by the AI issue solver