Repository navigation
Stamp last_tx/last_eos_account on updateCommunity (P2w W3b) - #77
Merged
Merged
Conversation
…2w W3b) The backend's new `communities_changed` AFTER UPDATE trigger (P2w W3a) notifies when `last_tx` changes, so the Wallet can confirm the signer's `cambiatus.cm::update` once it is indexed. This mirrors the stamps the sale and objective updaters already write. Replay-safe: re-indexing the same action writes the same values. DEPLOY ORDER: the columns come from the backend W3a migration. Ship this only after that migration is live; until then the update would fail and be swallowed by the existing catch, so community edits would silently not index. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_017TeHsQCwWCBJzuob6cYEPo
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.
DRAFT: do not merge or deploy until the backend P2w W3a migration (
communities.last_tx/last_eos_account+ thecommunities_changedtrigger) is live in production.Before that, the update fails on the missing columns. The existing
.catchswallows the error, so community edits would silently stop indexing.What
updateCommunitynow also writeslast_tx: payload.transactionIdandlast_eos_account: payload.authorization[0].actor, as the sale and objective updaters already do. The backend trigger fires on alast_txchange; DbListener then tells the signer's Wallet that itsupdatelanded.Replay
Idempotent: re-indexing the same action writes the same values. A replayed old update emits one NOTIFY, and the backend ignores it because no pending tx matches.
Order
:walletpast admins.Lint:
standard✅. There's no test suite in this repo; it gets a chain e2e on the local stack together with W3a.🤖 Generated with Claude Code
https://claude.ai/code/session_017TeHsQCwWCBJzuob6cYEPo