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

Subsidy halving interval #802

Merged
merged 1 commit into from Jan 20, 2022

Conversation

casey
Copy link
Contributor

@casey casey commented Jan 20, 2022

Fixes #801.

Copy link
Collaborator

@Kixunil Kixunil left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that it'd be better to squash trivial commit like added period. If you're going to do it you might as well format the number as 210_000 which is easier to read.

@Kixunil Kixunil added enhancement trivial Obvious, easy and quick to review (few lines or doc-only...) labels Jan 20, 2022
@casey
Copy link
Contributor Author

casey commented Jan 20, 2022

I think that it'd be better to squash trivial commit like added period. If you're going to do it you might as well format the number as 210_000 which is easier to read.

Done!

Copy link
Collaborator

@Kixunil Kixunil left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 94dd57d

@Kixunil Kixunil added the one ack PRs that have one ACK, so one more can progress them label Jan 20, 2022
@Kixunil
Copy link
Collaborator

Kixunil commented Jan 20, 2022

This is the kind of feature addition that I'm fine with adding to RC.

@dpc
Copy link
Contributor

dpc commented Jan 20, 2022

Just a though: I generally add "units" to name of constants when possible. So SUBSIDY_HALVING_BLOCKS_INTERVAL or SUBSIDY_HALVING_INTERVAL_BLOCKS? Here it seems somewhat unnecessary (I can't think of any other unit that would make sense), but the rule of thumb is a rule of thumb so just letting you know.

@casey
Copy link
Contributor Author

casey commented Jan 20, 2022

In the case of constants from Bitcoin Core, it's probably best to use whatever name is used in core, adapted to the local naming convention. (I.e. SCREAMING_SNAKE_CASE).

If you Google nSubsidyHalvingInterval you get a lot of hits, so keeping it consistent with those hits, and with core, is probably a good idea.

Copy link
Member

@apoelstra apoelstra left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK 94dd57d

@apoelstra apoelstra merged commit 45ed4df into rust-bitcoin:master Jan 20, 2022
@casey casey deleted the subsidy-halving-interval branch January 20, 2022 19:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement one ack PRs that have one ACK, so one more can progress them trivial Obvious, easy and quick to review (few lines or doc-only...)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add nSubsidyHalvingInterval constant
4 participants