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

rpc: loadtxoutset should return errors that currently go to logs #28621

Open
Sjors opened this issue Oct 9, 2023 · 3 comments · Fixed by #28652
Open

rpc: loadtxoutset should return errors that currently go to logs #28621

Sjors opened this issue Oct 9, 2023 · 3 comments · Fixed by #28652
Labels

Comments

@Sjors
Copy link
Member

Sjors commented Oct 9, 2023

Please describe the feature you'd like to see added.

loadtxoutset should return (more of) the errors that currently only appear in the log.

Is your feature related to a problem, if so please describe it.

Currently most errors encountered during loadtxoutset can only be found via the log.

Describe the solution you'd like

No response

Describe any alternatives you've considered

No response

Please leave any additional context

Errors could be shown by loadtxoutset status if the method is made async (see #28620), otherwise just returned.

@Sjors Sjors added the Feature label Oct 9, 2023
@Sjors Sjors mentioned this issue Oct 9, 2023
@pablomartin4btc
Copy link
Member

Concept ACK.

eg. currently when re-try already processed and completed loadtxoutset on mainnet the returned error message is:

./src/bitcoin-cli -datadir=${AU_DATADIR} loadtxoutset ${AU_DATADIR}/utxo-800000.dat
error code: -32603
error message:
Unable to load UTXO snapshot .../.test_utxo_2/utxo-800000.dat

While in the logs a user would see:

2023-10-09T20:26:13Z [httpworker.2] [snapshot] waiting to see blockheader 00000000000000000002a7c4c1e48d76c5a37902165a270156b7a8d72728a054 in headers chain before snapshot activation
2023-10-09T20:26:13Z [httpworker.2] [snapshot] can't activate a snapshot-based chainstate more than once

I like also the idea to extend the rpc command with the status param: loadtxoutset status, in order to see percentage of processing, errors or warnings, especially if we manage to make it async.

@brunoerg
Copy link
Contributor

brunoerg commented Oct 12, 2023

Perhaps a good first issue?

@Sjors
Copy link
Member Author

Sjors commented Oct 18, 2023

This shouldn't be closed yet. #28652 only fixes one failure mode.

@maflcko maflcko reopened this Oct 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: To do
Development

Successfully merging a pull request may close this issue.

4 participants