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

Bug: start_height not being respected both in "refresh" RPC call and Wallet.cpp API. #9362

Open
AlwaysCompile opened this issue Jun 11, 2024 · 0 comments

Comments

@AlwaysCompile
Copy link

AlwaysCompile commented Jun 11, 2024

After analyzing #9358 my friend told me there is a bug in Monero software. The software does not respect "start_height" during refreshes. Instead, it will always override the passed height.

You can see this in refresh() in Wallet2.cpp:

// always reset start_height to 0 to force short_chain_ history to be used on // subsequent pulls in this refresh. start_height = 0;

Except it is not "subsequent pulls", but ALL pulls including pulls with explicitly passed start heights. Looking at issue #9358 you see the reproduction steps for this using the wallet RPC. Explicitly passed heights seem to be completely ignored despite the docs saying they will be respected.

For example, the "refresh" RPC call specifically states this:

start_height - unsigned int; (Optional) The block height from which to start refreshing. Passing no value or a value less than the last block scanned by the wallet refreshes from the last block scanned.

However, in practice, it does not work this way in any sense neither from the passed value or the last value scanned. No matter what value is passed it will always refresh based on the blockchain size and the granularity value described in #9361.

I think this is a bug because it is contrary to the documentation and clearly the explicitly passed start_height is not being respected as it should be.

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

No branches or pull requests

2 participants