-
Notifications
You must be signed in to change notification settings - Fork 36.2k
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
Bitcoin-Qt (Settings) reports incorrect "Size of database cache" #11788
Comments
I don't think qt spin-boxes can be set to a specific value (at least acc to the documentation here: http://doc.qt.io/qt-5/qspinbox.html). Since at startup, we default to 450, we could change the minimum value of the spin-box to the cli value. This however, would prevent the user from reducing the db cache size from the cli value. What do you suggest? |
I suppose this question is meant for the devs, but just in case: I suggest to just show (display) it. Because right below there's |
The problem:
The layers are
We should at least inform the user that the GUI set value does overwrite in case it's set. |
@jonasschnelli if you set DBCache in the GUI, bitcoin.conf remains unchanged. |
@unsystemizer I think what he means is that it supersedes the bitcoin.conf value in that run, not overwrites. |
@unsystemizer: Yes. The bitcoin.conf files gets never changed by Core. But GUI / QT settings are stored in a different file and supersedes the settings in |
Hey guys, played around and I think I might have a fix(?). In optionsmodel.cpp, I check if the -dbcache flag and if it's set, I set the settings value to be the value of the flag and it displays the correct value in the options menu. Is there some reason this is not good? I'm new. otherwise, i'll submit a PR! :) Edit: given no flag, it now starts with the dbcache value in bitcoin.conf. This seems to make sense to me.. |
Sounds good, but if the value is set to something higher or lower and saved elsewhere, will the correct value be displayed? One part I don’t understand is what if bitcoind is started instead of Bitcoin-Qt, does the custom value from Qt not take effect in that case? That would be very confusing (if cache changed depending on how you start). But that is a separate thing from the issue at hand, so at least if the correct value was displayed I would be happy as far as this issue is concerned. |
I think so, because qt doesn't overwrite the config in the conf file as pointed out earlier. This would be a usability issue, so I guess someone from Core would have to comment about this. |
@Varunram - you're correct. The qt settings don't overwrite the |
Tested after #14375 merging. Case A
Case B
IMO, the GUI behaves as expected. @MarcoFalke, @fanquake, @jonasschnelli Close? |
debug.log reflects the correct amount:
However, the UI does not:
Both Bitcoin-Qt and bitcoind log the correct amount, only Bitcoin-Qt UI reports 450 MB instead of 8 GB.
I tried to start it with
-dbcache=8000
, it still shows 450 MB.The text was updated successfully, but these errors were encountered: