Skip to content

Remove all unused epoch code - #1537

Merged
mergify[bot] merged 4 commits into
CodeChain-io:masterfrom
foriequal0:feature/remove-epoch
May 17, 2019
Merged

mergify[bot] merged 4 commits into
CodeChain-io:masterfrom
foriequal0:feature/remove-epoch

Conversation

@foriequal0

@foriequal0 foriequal0 commented May 16, 2019 •

Copy link
Copy Markdown
Contributor

This is a revival of old patches which was rebased into #1519 with heavy modifications.
After some design changes, I decided that #1519 will be closed, and the features (last_term_id, solo force term end, etc) will be continued upon this.
This PR should not bring breaking changes
I'll check these conditions.

  • sync on master, continue to sync on this branch.
  • sync on this branch, continue to sync on master.

Resolves: #1507

majecty
majecty previously approved these changes May 16, 2019

@majecty majecty left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

LGTM

@foriequal0
foriequal0 marked this pull request as ready for review May 17, 2019 04:32
`is_epoch_begin` flag which is determined by the result of
`epoch_tranistion` call doesn't make any differences whether it is true
or false since `on_new_block`, `on_epoch_begin` does nothing on it. So
it is safe to remove. We can even remove reading `epoch_transition`.
`on_new_block` does nothing after removing `on_epoch_begin`
`epoch_transition` is not used anymore after removing `on_epoch_begin`
Inserted `EpochTransition` is not read anymore and inserting it does not
change state. So removing it doesn't introduce breaking change unless
reusing the key index.
@mergify
mergify Bot merged commit 3bc234e into CodeChain-io:master May 17, 2019
@foriequal0
foriequal0 deleted the feature/remove-epoch branch May 17, 2019 05:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Remove unused epoch-related code

3 participants