Repository navigation
doc: Change GiB to GB in release-process.md - #30171
BenWestgate wants to merge 1 commit into
Conversation
This will make it consistent with the Welcome gui and code comments. I noticed the Welcome GUI was using these values as if they were GB, not GiB. Then I read the comments in chainparams.h: /** Minimum free space (in GB) needed for data directory */ /** Minimum free space (in GB) needed for data directory when pruned; Does not include prune target*/ This doc is the only place that says to use GiB, and while an 8-10% overhead can account for the unit conversion, we say the overhead is for growth between releases, not misusing the units (in the GUI it could lead to running out of space without a warning).
|
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. Code CoverageFor detailed information about the code coverage, see the test coverage report. ReviewsSee the guideline for information on the review process.
If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update. |
|
Concept ACK c04edce. This assumes the value should be displayed in GB. Is there a benefit to doing the calculation and displaying in GiB instead? |
Software usually displays large sizes in GB because that's what the operating system and storage manufacturers use. |
I don't think that's universally true. I believe Apple generally uses GB (meaning 109), Microsoft generally uses GB (meaning 230), and open-source systems use a mix (sometimes using GiB to mean 230). |
Good to know. Should the value we display depend on platform then? At the very least I think we should be consistent within the repository or within a file. Currently we do math that adds and subtracts GiB from GB in the GUI welcome screen which will cause issues. bitcoin-core/gui#821
|
This makes sense to me for the UI, since the average user will be able to compare values to their local environments in the macOS Finder and Windows Explorer applications. |
|
This is a duplicate of #29678 (without the accompanying code fixes) |
This will make it consistent with the Welcome GUI and code comments which use "GB" for the
m_assumed_blockchain_sizeandm_assumed_chain_state_sizevalues.Since they are used as GB values to calculate disk space in GB needed in the GUI, measuring size in GiB here will cause users to run out of space without a graphical warning. The error between units is over 45 GB for the full chain.
This doc is the only place we say they are GiB, and while an 8-10% overhead can account for the unit conversion, we say the overhead was for growth between releases, not abusing the units without conversion.
bitcoin/src/kernel/chainparams.h
Lines 106 to 109 in 4c387cb
Here is a 3rd spot where the GiB value is presented to the user as GB:
bitcoin/src/init.cpp
Lines 1696 to 1713 in 4c387cb
However, it comes right after using the value correctly as GiB (unlike in GUI which uses it as GB). So that may need to be patched to calculate bytes from GB instead of GiB.