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

Confusing error message when enabling --watchonlywallet and --flatutreexoproofindex #188

Open
kcalvinalvin opened this issue Jun 18, 2024 · 1 comment

Comments

@kcalvinalvin
Copy link
Contributor

--flatutreexproofindex enables --noutreexo internally but it doesn't alert the user of doing so. When a user tries to enable --watchonlywallet it errors out and gives a confusing error message:

loadConfig: the --watchonlywallet requires the --noutreexo option off
@1amhesus
Copy link

Hello @kcalvinalvin,

I was looking into the code, specifically lines 1217-1222(config.go), where the current error message that appears when using the --watchonlywallet option could potentially be confusing for users because users can't recognize these two option conflict. Firstly, I suggest that some works on improving this error message to make it clearer with aditing README.md like below,

Bridge nodes are nodes that keep the entire merkle forest and attach proofs to new blocks and transactions. Since miners and nodes publish blocks and transactions without proofs, these nodes are needed to allow for utreexo nodes without a soft fork. To run a bridge node:

# Either one will work. The only difference these have is that the flatutreexoproofindex
# stores all the data in .dat files instead of leveldb. It makes it easier to read the
# proofs for tinkering.
# Note: The --flatutreexoproofindex option automatically enables --noutreexo. 
# If you use the --watchonlywallet option, it will conflict with --noutreexo and cause an error.
`./utreexod --flatutreexoproofindex`
`./utreexod --utreexoproofindex`

# For running bridge nodes that are also archival.
# Note: The --flatutreexoproofindex option automatically enables --noutreexo. 
# If you use the --watchonlywallet option, it will conflict with --noutreexo and cause an error.
`./utreexod --flatutreexoproofindex --prune=0`
`./utreexod --utreexoproofindex --prune=0`

Additionally, in lines 1199-1207(config.go), the --flatutreexoproofindex option automatically enables --noutreexo. It might be helpful to add a notification to inform the user about this internal activation.

Lastly, I’m curious to know if you have any thoughts on restructuring the relationship between these conflicting options. Do you feel that this is something necessary to do immediately?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants