Skip to content

Conversation

@codchen
Copy link
Collaborator

@codchen codchen commented Dec 29, 2025

Describe your changes and provide context

usage: seid testutils tx-reads --url $URL --tx-hash $TX
response:

{
  "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48": {
    "0x0000000000000000000000000000000000000000000000000000000000000001": "0x0000000000000000000000004914f61d25e5c567143774b76edbf4d5109a8566",
    "0x10d6a54a4754c8869d6886b5f5d7fbfa5b4522237ea5c60d11bc4e7a1ff9390b": "0x000000000000000000000000807a96288a1a408dbc13de2b1d087d10356395d2",
    "0x166c457a179ae04a1e2ba2459d98bf7c0aa543d9a4552937b325ef74c6c4ba47": "0x000000000000000000000000000000000000000000000000000000000000155e",
    "0x7050c9e0f4ca769c69bd3a8ef740bc37934f8e2c036e5a723fd8ee048ed3f8c3": "0x00000000000000000000000043506849d7c04f9138d1a2050bbf3a0c054402dd",
    "0xc47b9da36cb0e69388cd2c165b12bd89064c9b8f140a685dce964cb91e3ce676": "0x00000000000000000000000000000000000000000000000000000030ec068344"
  }
}

The results indicate all states accessed by a particular transaction, which can be used to mock state in tests

Testing performed to validate your change

n/a

@github-actions
Copy link

github-actions bot commented Dec 29, 2025

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

BuildFormatLintBreakingUpdated (UTC)
✅ passed✅ passed✅ passed✅ passedDec 29, 2025, 12:37 PM

@codecov
Copy link

codecov bot commented Dec 29, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 47.54%. Comparing base (9109a8a) to head (fe41ed0).

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2645      +/-   ##
==========================================
+ Coverage   38.48%   47.54%   +9.05%     
==========================================
  Files         674      350     -324     
  Lines       51042    34231   -16811     
==========================================
- Hits        19643    16274    -3369     
+ Misses      29573    16406   -13167     
+ Partials     1826     1551     -275     
Flag Coverage Δ
sei-cosmos ?
sei-db 69.06% <ø> (ø)
sei-tendermint 47.24% <ø> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.
see 1013 files with indirect coverage changes

🚀 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.

Comment on lines +58 to +64
for contractAddr, stateMap := range reads {
stateOutput := make(map[string]string)
for stateKey, stateValue := range stateMap {
stateOutput[stateKey.Hex()] = stateValue.Hex()
}
outputMap[contractAddr.Hex()] = stateOutput
}

Check warning

Code scanning / CodeQL

Iteration over map Warning test

Iteration over map may be a possible source of non-determinism
Comment on lines +60 to +62
for stateKey, stateValue := range stateMap {
stateOutput[stateKey.Hex()] = stateValue.Hex()
}

Check warning

Code scanning / CodeQL

Iteration over map Warning test

Iteration over map may be a possible source of non-determinism
Comment on lines +52 to +56
for address, reads := range allReads {
for read := range reads {
reads[read] = GetState(url, address, read, height)
}
}

Check warning

Code scanning / CodeQL

Iteration over map Warning test

Iteration over map may be a possible source of non-determinism
Comment on lines +53 to +55
for read := range reads {
reads[read] = GetState(url, address, read, height)
}

Check warning

Code scanning / CodeQL

Iteration over map Warning test

Iteration over map may be a possible source of non-determinism
Comment on lines +146 to +148
for k, v := range v {
kvs = append(kvs, fmt.Sprintf("\"%s\":%s", k, formatParam(v)))
}

Check warning

Code scanning / CodeQL

Iteration over map Warning test

Iteration over map may be a possible source of non-determinism
Comment on lines +152 to +154
for k, v := range v {
kvs = append(kvs, fmt.Sprintf("\"%s\":%s", k, formatParam(v)))
}

Check warning

Code scanning / CodeQL

Iteration over map Warning test

Iteration over map may be a possible source of non-determinism
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.

3 participants