-
Notifications
You must be signed in to change notification settings - Fork 122
fix: consider microblock transactions in balance calculations #2277
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Vercel deployment URL: https://stacks-blockchain-6kzt0wrg5-hirosystems.vercel.app 🚀 |
Codecov ReportAll modified and coverable lines are covered by tests ✅ 📢 Thoughts on this report? Let us know! |
zone117x
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
## [8.11.0](v8.10.0...v8.11.0) (2025-05-26) ### Features * add /extended/v2/block-tenures/:height/blocks endpoint ([#2285](#2285)) ([f5c2e01](f5c2e01)) * stacks core event and rpc proxy body limits configurable via env ([#2278](#2278)) ([8a54e9d](8a54e9d)) * store and expose vm_error for failed transactions ([#2286](#2286)) ([7ac7513](7ac7513)) ### Bug Fixes * consider microblock transactions in balance calculations ([#2277](#2277)) ([3418863](3418863)) * count stx mint data at block 0 towards account balances ([#2289](#2289)) ([a0cd9f2](a0cd9f2)) * ignore unanchored param for BNS names endpoint ([#2263](#2263)) ([3d33725](3d33725)) * keep a table of latest stacks node event timestamps ([#2266](#2266)) ([6f111ad](6f111ad)) * module imports in block tenure routes ([#2287](#2287)) ([2cb442e](2cb442e)) * **rosetta:** get current block should only join by stacks chain tip information ([#2265](#2265)) ([78ebad0](78ebad0)) * simplify transaction events query ([#2279](#2279)) ([517ca68](517ca68))
|
🎉 This PR is included in version 8.11.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
The API has Stacks 2.x logic to avoid re-inserting transactions to the DB during a
/new_blockevent when those transactions were previously inserted during a/new_microblockevent. However, the new /extended/v2 balance endpoint logic only considers/new_blocktransactions when adding/subtracting from account balances. This is causing some old 2.x blocks to warp balances in accounts that happened to have transactions confirmed in previous microblocks.This PR changes this behavior so these balance calculations always include all transactions regardless of microblocks. It also includes a migration that will execute a query to recompute all transaction balances to correct the issue on deployed environments.
Fixes #2267