Skip to content
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

Client sometimes reports "No block with hash ..." while waiting for valid transaction to be committed #249

Open
Bargsteen opened this issue Mar 31, 2023 · 1 comment
Labels
[Type] Bug Something isn't working

Comments

@Bargsteen
Copy link
Contributor

Bargsteen commented Mar 31, 2023

Bug Description
The client waits for transactions to be committed and finalized by default.
If a transaction is valid and eventually included in a finalized block, this waiting behavior should always succeed (as far as I know).
But apparently, that is (no longer) the case.

Steps to Reproduce
Not sure as it happened once while making some smart contract-related transactions.
But it occurred during a contract update.

Expected Result

Transaction '18c2c67d50186e10c017bb911dfafcb33daed9fd9d2b697970533a2d35c65adb' sent to the baker.
Waiting for the transaction to be committed and finalized.
You may skip this step by interrupting the command using Ctrl-C (pass flag '--no-wait' to do this by default).
The transaction will still get processed and may be queried using
  'concordium-client transaction status 18c2c67d50186e10c017bb911dfafcb33daed9fd9d2b697970533a2d35c65adb'.
[13:51:21] Waiting for the transaction to be committed.....
Transaction is finalized into block 9418830e27ad7d557e29dbbe8a260c1e9829ec47641c6a617750ab639922b41a with status "success" and cost 4.639231 CCD (1838 NRG).
[13:51:26] Transaction finalized.
Successfully updated contract instance {"index":4190,"subindex":0} ('fibwasm') using the function 'receive'.

Actual Result

Transaction '617f2c80ba896cce7f8a7ec26102f0f8b70fa3d1c8bfeddbf544985d64e7d521' sent to the baker.
Waiting for the transaction to be committed and finalized.
You may skip this step by interrupting the command using Ctrl-C (pass flag '--no-wait' to do this by default).
The transaction will still get processed and may be queried using
  'concordium-client transaction status 617f2c80ba896cce7f8a7ec26102f0f8b70fa3d1c8bfeddbf544985d64e7d521'.
[14:18:42] Waiting for the transaction to be committed....
Error: No block with block with hash ee758c2aa8b75c5278e953ffbdea3de37bb0c1c94a5de5cd2637dcf00f94853f exists.

Also, the error message here is slightly off. Should have been: No block with hash:.

Versions

  • Software Version: 5.1.1
  • OS: macOS 13.2.1
  • Processor: Apple M2 Pro

┆Issue is synchronized with this Jira Bug by Unito

@Bargsteen Bargsteen added the [Type] Bug Something isn't working label Mar 31, 2023
@abizjak
Copy link
Contributor

abizjak commented Jun 11, 2023

The cause of this is that when the transaction gets committed we then try to get schemas in all the blocks in which it is committed.

And some of those blocks might no longer exist since they can be pruned.

We can probably revise getTxContractInfoWithSchemas, where this error is caused, to not fail, but rather to not return the schema in the case it cannot find the block.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Type] Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants