CauseStarter: persist seeded bridge drafts, home Statements/Projects, and believer-set cache - #133
Merged
Merged
Conversation
Seeded parent owner/slug now persist so reload does not blank the editor, missing draft ids no longer mint a empty cluster, skip-modified is stand-in only, and the editor warns if the connected wallet owns a parent cause.
The cause page fired one indexer query per published plank through Promise.all, so a 40-plank cause opened 40 simultaneous walks on each of four paths: believer sets, aligned projects, plank texts, and the signed-already check. mapWithConcurrency keeps input order and all-or-nothing rejection but holds six in flight. Believer sets also lived in component state, so leaving a cause page and coming back refetched every plank. They now go through a module-level cache keyed by statement and trusted-attester list, sharing in-flight promises between callers. Failures are not cached, or one blip would poison a plank for a whole TTL and make retry look broken; refresh() invalidates first, or the cache would serve the same numbers back. Not fixed here, and noted in inbox.md: the sets themselves are still shipped to the browser in full, so a plank with 100k believers downloads 100k IDs to render one number. That needs an indexer-side aggregate. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Human-authored clusters and LLM bridge-creator instances share the same listener-facing identity; opt-in on clusters is the open question.
Home is the personal dashboard: signed-statement count plus a list page, and projects you created, contributed to, or bookmarked, without turning either into a public directory.
Share the cause-row caption (direct/indirect counts and a projects link) so the Statements page matches other statement surfaces without the selection eye.
An empty chain ref no longer writes a local document that would block later sync, and the project page hydrates on mount instead of only the home list.
Reuse a just-minted seeded path across the remount window, show signed-statement load errors instead of an empty wallet, and drop expired believer-set cache entries so unused planks do not keep full ID sets.
Skip writing the chain list if localStorage gained a key during getUserRef, drop the extra reserved-slug check, and shorten two file-level comments.
AdamSpitz
commented
Aug 20, 2026
AdamSpitz
left a comment
Owner
Author
There was a problem hiding this comment.
Review receipt.
Reviewed PR 133. Fixed hydrate-vs-click clobber on project bookmarks, redundant reserved slug check, and two file-level narrative comments. Remaining follow-up: last-local-wins project bookmarks across devices (causestarter/TODO.md).
Reviewed-with: grok
Reviewed-files: 44
Reviewed-commit: b71a26e
AdamSpitz
commented
Aug 20, 2026
AdamSpitz
left a comment
Owner
Author
There was a problem hiding this comment.
Review receipt.
Reviewed PR 133 after review-fix commit 3919e38. Hydrate-vs-click clobber on project bookmarks is skipped if a local key appears during getUserRef; reserved slug uses RESERVED_REF_NAMES only; last-local-wins across devices remains in causestarter/TODO.md.
Reviewed-with: grok
Reviewed-files: 44
Reviewed-commit: 3919e38
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.
What & why
CauseStarter work that accumulated on this branch:
mapWithConcurrency, six in flight) and cache believer sets at module level so leaving and returning does not refetch every plank. Failures are not cached; expired entries are dropped.Review (enforced for PRs into
dev)/code-review --comment, pi, etc.)review-receivedcheck goes green (scripts/post-review.sh)Checklist
pre-commitfast tests green; full suite runs ondev → master)devfor features;masteronly for releases)