Skip to content

Conversation

@algorandskiy
Copy link
Contributor

@algorandskiy algorandskiy commented Apr 7, 2025

Summary

After adding online accounts table data into catchpoint files (see #6177), we figured out the table might have some exceed rows in the following cases:

  1. Multiple modifications of used-to-be online account within the same committing batch: going offline, then transfer.
  2. Used-to-be online accounts modification in between node restart because aggressive online accts caching.

Fixed by comparing the voting data for existing and new accounts when updating the ledger db.

Test Plan

Added a new unit test exercising both cases.

@algorandskiy algorandskiy requested review from cce, gmalouf and jannotti April 7, 2025 18:58
@algorandskiy algorandskiy self-assigned this Apr 7, 2025
@codecov
Copy link

codecov bot commented Apr 7, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 51.70%. Comparing base (558bcc3) to head (0cac60a).
Report is 3 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #6295      +/-   ##
==========================================
+ Coverage   51.69%   51.70%   +0.01%     
==========================================
  Files         649      649              
  Lines       86858    86860       +2     
==========================================
+ Hits        44901    44915      +14     
+ Misses      39094    39089       -5     
+ Partials     2863     2856       -7     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

jannotti
jannotti previously approved these changes Apr 7, 2025
jannotti
jannotti previously approved these changes Apr 7, 2025
@algorandskiy algorandskiy changed the title ledger: fix exceed offline rows in online accounts table ledger: fix exceeding offline rows in online accounts table Apr 8, 2025
@onetechnical onetechnical merged commit 9d579da into algorand:master Apr 8, 2025
20 checks passed
onetechnical pushed a commit to onetechnical/go-algorand that referenced this pull request Apr 8, 2025
cce pushed a commit to cce/go-algorand that referenced this pull request May 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants