{"action":"created","comment":{"url":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls/comments/244551294","pull_request_review_id":188457513,"id":244551294,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDI0NDU1MTI5NA==","diff_hunk":"@@ -1330,90 +1324,42 @@ def process_deposit(state: BeaconState,\n     return index\n ```\n \n-### Routine for updating validator status\n+### Routines for updating validator status\n \n-```python\n-def update_validator_status(state: BeaconState,\n-                            index: int,\n-                            new_status: int) -> None:\n-    \"\"\"\n-    Update the validator status with the given ``index`` to ``new_status``.\n-    Handle other general accounting related to this status update.\n-    Note that this function mutates ``state``.\n-    \"\"\"\n-    if new_status == ACTIVE:\n-        activate_validator(state, index)\n-    if new_status == ACTIVE_PENDING_EXIT:\n-        initiate_validator_exit(state, index)\n-    if new_status in [EXITED_WITH_PENALTY, EXITED_WITHOUT_PENALTY]:\n-        exit_validator(state, index, new_status)\n-```\n-\n-The following are helpers and should only be called via `update_validator_status`:\n+_Note that all functions in this section mutate `state`_.\n \n ```python\n-def activate_validator(state: BeaconState,\n-                       index: int) -> None:\n-    \"\"\"\n-    Activate the validator with the given ``index``.\n-    Note that this function mutates ``state``.\n-    \"\"\"\n+def activate_validator(state: BeaconState, index: int, immediate: bool) -> None:","path":"specs/core/0_beacon-chain.md","position":null,"original_position":325,"commit_id":"011970169c5907d8016e0dea8726407f5b8c63c3","original_commit_id":"4a9337402584bf24808ead3238b7cd25b2686ad5","user":{"login":"vbuterin","id":2230894,"node_id":"MDQ6VXNlcjIyMzA4OTQ=","avatar_url":"https://avatars1.githubusercontent.com/u/2230894?v=4","gravatar_id":"","url":"https://api.github.com/users/vbuterin","html_url":"https://github.com/vbuterin","followers_url":"https://api.github.com/users/vbuterin/followers","following_url":"https://api.github.com/users/vbuterin/following{/other_user}","gists_url":"https://api.github.com/users/vbuterin/gists{/gist_id}","starred_url":"https://api.github.com/users/vbuterin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vbuterin/subscriptions","organizations_url":"https://api.github.com/users/vbuterin/orgs","repos_url":"https://api.github.com/users/vbuterin/repos","events_url":"https://api.github.com/users/vbuterin/events{/privacy}","received_events_url":"https://api.github.com/users/vbuterin/received_events","type":"User","site_admin":false},"body":"Renamed to `genesis`.\r\n\r\n> (Side question: could we always do validator.activation_slot = state.slot + ENTRY_EXIT_DELAY, including at genesis?)\r\n\r\nI suppose we could, but not sure what the value is...","created_at":"2018-12-31T02:44:37Z","updated_at":"2018-12-31T02:44:37Z","html_url":"https://github.com/ethereum/eth2.0-specs/pull/374#discussion_r244551294","pull_request_url":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls/374","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls/comments/244551294"},"html":{"href":"https://github.com/ethereum/eth2.0-specs/pull/374#discussion_r244551294"},"pull_request":{"href":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls/374"}},"in_reply_to_id":244548717},"pull_request":{"url":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls/374","id":241374099,"node_id":"MDExOlB1bGxSZXF1ZXN0MjQxMzc0MDk5","html_url":"https://github.com/ethereum/eth2.0-specs/pull/374","diff_url":"https://github.com/ethereum/eth2.0-specs/pull/374.diff","patch_url":"https://github.com/ethereum/eth2.0-specs/pull/374.patch","issue_url":"https://api.github.com/repos/ethereum/eth2.0-specs/issues/374","number":374,"state":"open","locked":false,"title":"Status code / slot reorganization","user":{"login":"vbuterin","id":2230894,"node_id":"MDQ6VXNlcjIyMzA4OTQ=","avatar_url":"https://avatars1.githubusercontent.com/u/2230894?v=4","gravatar_id":"","url":"https://api.github.com/users/vbuterin","html_url":"https://github.com/vbuterin","followers_url":"https://api.github.com/users/vbuterin/followers","following_url":"https://api.github.com/users/vbuterin/following{/other_user}","gists_url":"https://api.github.com/users/vbuterin/gists{/gist_id}","starred_url":"https://api.github.com/users/vbuterin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vbuterin/subscriptions","organizations_url":"https://api.github.com/users/vbuterin/orgs","repos_url":"https://api.github.com/users/vbuterin/repos","events_url":"https://api.github.com/users/vbuterin/events{/privacy}","received_events_url":"https://api.github.com/users/vbuterin/received_events","type":"User","site_admin":false},"body":"Supersedes #350 and #354\r\n\r\n* Added `activation_slot`, `exit_slot`, `penalized_slot`, `withdrawal_slot`, use these to determine if a validator is active\r\n* Universal min activation/exit delay of 256 slots\r\n* Min exit time of ~1 day, but penalization delays this to ~18 days\r\n* 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\r\n* Processes withdrawals in all epochs, not just dynasty-changing epochs\r\n* Change `get_shuffling` function to take slot as argument\r\n\r\nNot yet done:\r\n\r\n* Removed `shard_committees` from the state\r\n* Removed persistent committees from the state","created_at":"2018-12-28T18:06:43Z","updated_at":"2018-12-31T02:44:37Z","closed_at":null,"merged_at":null,"merge_commit_sha":"92e85ab2992a8c02a518ca288e3d6bb1eef2e979","assignee":null,"assignees":[],"requested_reviewers":[{"login":"djrtwo","id":1433595,"node_id":"MDQ6VXNlcjE0MzM1OTU=","avatar_url":"https://avatars0.githubusercontent.com/u/1433595?v=4","gravatar_id":"","url":"https://api.github.com/users/djrtwo","html_url":"https://github.com/djrtwo","followers_url":"https://api.github.com/users/djrtwo/followers","following_url":"https://api.github.com/users/djrtwo/following{/other_user}","gists_url":"https://api.github.com/users/djrtwo/gists{/gist_id}","starred_url":"https://api.github.com/users/djrtwo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djrtwo/subscriptions","organizations_url":"https://api.github.com/users/djrtwo/orgs","repos_url":"https://api.github.com/users/djrtwo/repos","events_url":"https://api.github.com/users/djrtwo/events{/privacy}","received_events_url":"https://api.github.com/users/djrtwo/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls/374/commits","review_comments_url":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls/374/comments","review_comment_url":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ethereum/eth2.0-specs/issues/374/comments","statuses_url":"https://api.github.com/repos/ethereum/eth2.0-specs/statuses/011970169c5907d8016e0dea8726407f5b8c63c3","head":{"label":"ethereum:vbuterin-patch-19","ref":"vbuterin-patch-19","sha":"011970169c5907d8016e0dea8726407f5b8c63c3","user":{"login":"ethereum","id":6250754,"node_id":"MDEyOk9yZ2FuaXphdGlvbjYyNTA3NTQ=","avatar_url":"https://avatars3.githubusercontent.com/u/6250754?v=4","gravatar_id":"","url":"https://api.github.com/users/ethereum","html_url":"https://github.com/ethereum","followers_url":"https://api.github.com/users/ethereum/followers","following_url":"https://api.github.com/users/ethereum/following{/other_user}","gists_url":"https://api.github.com/users/ethereum/gists{/gist_id}","starred_url":"https://api.github.com/users/ethereum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ethereum/subscriptions","organizations_url":"https://api.github.com/users/ethereum/orgs","repos_url":"https://api.github.com/users/ethereum/repos","events_url":"https://api.github.com/users/ethereum/events{/privacy}","received_events_url":"https://api.github.com/users/ethereum/received_events","type":"Organization","site_admin":false},"repo":{"id":149554797,"node_id":"MDEwOlJlcG9zaXRvcnkxNDk1NTQ3OTc=","name":"eth2.0-specs","full_name":"ethereum/eth2.0-specs","private":false,"owner":{"login":"ethereum","id":6250754,"node_id":"MDEyOk9yZ2FuaXphdGlvbjYyNTA3NTQ=","avatar_url":"https://avatars3.githubusercontent.com/u/6250754?v=4","gravatar_id":"","url":"https://api.github.com/users/ethereum","html_url":"https://github.com/ethereum","followers_url":"https://api.github.com/users/ethereum/followers","following_url":"https://api.github.com/users/ethereum/following{/other_user}","gists_url":"https://api.github.com/users/ethereum/gists{/gist_id}","starred_url":"https://api.github.com/users/ethereum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ethereum/subscriptions","organizations_url":"https://api.github.com/users/ethereum/orgs","repos_url":"https://api.github.com/users/ethereum/repos","events_url":"https://api.github.com/users/ethereum/events{/privacy}","received_events_url":"https://api.github.com/users/ethereum/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/ethereum/eth2.0-specs","description":"Ethereum 2.0 Specifications","fork":false,"url":"https://api.github.com/repos/ethereum/eth2.0-specs","forks_url":"https://api.github.com/repos/ethereum/eth2.0-specs/forks","keys_url":"https://api.github.com/repos/ethereum/eth2.0-specs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ethereum/eth2.0-specs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ethereum/eth2.0-specs/teams","hooks_url":"https://api.github.com/repos/ethereum/eth2.0-specs/hooks","issue_events_url":"https://api.github.com/repos/ethereum/eth2.0-specs/issues/events{/number}","events_url":"https://api.github.com/repos/ethereum/eth2.0-specs/events","assignees_url":"https://api.github.com/repos/ethereum/eth2.0-specs/assignees{/user}","branches_url":"https://api.github.com/repos/ethereum/eth2.0-specs/branches{/branch}","tags_url":"https://api.github.com/repos/ethereum/eth2.0-specs/tags","blobs_url":"https://api.github.com/repos/ethereum/eth2.0-specs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ethereum/eth2.0-specs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ethereum/eth2.0-specs/git/refs{/sha}","trees_url":"https://api.github.com/repos/ethereum/eth2.0-specs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ethereum/eth2.0-specs/statuses/{sha}","languages_url":"https://api.github.com/repos/ethereum/eth2.0-specs/languages","stargazers_url":"https://api.github.com/repos/ethereum/eth2.0-specs/stargazers","contributors_url":"https://api.github.com/repos/ethereum/eth2.0-specs/contributors","subscribers_url":"https://api.github.com/repos/ethereum/eth2.0-specs/subscribers","subscription_url":"https://api.github.com/repos/ethereum/eth2.0-specs/subscription","commits_url":"https://api.github.com/repos/ethereum/eth2.0-specs/commits{/sha}","git_commits_url":"https://api.github.com/repos/ethereum/eth2.0-specs/git/commits{/sha}","comments_url":"https://api.github.com/repos/ethereum/eth2.0-specs/comments{/number}","issue_comment_url":"https://api.github.com/repos/ethereum/eth2.0-specs/issues/comments{/number}","contents_url":"https://api.github.com/repos/ethereum/eth2.0-specs/contents/{+path}","compare_url":"https://api.github.com/repos/ethereum/eth2.0-specs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ethereum/eth2.0-specs/merges","archive_url":"https://api.github.com/repos/ethereum/eth2.0-specs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ethereum/eth2.0-specs/downloads","issues_url":"https://api.github.com/repos/ethereum/eth2.0-specs/issues{/number}","pulls_url":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls{/number}","milestones_url":"https://api.github.com/repos/ethereum/eth2.0-specs/milestones{/number}","notifications_url":"https://api.github.com/repos/ethereum/eth2.0-specs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ethereum/eth2.0-specs/labels{/name}","releases_url":"https://api.github.com/repos/ethereum/eth2.0-specs/releases{/id}","deployments_url":"https://api.github.com/repos/ethereum/eth2.0-specs/deployments","created_at":"2018-09-20T05:12:54Z","updated_at":"2018-12-30T23:46:35Z","pushed_at":"2018-12-31T02:42:07Z","git_url":"git://github.com/ethereum/eth2.0-specs.git","ssh_url":"git@github.com:ethereum/eth2.0-specs.git","clone_url":"https://github.com/ethereum/eth2.0-specs.git","svn_url":"https://github.com/ethereum/eth2.0-specs","homepage":null,"size":1389,"stargazers_count":309,"watchers_count":309,"language":null,"has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":73,"mirror_url":null,"archived":false,"open_issues_count":43,"license":null,"forks":73,"open_issues":43,"watchers":309,"default_branch":"master"}},"base":{"label":"ethereum:master","ref":"master","sha":"6b84dae09e38808f95eb299c97f945be991535bb","user":{"login":"ethereum","id":6250754,"node_id":"MDEyOk9yZ2FuaXphdGlvbjYyNTA3NTQ=","avatar_url":"https://avatars3.githubusercontent.com/u/6250754?v=4","gravatar_id":"","url":"https://api.github.com/users/ethereum","html_url":"https://github.com/ethereum","followers_url":"https://api.github.com/users/ethereum/followers","following_url":"https://api.github.com/users/ethereum/following{/other_user}","gists_url":"https://api.github.com/users/ethereum/gists{/gist_id}","starred_url":"https://api.github.com/users/ethereum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ethereum/subscriptions","organizations_url":"https://api.github.com/users/ethereum/orgs","repos_url":"https://api.github.com/users/ethereum/repos","events_url":"https://api.github.com/users/ethereum/events{/privacy}","received_events_url":"https://api.github.com/users/ethereum/received_events","type":"Organization","site_admin":false},"repo":{"id":149554797,"node_id":"MDEwOlJlcG9zaXRvcnkxNDk1NTQ3OTc=","name":"eth2.0-specs","full_name":"ethereum/eth2.0-specs","private":false,"owner":{"login":"ethereum","id":6250754,"node_id":"MDEyOk9yZ2FuaXphdGlvbjYyNTA3NTQ=","avatar_url":"https://avatars3.githubusercontent.com/u/6250754?v=4","gravatar_id":"","url":"https://api.github.com/users/ethereum","html_url":"https://github.com/ethereum","followers_url":"https://api.github.com/users/ethereum/followers","following_url":"https://api.github.com/users/ethereum/following{/other_user}","gists_url":"https://api.github.com/users/ethereum/gists{/gist_id}","starred_url":"https://api.github.com/users/ethereum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ethereum/subscriptions","organizations_url":"https://api.github.com/users/ethereum/orgs","repos_url":"https://api.github.com/users/ethereum/repos","events_url":"https://api.github.com/users/ethereum/events{/privacy}","received_events_url":"https://api.github.com/users/ethereum/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/ethereum/eth2.0-specs","description":"Ethereum 2.0 Specifications","fork":false,"url":"https://api.github.com/repos/ethereum/eth2.0-specs","forks_url":"https://api.github.com/repos/ethereum/eth2.0-specs/forks","keys_url":"https://api.github.com/repos/ethereum/eth2.0-specs/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ethereum/eth2.0-specs/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ethereum/eth2.0-specs/teams","hooks_url":"https://api.github.com/repos/ethereum/eth2.0-specs/hooks","issue_events_url":"https://api.github.com/repos/ethereum/eth2.0-specs/issues/events{/number}","events_url":"https://api.github.com/repos/ethereum/eth2.0-specs/events","assignees_url":"https://api.github.com/repos/ethereum/eth2.0-specs/assignees{/user}","branches_url":"https://api.github.com/repos/ethereum/eth2.0-specs/branches{/branch}","tags_url":"https://api.github.com/repos/ethereum/eth2.0-specs/tags","blobs_url":"https://api.github.com/repos/ethereum/eth2.0-specs/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ethereum/eth2.0-specs/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ethereum/eth2.0-specs/git/refs{/sha}","trees_url":"https://api.github.com/repos/ethereum/eth2.0-specs/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ethereum/eth2.0-specs/statuses/{sha}","languages_url":"https://api.github.com/repos/ethereum/eth2.0-specs/languages","stargazers_url":"https://api.github.com/repos/ethereum/eth2.0-specs/stargazers","contributors_url":"https://api.github.com/repos/ethereum/eth2.0-specs/contributors","subscribers_url":"https://api.github.com/repos/ethereum/eth2.0-specs/subscribers","subscription_url":"https://api.github.com/repos/ethereum/eth2.0-specs/subscription","commits_url":"https://api.github.com/repos/ethereum/eth2.0-specs/commits{/sha}","git_commits_url":"https://api.github.com/repos/ethereum/eth2.0-specs/git/commits{/sha}","comments_url":"https://api.github.com/repos/ethereum/eth2.0-specs/comments{/number}","issue_comment_url":"https://api.github.com/repos/ethereum/eth2.0-specs/issues/comments{/number}","contents_url":"https://api.github.com/repos/ethereum/eth2.0-specs/contents/{+path}","compare_url":"https://api.github.com/repos/ethereum/eth2.0-specs/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ethereum/eth2.0-specs/merges","archive_url":"https://api.github.com/repos/ethereum/eth2.0-specs/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ethereum/eth2.0-specs/downloads","issues_url":"https://api.github.com/repos/ethereum/eth2.0-specs/issues{/number}","pulls_url":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls{/number}","milestones_url":"https://api.github.com/repos/ethereum/eth2.0-specs/milestones{/number}","notifications_url":"https://api.github.com/repos/ethereum/eth2.0-specs/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ethereum/eth2.0-specs/labels{/name}","releases_url":"https://api.github.com/repos/ethereum/eth2.0-specs/releases{/id}","deployments_url":"https://api.github.com/repos/ethereum/eth2.0-specs/deployments","created_at":"2018-09-20T05:12:54Z","updated_at":"2018-12-30T23:46:35Z","pushed_at":"2018-12-31T02:42:07Z","git_url":"git://github.com/ethereum/eth2.0-specs.git","ssh_url":"git@github.com:ethereum/eth2.0-specs.git","clone_url":"https://github.com/ethereum/eth2.0-specs.git","svn_url":"https://github.com/ethereum/eth2.0-specs","homepage":null,"size":1389,"stargazers_count":309,"watchers_count":309,"language":null,"has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":73,"mirror_url":null,"archived":false,"open_issues_count":43,"license":null,"forks":73,"open_issues":43,"watchers":309,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls/374"},"html":{"href":"https://github.com/ethereum/eth2.0-specs/pull/374"},"issue":{"href":"https://api.github.com/repos/ethereum/eth2.0-specs/issues/374"},"comments":{"href":"https://api.github.com/repos/ethereum/eth2.0-specs/issues/374/comments"},"review_comments":{"href":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls/374/comments"},"review_comment":{"href":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ethereum/eth2.0-specs/pulls/374/commits"},"statuses":{"href":"https://api.github.com/repos/ethereum/eth2.0-specs/statuses/011970169c5907d8016e0dea8726407f5b8c63c3"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"vbuterin"}}