Repository navigation
fix(station): replace fronts of streams 5, stamp hub writes with the clock now, index pace spend - #7952
Merged
Conversation
…clock now, index pace spend - front.rs STREAMS 5 -> 6 (and mesh.mbt says 6): a front is kept across updates and only replaced when STREAMS rises, so one started before iroh.probeRelay (#7567), the shell's unix backlog/retry and conn.hand skip (#7568) and the noq path-idle/RTT-stall fixes (#7869/#7899/#7919) kept running the old binary after updating. - session_hub Hub::tw sets the threads store's now from the hub's clock before each write: insert_message stamps entries.at from the store's cached now, which nothing refreshed, so a person's message could carry an `at` hours off its ts. - accounts_pool pace_view finds a profile's (hour, scope) entry through a map instead of scanning the list for each spend row (quadratic on GET /profiles/pace); output is byte-identical (NaN hours stay separate, -0 and 0 merge). Tests: launcher test for a streams-5 front being replaced; harness op say.stampsNow with a node test (fails without the fix: at = the store's start time); a pace_view golden recorded from the old implementation. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
STREAMS5 → 6 (station/native/launcher/src/front.rs,station/mb/src/front/mesh.mbt). The launcher keeps a front across updates and replaces it only whenSTREAMSrises (or the macOS launcher identity changes). A front started before fix(shell): route iroh.probeRelay to the endpoint's operations #7567 (iroh.probeRelay), fix(shell): raise unix backlog, retry connect, and skip or close failed streams #7568 (unix backlog/retry,conn.handskip) and fix(mesh): bump noq-proto rev to 63b8fad9d5 to fix handshake close loop and drained panic #7869/chore(mesh): pin noq last-open-path idle cleanup #7899/feat(mesh): request bounded single-path pings when observed RTT samples stall #7919 (noq path-idle and RTT-stall fixes) kept running its old binary after updating, and loggedno operation iroh.probeRelay.Hub::twsets the threads store's now (station/mb/src/session_hub/hub_in.mbt).insert_messagestampsentries.atfrom the store's cachednow, which nothing in the hub refreshed, so a message'satcould be hours off itsts. Every hub write goes throughtw. Directself.threads.*calls insession_hubare reads that do not usenow.pace_viewindexes spend by(hour, scope)(station/mb/src/accounts_pool/pace.mbt). Each spend row scanned its profile's whole list, which madeGET /profiles/pacequadratic. A per-profile map now finds the entry. The output is byte-identical: NaN hours stay separate entries and-0merges with0, as==had them.Tests
a_front_from_before_the_shell_and_path_fixes_is_replaced_by_the_launcher_that_takes_it_up(a front sayingstreams: 5is replaced). The fixtures now say 6.say.stampsNowand node testMoonBit session_hub stamps a person's message with the clock's now…: the clock moves 60 s after the store is made, thenHub::say. Without the fix,atis the store's start time and the test fails.accounts_poolwbtestpace_view adds each spend row…: the golden was recorded from the old linear implementation and passes unchanged with the new one.Ran:
cargo test(launcher),moon check --target native --warn-list -aandmoon test --target nativeforsrc/front src/session_hub src/accounts_pool, the node harness tests, andsh scripts/check.sh push origin/main..HEAD.Model: Claude Opus 5.5. Test frameworks: cargo test, moon test, node:test.
🤖 Generated with Claude Code
Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.