Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
9bb0dc4
store: flush Class C from the live slots
reardencode Oct 26, 2026
b7518c9
store: Class C stores take a single-writer capability
reardencode Oct 26, 2026
656e146
store: Class C gets use a sequence counter
reardencode Oct 26, 2026
0ae8073
store: model the Class C counter and the script-pool wake
reardencode Oct 26, 2026
3bf1954
ci: model job takes rustc from rust-toolchain.toml
rearden-grok[bot] Oct 26, 2026
f671f6b
store: strong bits use try_update, and CI checks rustc 1.99
rearden-grok[bot] Oct 26, 2026
81987cd
test: run /dev/full flush failures on Linux only
rearden-grok[bot] Oct 26, 2026
a1b3f2f
store: reject a sparse array set above the length
rearden-grok[bot] Oct 26, 2026
2c37ccb
ibd: drop the coordinator lock across an archived-body clear
rearden-grok[bot] Oct 26, 2026
a69c011
store: commit the strong bit image in one reservation
rearden-grok[bot] Oct 26, 2026
eeab2c1
store: one Class C writer wins the even-to-odd exchange
rearden-grok[bot] Oct 26, 2026
a22b82c
query: join the tip flush before a standalone header range put
rearden-grok[bot] Oct 26, 2026
461d08e
test: declare the log suite close symbol unsafe
rearden-grok[bot] Oct 26, 2026
10d19bb
test: split the Class C sequence loom checks
rearden-grok[bot] Oct 27, 2026
d328a3e
store: say the header-pair odd step is SeqCst
rearden-grok[bot] Oct 28, 2026
ae78634
ibd: defer every mutated archived-body clear
rearden-grok[bot] Oct 28, 2026
8406818
store: publish a disk-only Class C append after its bytes
rearden-grok[bot] Oct 28, 2026
edb87fb
store: a disk-only Class C get treats a truncate race as absent
rearden-grok[bot] Oct 28, 2026
eaae077
store: a disk-only zero gap fills one span
rearden-grok[bot] Oct 28, 2026
6357fb5
test: a tip flush counts its own thread
rearden-grok[bot] Oct 28, 2026
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
12 changes: 7 additions & 5 deletions .agents/skills/ship-pr/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,12 +75,14 @@ Coverage and native `windows` / `macos` stay GitHub Actions;

## Push and poll

Required jobs: `qc`, `test`, `windows`, `macos`, `coverage`, and `pread`.
`qc` is fmt, ast-grep, deny, the script self-tests, clippy, then
nixos-module-eval on one runner. `pread` is GitHub Actions only:
Required jobs: `qc`, `test`, `windows`, `macos`, `coverage`, `pread`, and
`rust-forward`. `qc` is fmt, ast-grep, deny, the script self-tests, clippy,
then nixos-module-eval on one runner. `pread` is GitHub Actions only:
`RBITCOIN_IO=pread cargo test -p rbitcoin-store -p rbitcoin-query` after
`qc` and `test`, in parallel with `coverage`. Do not run it in the local
gate list. The `test` job leaves `RBITCOIN_IO` unset. Mutants run nightly
`qc` and `test`, in parallel with `coverage`. `rust-forward` is the same
wait: `cargo check --workspace --all-targets` on the channel in
`rust-forward.toml`. Do not run either in the local gate list. The `test`
job leaves `RBITCOIN_IO` unset and stays on rustc 1.95. Mutants run nightly
with workspace tests (`mutants.yml`); they are not a required check.
Structural scan is `./scripts/ast-grep.sh`. `windows` / `macos` are native
store plus `--smoke`, not operator zips.
Expand Down
27 changes: 27 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,33 @@ jobs:
- name: cargo test store and query
run: cargo test -p rbitcoin-store -p rbitcoin-query

# Forward rustc. Same wait as pread: a red `test` does not compile it.
# Product MSRV stays rust-toolchain.toml. This job checks the dialect still
# builds on the channel in rust-forward.toml, beside pread.
rust-forward:
name: rust-forward
runs-on: ubuntu-latest
timeout-minutes: 30
needs: [qc, test]
env:
CARGO_TARGET_DIR: target/forward
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: install forward toolchain
run: |
channel=$(sed -n 's/^channel = "\(.*\)"$/\1/p' rust-forward.toml)
test -n "$channel"
rustup toolchain install --profile minimal "$channel"
echo "RUSTUP_TOOLCHAIN=$channel" >> "$GITHUB_ENV"
- uses: Swatinem/rust-cache@d1527c8f67ef9af357290475d4af4b0fab8f12e0 # v2.9.3
with:
shared-key: ci-rust-forward
workspaces: ". -> target/forward"
- name: cargo check
run: cargo check --workspace --all-targets

# Line-coverage 91% floor + CRAP --fail-above 30 (allowlist in .cargo-crap.toml).
# Slow; waits for qc and test so a red check does not start
# this job. Required. Job+step timeouts so a hung llvm-cov test binary
Expand Down
66 changes: 66 additions & 0 deletions .github/workflows/model.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
# Model-checked concurrency (`--test model`): loom explores script-pool claim
# order, the UTXO view stamp, and the Class C sequence counter. shuttle runs
# the script-pool idle turn. Not a required PR check. The engine is a
# `--cfg`, not a feature, so each job has its own target dir and cache. The
# nightly schedule raises the budget (TESTING.md) and seeds shuttle with the
# run id. The index-release order is not a model: it needs a Query full of
# std locks.
#
# rustc comes from rust-toolchain.toml (the nix-shell / crane baseline). The
# runner image's rustup auto-installs that toolchain and its components on
# first cargo.

name: model

on:
pull_request:
push:
branches: [master, main, "v*.*.x"]
schedule:
- cron: "23 6 * * *"
workflow_dispatch:

concurrency:
group: model-${{ github.ref }}
cancel-in-progress: true

permissions:
contents: read

env:
CARGO_TERM_COLOR: always
RUSTFLAGS: -D warnings
# Actions only. rust-cache restores dep rlibs (not workspace crates) and
# strips incremental artifacts before persist; it also sets this so rustc
# does not write throwaway dep-graphs.
CARGO_INCREMENTAL: "0"

jobs:
model:
name: ${{ matrix.engine }}
runs-on: ubuntu-latest
timeout-minutes: 30
strategy:
# A loom failure and a shuttle failure are separate findings.
fail-fast: false
matrix:
engine: [loom, shuttle]
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6 # v2.9.2
with:
shared-key: model-${{ matrix.engine }}
workspaces: ". -> target/model-${{ matrix.engine }}"
- name: model-check ${{ matrix.engine }}
if: github.event_name != 'schedule'
run: ./scripts/model-check.sh ${{ matrix.engine }}

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[suggestion] Every pull request runs ./scripts/model-check.sh with LOOM_MAX_PREEMPTIONS unset. seq::len_belongs_to_the_slot_and_a_header_pair_does_not_mix calls check_at_most(2), and an unset env becomes bound 2, so that test is the ~15 minute step (job 121898809276: 929.96s) while flush and utxo finish in the same second they start. The nightly cron sets LOOM_MAX_PREEMPTIONS=4, and check_limited takes min(bound, cap), so the sequence model stays at 2. Nightly cannot make that test longer.

Suggestion: Keep the sub-second models (flush, utxo, script-pool claim) on the pull-request job, and run the sequence model only on the nightly schedule. Moving it does not raise coverage while check_at_most(2) stays. Raising that cap is the change TESTING.md refuses, because a higher bound still would not exhaust an aarch64 release reorder of the odd advance. Do not put a spinning two-writer case back on the default model job.

- name: model-check ${{ matrix.engine }} (nightly deep budget)
if: github.event_name == 'schedule'
env:
LOOM_MAX_PREEMPTIONS: "4"
MODEL_SHUTTLE_ITERS: "50000"
MODEL_SHUTTLE_DEPTH: "5"
SHUTTLE_RANDOM_SEED: ${{ github.run_id }}
run: ./scripts/model-check.sh ${{ matrix.engine }}
17 changes: 11 additions & 6 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
**Nix is not required** to clone, compile, run `--smoke`, or send a PR.
CI pins **rustc 1.95.0**; [`rust-toolchain.toml`](./rust-toolchain.toml) makes
[rustup](https://rustup.rs) install that channel (plus `rustfmt` and `clippy`)
the first time you run `cargo` in this tree.
the first time you run `cargo` in this tree. [`rust-forward.toml`](./rust-forward.toml)
is the newer compiler the `rust-forward` job checks. It is not the compiler
you develop with. Later pulls move that channel forward.

Operator Linux binaries stay the musl path in [`README.md`](./README.md) /
[`OPERATOR.md`](./OPERATOR.md). This section is **developing the tree**.
Expand Down Expand Up @@ -211,8 +213,9 @@ engineering.
packed `g` (`mphf_g=0`) versus mmap sealed `.fuse8` (`fuse8=0` heap)
and SH BDZ3 occupancy (`mphf_occ=` supers only; occ bits are `file=`)
is that kind of choice. Reclaim of mapped fuse/occ is drop of file pages,
not swap. `strong_tx` and mempool stay process `Vec` (Class C tip-last write-behind
/ live graph); do not mmap those because fuse mapping looked good.
not swap. `strong_tx` stays a process-resident bit image and mempool stays a
process `Vec` (Class C tip-last write-behind / live graph); do not mmap those
because fuse mapping looked good.

Write as if the structure is huge, because in IBD it is. **Address** it
(hash, slot, page, bit offset, subscript). Do not walk everything resident
Expand Down Expand Up @@ -265,11 +268,13 @@ Do not edit [`CHANGELOG.md`](./CHANGELOG.md) on a feature branch. The release
cut folds those files in. Owner: [`docs/releases.md`](./docs/releases.md).

Required **jobs** match [`.github/workflows/ci.yml`](./.github/workflows/ci.yml)
(`qc`, `test`, `windows`, `macos`, `coverage`, `pread`). `qc` is fmt, ast-grep, deny, the script self-tests,
(`qc`, `test`, `windows`, `macos`, `coverage`, `pread`, `rust-forward`). `qc` is fmt, ast-grep, deny, the script self-tests,
clippy, then nixos-module-eval, in that order on one runner. `pread` is the
Linux libc backend for `rbitcoin-store` and `rbitcoin-query`
(`RBITCOIN_IO=pread`). It starts with `coverage`, after `qc` and `test`.
The `test` job does not set `RBITCOIN_IO`.
(`RBITCOIN_IO=pread`). `rust-forward` is `cargo check --workspace --all-targets`
on the channel in [`rust-forward.toml`](./rust-forward.toml). Both start with
`coverage`, after `qc` and `test`. The `test` job does not set `RBITCOIN_IO`
and stays on 1.95.
Label **`nixos-module-runtime`** to run the NixOS module qemu test (not
eval). That job is not required.

Expand Down
Loading
Loading