celestia-node
celestia-node copied to clipboard
fix(blob)!: tendermint compatible commitment proof json marshall
Fixes https://github.com/celestiaorg/celestia-node/issues/3918
Please note: this PR is BREAKING as commitment proof encoding has changed.
yes, it uses coretypes.RowProof. Everything that comes from core (tendermint fork) should be serialized with tendermint json encoder / decoder as it treats 64 bit integers differently (stringifies them)
thanks for your response @zvolin. And why is this change useful?
After second thinking about this, I guess you're right, this needs fixing
And why is this change useful?
to have unified representation of objects regardless whether they are returned from celestia-node api or tendermint rest api. Moreover, tendermint implementations in different languages can have the rules how to encode types in different level than in go, namely tendermint-rs bakes how the type is meant to be encoded on type level, not encoder level, so in lumina we had to patch tendermint to achieve celestia-node compatible representation, but we could never be compatible with both tendermint and celestia-node.
tl;dr it originates from us wishing to drop tendermint-rs fork but I believe it's a good thing in general
@zvolin could you please fix lint?
switched to marshaling whole type as per https://github.com/celestiaorg/celestia-node/pull/3930#discussion_r1837870368
Linter failed.
should be good now, sorry
blob_fuzz_test.go:69: invalid 64-bit integer encoding "64", expected string
:crossed_fingers: sd '"(total|index)":([0-9]+)' '"$1":"$2"' blob/testdata/**/*.json
Codecov Report
Attention: Patch coverage is 90.90909% with 1 line in your changes missing coverage. Please review.
Please upload report for BASE (
feature/api-breaks@2ff0d14). Learn more about missing BASE report.
| Files with missing lines | Patch % | Lines |
|---|---|---|
| header/header.go | 0.00% | 1 Missing :warning: |
Additional details and impacted files
@@ Coverage Diff @@
## feature/api-breaks #3929 +/- ##
=====================================================
Coverage ? 35.60%
=====================================================
Files ? 307
Lines ? 24168
Branches ? 0
=====================================================
Hits ? 8604
Misses ? 14608
Partials ? 956
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
:rocket: New features to boost your workflow:
- :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
make test-integration SHORT=true TAGS=sync passes for me locally :thinking:
The test seems to be flaky.