-
Notifications
You must be signed in to change notification settings - Fork 94
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
Reconciliation failed for genesis block account #29
Comments
https://github.com/coinbase/rosetta-cli/blob/master/internal/storage/block_storage.go#L501
If |
You are spot on @tuxcanfly. Looks like this regression was introduced in the large |
Awesome. I was working on fix that involves checking |
I was thinking through some potential fixes here as well. I think there are 2 reasonable approaches here:
I believe your idea is the "most correct" but it could impose a minor usability hurdle in some edge cases for blockchains with genesis allocations and genesis transactions (I think that tradeoff is fine). Let me know if you are going to put up a PR for this @tuxcanfly. Otherwise, I'll take a stab at this! |
Fortunately, it will be pretty straightforward to write a test case here (example test linked below): https://github.com/coinbase/rosetta-cli/blob/1f0d9c523088a77d9f77e03b0d66a31f2d75a563/internal/storage/block_storage_test.go#L371 |
Following up here @tuxcanfly ^^^ |
Working on a fix using option 1 and suggestions. |
Describe the bug
I have a blockchain which contains a transaction in the genesis block. This transaction contains a single output going to an address. I have found that the reconciliation step fails, expecting
computed balance to be twice the node balance (which is simply just the only output from the genesis transaction). The failure log shows, for example:
Reconciliation failed for ss1q7q3h4chglps004u3yn79z0cp9ed24rfr9dn5nv at 0 computed: 4004420000HNS node: 2002210000HNS
To Reproduce
Create a genesis block containing a transaction generating an output to an address.
Run
rosetta-cli check
Expected behavior
Additional context
rosetta-cli version v0.2.3, go version v0.2.3 on ubuntu linux, bionic
The text was updated successfully, but these errors were encountered: