Skip to content

Add 9 bytes of metadata to FlatKV store#3163

Draft
cody-littley wants to merge 137 commits intomainfrom
cjl/9-byte-metadata
Draft

Add 9 bytes of metadata to FlatKV store#3163
cody-littley wants to merge 137 commits intomainfrom
cjl/9-byte-metadata

Conversation

@cody-littley
Copy link
Copy Markdown
Contributor

Describe your changes and provide context

In order to support BUD proofs, we need to add "block last modified" metadata to each value. Since we are about to do a migration, it's lower effort in the long run to add this metadata now instead of later.

Testing performed to validate your change

Unit tests

@cody-littley cody-littley self-assigned this Apr 1, 2026
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 1, 2026

The latest Buf updates on your PR. Results from workflow Buf / buf (pull_request).

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedApr 1, 2026, 8:41 PM

@codecov
Copy link
Copy Markdown

codecov bot commented Apr 1, 2026

Codecov Report

❌ Patch coverage is 85.54070% with 119 lines in your changes missing coverage. Please review.
✅ Project coverage is 58.63%. Comparing base (232fee5) to head (2050921).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
sei-db/state_db/sc/flatkv/store_write.go 67.42% 26 Missing and 17 partials ⚠️
sei-db/state_db/sc/flatkv/store_read.go 75.80% 21 Missing and 9 partials ⚠️
sei-db/state_db/sc/flatkv/store_apply.go 83.53% 19 Missing and 8 partials ⚠️
sei-db/state_db/sc/flatkv/exporter.go 62.06% 9 Missing and 2 partials ⚠️
sei-db/state_db/sc/flatkv/iterator.go 50.00% 4 Missing and 1 partial ⚠️
sei-db/common/utils/hash64.go 85.71% 1 Missing and 1 partial ⚠️
sei-db/common/rand/canned_random.go 66.66% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #3163      +/-   ##
==========================================
+ Coverage   58.57%   58.63%   +0.06%     
==========================================
  Files        2099     2108       +9     
  Lines      173853   174359     +506     
==========================================
+ Hits       101829   102244     +415     
- Misses      62864    62925      +61     
- Partials     9160     9190      +30     
Flag Coverage Δ
sei-chain-pr 71.49% <85.54%> (?)
sei-db 70.41% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
sei-db/state_db/sc/flatkv/config.go 53.33% <100.00%> (+0.63%) ⬆️
sei-db/state_db/sc/flatkv/flatkv_test_config.go 100.00% <100.00%> (ø)
sei-db/state_db/sc/flatkv/keys.go 100.00% <100.00%> (ø)
sei-db/state_db/sc/flatkv/store.go 70.87% <100.00%> (ø)
sei-db/state_db/sc/flatkv/vtype/account_data.go 100.00% <100.00%> (ø)
sei-db/state_db/sc/flatkv/vtype/base_types.go 100.00% <100.00%> (ø)
sei-db/state_db/sc/flatkv/vtype/code_data.go 100.00% <100.00%> (ø)
sei-db/state_db/sc/flatkv/vtype/legacy_data.go 100.00% <100.00%> (ø)
.../state_db/sc/flatkv/vtype/pending_account_write.go 100.00% <100.00%> (ø)
sei-db/state_db/sc/flatkv/vtype/storage_data.go 100.00% <100.00%> (ø)
... and 7 more
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant