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

Status code / slot reorganization #374

Merged
merged 17 commits into from
Jan 6, 2019
Merged

Status code / slot reorganization #374

merged 17 commits into from
Jan 6, 2019

Commits on Dec 28, 2018

  1. Status code / slot reorganization

    * Added `activation_slot`, `exit_slot`, `penalized_slot`, `withdrawal_slot`, use these to determine if a validator is active
    * Universal min activation/exit delay of 256 slots
    * Min exit time of ~1 day, but penalization delays this to ~18 days
    * Penalty calculation period of `[time penalized - 18 days, time penalized + 18 days]`; made the total penalties array fixed size and wraparound to make calculation more fine-grained
    * Processes withdrawals in all epochs, not just dynasty-changing epochs
    * Change `get_shuffling` function to take slot as argument
    
    Not yet done:
    
    * Removed `shard_committees` from the state
    * Removed persistent committees from the state
    vbuterin committed Dec 28, 2018
    Configuration menu
    Copy the full SHA
    d9e897b View commit details
    Browse the repository at this point in the history
  2. Fixed seed lookahead

    vbuterin committed Dec 28, 2018
    Configuration menu
    Copy the full SHA
    85d0010 View commit details
    Browse the repository at this point in the history

Commits on Dec 29, 2018

  1. Initialize status_flags

    vbuterin committed Dec 29, 2018
    Configuration menu
    Copy the full SHA
    bd5b32e View commit details
    Browse the repository at this point in the history
  2. Update specs/core/0_beacon-chain.md

    Co-Authored-By: vbuterin <v@buterin.com>
    hwwhww and vbuterin committed Dec 29, 2018
    Configuration menu
    Copy the full SHA
    14f49aa View commit details
    Browse the repository at this point in the history

Commits on Dec 30, 2018

  1. Fixed as per hww's comments

    vbuterin committed Dec 30, 2018
    Configuration menu
    Copy the full SHA
    4a93374 View commit details
    Browse the repository at this point in the history

Commits on Dec 31, 2018

  1. Configuration menu
    Copy the full SHA
    0119701 View commit details
    Browse the repository at this point in the history
  2. Cleanups and fixes

    Cleanups
    
    * (typo) Remove `get_new_validator_registry_delta_chain_tip` from table of contents
    * (typo) Update "Routines for updating validator status" in table of contents
    * Update `FAR_FUTURE_SLOT` from `2**63` to `2**64 - 1`
    * Put more constants in "Initial values", homogenise
    * Cleanup note formatting
    * Remove `ZERO_BALANCE_VALIDATOR_TTL` logic (to be possibly reintroduced in phase 2).
    * Cleanup `min_empty_validator_index`
    * Rename `deposit` to `amount` in `process_deposit` and `DepositData`.
    * (typo) Remove new line under `process_penalties_and_exits`
    * (typo) "Status codes" => "Status flags" in the table of contents
    * (typo) `(state.slot - EPOCH_LENGTH) % LATEST_RANDAO_MIXES_LENGTH` => Use `SEED_LOOKAHEAD` instead.
    * Put `state.validator_registry_latest_change_slot = state.slot` in `update_validator_registry`.
    * Use `GENESIS_SLOT` for `last_poc_change_slot=0` and `second_last_poc_change_slot=0`.
    
    Bugfixes
    
    * (typo) `validator_exit` => `exit.validator_index`
    * Separate initial deposits and initial activations to avoid double activations
    * Replace `proposer.status != EXITED_WITH_PENALTY` with `validator.penalized_slot > state.slot` in two different places.
    * Replace `status == EXITED_WITH_PENALTY` with `validator.penalized_slot <= state.slot` (and validator active) in two different places.
    JustinDrake committed Dec 31, 2018
    Configuration menu
    Copy the full SHA
    d36b403 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    fd295eb View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    fdb1b67 View commit details
    Browse the repository at this point in the history

Commits on Jan 2, 2019

  1. Bunch of fixes

    vbuterin committed Jan 2, 2019
    Configuration menu
    Copy the full SHA
    2105614 View commit details
    Browse the repository at this point in the history
  2. Remove returned value for process_deposit

    Also trim trailing whitespace
    JustinDrake committed Jan 2, 2019
    Configuration menu
    Copy the full SHA
    696bf23 View commit details
    Browse the repository at this point in the history
  3. Fix typo

    JustinDrake committed Jan 2, 2019
    Configuration menu
    Copy the full SHA
    93b18d5 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    b614595 View commit details
    Browse the repository at this point in the history

Commits on Jan 4, 2019

  1. Configuration menu
    Copy the full SHA
    3f4be7a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    a5b1f2c View commit details
    Browse the repository at this point in the history
  3. Put back spaces

    vbuterin committed Jan 4, 2019
    Configuration menu
    Copy the full SHA
    c24f907 View commit details
    Browse the repository at this point in the history

Commits on Jan 5, 2019

  1. Configuration menu
    Copy the full SHA
    fd2cc69 View commit details
    Browse the repository at this point in the history