doc: Change GiB to GB in release-process.md #30171

pull BenWestgate wants to merge 1 commits into bitcoin:master from BenWestgate:patch-2 changing 1 files +2 −2
  1. BenWestgate commented at 5:06 pm on May 24, 2024: contributor

    This will make it consistent with the Welcome GUI and code comments which use “GB” for the m_assumed_blockchain_size and m_assumed_chain_state_size values.

    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.

    https://github.com/bitcoin/bitcoin/blob/4c387cb64ff4c74f911b1559fb0ef143ee6c268b/src/kernel/chainparams.h#L106-L109 image

    Here is a 3rd spot where the GiB value is presented to the user as GB: https://github.com/bitcoin/bitcoin/blob/4c387cb64ff4c74f911b1559fb0ef143ee6c268b/src/init.cpp#L1696-L1713

    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.

  2. doc: Change GiB to GB in release-process.md
    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).
    c04edce83d
  3. DrahtBot commented at 5:06 pm on May 24, 2024: contributor

    The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

    Code Coverage

    For detailed information about the code coverage, see the test coverage report.

    Reviews

    See the guideline for information on the review process.

    Type Reviewers
    Concept ACK epiccurious

    If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update.

  4. DrahtBot added the label Docs on May 24, 2024
  5. epiccurious commented at 5:19 pm on May 24, 2024: none

    Concept ACK c04edce83db41cfce7a0a2f3418cf830c2e8afb5.

    This assumes the value should be displayed in GB. Is there a benefit to doing the calculation and displaying in GiB instead?

  6. BenWestgate commented at 5:35 pm on May 24, 2024: contributor

    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.

  7. sipa commented at 6:23 pm on May 24, 2024: member

    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).

  8. showtime73 commented at 6:25 pm on May 24, 2024: none
    Hello World
  9. BenWestgate commented at 6:45 pm on May 24, 2024: contributor

    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. https://github.com/bitcoin-core/gui/issues/821

    In response to litigation over whether the makers of electronic storage devices must conform to Microsoft Windows’ use of a binary definition of “GB” instead of the metric/decimal definition, the United States District Court for the Northern District of California rejected that argument, ruling that “the U.S. Congress has deemed the decimal definition of gigabyte to be the ‘preferred’ one for the purposes of ‘U.S. trade and commerce.’”

    To resolve this difficulty, IEC 80000-13 clarifies that a gigabyte (GB) is 10^9 bytes and specifies the term gibibyte (GiB) to denote 2^30 bytes.

  10. epiccurious commented at 7:19 pm on May 24, 2024: none

    Should the value we display depend on platform then?

    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.

  11. luke-jr commented at 2:59 pm on May 28, 2024: member
    This is a duplicate of #29678 (without the accompanying code fixes)
  12. BenWestgate closed this on May 28, 2024


github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-11-23 09:12 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me