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

Fix shard ranges in seedtos3.sh #15

Merged
merged 1 commit into from
May 7, 2024
Merged

Commits on May 3, 2024

  1. Fix shard ranges in seedtos3.sh

    The shard_seeder tool (in opencbdc-tx) computes shard range
    as 256/#shards, i.e., rounds down the range. This script computes
    it as 255/#shards +1, i.e., rounds it up. This doesn't matter if
    num shards is a power of 2, but for other values, the tool and script
    differ, causing errors in seed generation. The quick fix in this
    commit is to calculate the range by rounding down, as the tool
    does, and to ensure that the last range is extended, if needed,
    to the 1-byte max or 255.
    
    Signed-off-by: Ram Darbha <[email protected]>
    darbha-ram committed May 3, 2024
    Configuration menu
    Copy the full SHA
    892e42a View commit details
    Browse the repository at this point in the history