{"action":"created","comment":{"url":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls/comments/236281722","pull_request_review_id":178318186,"id":236281722,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzNjI4MTcyMg==","diff_hunk":"@@ -0,0 +1,30 @@\n+# Copyright (c) 2018 Status Research & Development GmbH\n+# Licensed and distributed under either of\n+#   * MIT license (license terms in the root directory or at http://opensource.org/licenses/MIT).\n+#   * Apache v2 license (license terms in the root directory or at http://www.apache.org/licenses/LICENSE-2.0).\n+# at your option. This file may not be copied, modified, or distributed except according to those terms.\n+\n+import\n+  math, nimcrypto, unittest, sequtils,\n+  ../beacon_chain/[datatypes, validator]\n+\n+func sumCommittees(v: openArray[seq[ShardAndCommittee]]): int =\n+  for x in v:\n+    for y in x:\n+      inc result, y.committee.len\n+\n+suite \"Validators\":\n+  ## For now just test that we can compile and execute block processing with mock data.\n+\n+  test \"Smoke validator shuffling\":\n+    let\n+      validators = repeat(\n+        ValidatorRecord(\n+          status: ACTIVE\n+        ), 1024)\n+\n+    # XXX the shuffling looks really odd, probably buggy","path":"tests/test_validator.nim","position":26,"original_position":26,"commit_id":"d1839dad9a77cb1b93f81879806d6b8b88a215f3","original_commit_id":"d1839dad9a77cb1b93f81879806d6b8b88a215f3","user":{"login":"mratsim","id":22738317,"node_id":"MDQ6VXNlcjIyNzM4MzE3","avatar_url":"https://avatars3.githubusercontent.com/u/22738317?v=4","gravatar_id":"","url":"https://api.github.com/users/mratsim","html_url":"https://github.com/mratsim","followers_url":"https://api.github.com/users/mratsim/followers","following_url":"https://api.github.com/users/mratsim/following{/other_user}","gists_url":"https://api.github.com/users/mratsim/gists{/gist_id}","starred_url":"https://api.github.com/users/mratsim/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mratsim/subscriptions","organizations_url":"https://api.github.com/users/mratsim/orgs","repos_url":"https://api.github.com/users/mratsim/repos","events_url":"https://api.github.com/users/mratsim/events{/privacy}","received_events_url":"https://api.github.com/users/mratsim/received_events","type":"User","site_admin":false},"body":"Repurposed https://github.com/status-im/nim-beacon-chain/issues/1#issuecomment-441662920 for shuffling test implementations using Sigp tests as reference - https://github.com/sigp/lighthouse/blob/ba548e49a52687a655c61b443b6835d79c6d4236/beacon_chain/validator_shuffling/src/shuffle.rs","created_at":"2018-11-26T14:45:55Z","updated_at":"2018-11-26T14:49:20Z","html_url":"https://github.com/status-im/nim-beacon-chain/pull/20#discussion_r236281722","pull_request_url":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls/20","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls/comments/236281722"},"html":{"href":"https://github.com/status-im/nim-beacon-chain/pull/20#discussion_r236281722"},"pull_request":{"href":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls/20"}}},"pull_request":{"url":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls/20","id":233271282,"node_id":"MDExOlB1bGxSZXF1ZXN0MjMzMjcxMjgy","html_url":"https://github.com/status-im/nim-beacon-chain/pull/20","diff_url":"https://github.com/status-im/nim-beacon-chain/pull/20.diff","patch_url":"https://github.com/status-im/nim-beacon-chain/pull/20.patch","issue_url":"https://api.github.com/repos/status-im/nim-beacon-chain/issues/20","number":20,"state":"open","locked":false,"title":"spec updates","user":{"login":"arnetheduck","id":1382986,"node_id":"MDQ6VXNlcjEzODI5ODY=","avatar_url":"https://avatars3.githubusercontent.com/u/1382986?v=4","gravatar_id":"","url":"https://api.github.com/users/arnetheduck","html_url":"https://github.com/arnetheduck","followers_url":"https://api.github.com/users/arnetheduck/followers","following_url":"https://api.github.com/users/arnetheduck/following{/other_user}","gists_url":"https://api.github.com/users/arnetheduck/gists{/gist_id}","starred_url":"https://api.github.com/users/arnetheduck/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/arnetheduck/subscriptions","organizations_url":"https://api.github.com/users/arnetheduck/orgs","repos_url":"https://api.github.com/users/arnetheduck/repos","events_url":"https://api.github.com/users/arnetheduck/events{/privacy}","received_events_url":"https://api.github.com/users/arnetheduck/received_events","type":"User","site_admin":false},"body":"random stuff encountered while reading spec","created_at":"2018-11-23T19:44:31Z","updated_at":"2018-11-26T14:49:19Z","closed_at":null,"merged_at":null,"merge_commit_sha":"398a81cc0348e1fcc800b49d5370797ce8fe6ad0","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls/20/commits","review_comments_url":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls/20/comments","review_comment_url":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls/comments{/number}","comments_url":"https://api.github.com/repos/status-im/nim-beacon-chain/issues/20/comments","statuses_url":"https://api.github.com/repos/status-im/nim-beacon-chain/statuses/d1839dad9a77cb1b93f81879806d6b8b88a215f3","head":{"label":"status-im:random-spec-updates","ref":"random-spec-updates","sha":"d1839dad9a77cb1b93f81879806d6b8b88a215f3","user":{"login":"status-im","id":11767950,"node_id":"MDEyOk9yZ2FuaXphdGlvbjExNzY3OTUw","avatar_url":"https://avatars1.githubusercontent.com/u/11767950?v=4","gravatar_id":"","url":"https://api.github.com/users/status-im","html_url":"https://github.com/status-im","followers_url":"https://api.github.com/users/status-im/followers","following_url":"https://api.github.com/users/status-im/following{/other_user}","gists_url":"https://api.github.com/users/status-im/gists{/gist_id}","starred_url":"https://api.github.com/users/status-im/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/status-im/subscriptions","organizations_url":"https://api.github.com/users/status-im/orgs","repos_url":"https://api.github.com/users/status-im/repos","events_url":"https://api.github.com/users/status-im/events{/privacy}","received_events_url":"https://api.github.com/users/status-im/received_events","type":"Organization","site_admin":false},"repo":{"id":141717232,"node_id":"MDEwOlJlcG9zaXRvcnkxNDE3MTcyMzI=","name":"nim-beacon-chain","full_name":"status-im/nim-beacon-chain","private":false,"owner":{"login":"status-im","id":11767950,"node_id":"MDEyOk9yZ2FuaXphdGlvbjExNzY3OTUw","avatar_url":"https://avatars1.githubusercontent.com/u/11767950?v=4","gravatar_id":"","url":"https://api.github.com/users/status-im","html_url":"https://github.com/status-im","followers_url":"https://api.github.com/users/status-im/followers","following_url":"https://api.github.com/users/status-im/following{/other_user}","gists_url":"https://api.github.com/users/status-im/gists{/gist_id}","starred_url":"https://api.github.com/users/status-im/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/status-im/subscriptions","organizations_url":"https://api.github.com/users/status-im/orgs","repos_url":"https://api.github.com/users/status-im/repos","events_url":"https://api.github.com/users/status-im/events{/privacy}","received_events_url":"https://api.github.com/users/status-im/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/status-im/nim-beacon-chain","description":"Implementation of Ethereum Sharded Casper v2.1 Beacon Chain","fork":false,"url":"https://api.github.com/repos/status-im/nim-beacon-chain","forks_url":"https://api.github.com/repos/status-im/nim-beacon-chain/forks","keys_url":"https://api.github.com/repos/status-im/nim-beacon-chain/keys{/key_id}","collaborators_url":"https://api.github.com/repos/status-im/nim-beacon-chain/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/status-im/nim-beacon-chain/teams","hooks_url":"https://api.github.com/repos/status-im/nim-beacon-chain/hooks","issue_events_url":"https://api.github.com/repos/status-im/nim-beacon-chain/issues/events{/number}","events_url":"https://api.github.com/repos/status-im/nim-beacon-chain/events","assignees_url":"https://api.github.com/repos/status-im/nim-beacon-chain/assignees{/user}","branches_url":"https://api.github.com/repos/status-im/nim-beacon-chain/branches{/branch}","tags_url":"https://api.github.com/repos/status-im/nim-beacon-chain/tags","blobs_url":"https://api.github.com/repos/status-im/nim-beacon-chain/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/status-im/nim-beacon-chain/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/status-im/nim-beacon-chain/git/refs{/sha}","trees_url":"https://api.github.com/repos/status-im/nim-beacon-chain/git/trees{/sha}","statuses_url":"https://api.github.com/repos/status-im/nim-beacon-chain/statuses/{sha}","languages_url":"https://api.github.com/repos/status-im/nim-beacon-chain/languages","stargazers_url":"https://api.github.com/repos/status-im/nim-beacon-chain/stargazers","contributors_url":"https://api.github.com/repos/status-im/nim-beacon-chain/contributors","subscribers_url":"https://api.github.com/repos/status-im/nim-beacon-chain/subscribers","subscription_url":"https://api.github.com/repos/status-im/nim-beacon-chain/subscription","commits_url":"https://api.github.com/repos/status-im/nim-beacon-chain/commits{/sha}","git_commits_url":"https://api.github.com/repos/status-im/nim-beacon-chain/git/commits{/sha}","comments_url":"https://api.github.com/repos/status-im/nim-beacon-chain/comments{/number}","issue_comment_url":"https://api.github.com/repos/status-im/nim-beacon-chain/issues/comments{/number}","contents_url":"https://api.github.com/repos/status-im/nim-beacon-chain/contents/{+path}","compare_url":"https://api.github.com/repos/status-im/nim-beacon-chain/compare/{base}...{head}","merges_url":"https://api.github.com/repos/status-im/nim-beacon-chain/merges","archive_url":"https://api.github.com/repos/status-im/nim-beacon-chain/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/status-im/nim-beacon-chain/downloads","issues_url":"https://api.github.com/repos/status-im/nim-beacon-chain/issues{/number}","pulls_url":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls{/number}","milestones_url":"https://api.github.com/repos/status-im/nim-beacon-chain/milestones{/number}","notifications_url":"https://api.github.com/repos/status-im/nim-beacon-chain/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/status-im/nim-beacon-chain/labels{/name}","releases_url":"https://api.github.com/repos/status-im/nim-beacon-chain/releases{/id}","deployments_url":"https://api.github.com/repos/status-im/nim-beacon-chain/deployments","created_at":"2018-07-20T13:45:21Z","updated_at":"2018-11-22T10:24:29Z","pushed_at":"2018-11-26T13:33:19Z","git_url":"git://github.com/status-im/nim-beacon-chain.git","ssh_url":"git@github.com:status-im/nim-beacon-chain.git","clone_url":"https://github.com/status-im/nim-beacon-chain.git","svn_url":"https://github.com/status-im/nim-beacon-chain","homepage":null,"size":149,"stargazers_count":11,"watchers_count":11,"language":"Nim","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":6,"license":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":6,"watchers":11,"default_branch":"master"}},"base":{"label":"status-im:master","ref":"master","sha":"9989f2fe560606383352e5063511b3f5791f6dbc","user":{"login":"status-im","id":11767950,"node_id":"MDEyOk9yZ2FuaXphdGlvbjExNzY3OTUw","avatar_url":"https://avatars1.githubusercontent.com/u/11767950?v=4","gravatar_id":"","url":"https://api.github.com/users/status-im","html_url":"https://github.com/status-im","followers_url":"https://api.github.com/users/status-im/followers","following_url":"https://api.github.com/users/status-im/following{/other_user}","gists_url":"https://api.github.com/users/status-im/gists{/gist_id}","starred_url":"https://api.github.com/users/status-im/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/status-im/subscriptions","organizations_url":"https://api.github.com/users/status-im/orgs","repos_url":"https://api.github.com/users/status-im/repos","events_url":"https://api.github.com/users/status-im/events{/privacy}","received_events_url":"https://api.github.com/users/status-im/received_events","type":"Organization","site_admin":false},"repo":{"id":141717232,"node_id":"MDEwOlJlcG9zaXRvcnkxNDE3MTcyMzI=","name":"nim-beacon-chain","full_name":"status-im/nim-beacon-chain","private":false,"owner":{"login":"status-im","id":11767950,"node_id":"MDEyOk9yZ2FuaXphdGlvbjExNzY3OTUw","avatar_url":"https://avatars1.githubusercontent.com/u/11767950?v=4","gravatar_id":"","url":"https://api.github.com/users/status-im","html_url":"https://github.com/status-im","followers_url":"https://api.github.com/users/status-im/followers","following_url":"https://api.github.com/users/status-im/following{/other_user}","gists_url":"https://api.github.com/users/status-im/gists{/gist_id}","starred_url":"https://api.github.com/users/status-im/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/status-im/subscriptions","organizations_url":"https://api.github.com/users/status-im/orgs","repos_url":"https://api.github.com/users/status-im/repos","events_url":"https://api.github.com/users/status-im/events{/privacy}","received_events_url":"https://api.github.com/users/status-im/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/status-im/nim-beacon-chain","description":"Implementation of Ethereum Sharded Casper v2.1 Beacon Chain","fork":false,"url":"https://api.github.com/repos/status-im/nim-beacon-chain","forks_url":"https://api.github.com/repos/status-im/nim-beacon-chain/forks","keys_url":"https://api.github.com/repos/status-im/nim-beacon-chain/keys{/key_id}","collaborators_url":"https://api.github.com/repos/status-im/nim-beacon-chain/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/status-im/nim-beacon-chain/teams","hooks_url":"https://api.github.com/repos/status-im/nim-beacon-chain/hooks","issue_events_url":"https://api.github.com/repos/status-im/nim-beacon-chain/issues/events{/number}","events_url":"https://api.github.com/repos/status-im/nim-beacon-chain/events","assignees_url":"https://api.github.com/repos/status-im/nim-beacon-chain/assignees{/user}","branches_url":"https://api.github.com/repos/status-im/nim-beacon-chain/branches{/branch}","tags_url":"https://api.github.com/repos/status-im/nim-beacon-chain/tags","blobs_url":"https://api.github.com/repos/status-im/nim-beacon-chain/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/status-im/nim-beacon-chain/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/status-im/nim-beacon-chain/git/refs{/sha}","trees_url":"https://api.github.com/repos/status-im/nim-beacon-chain/git/trees{/sha}","statuses_url":"https://api.github.com/repos/status-im/nim-beacon-chain/statuses/{sha}","languages_url":"https://api.github.com/repos/status-im/nim-beacon-chain/languages","stargazers_url":"https://api.github.com/repos/status-im/nim-beacon-chain/stargazers","contributors_url":"https://api.github.com/repos/status-im/nim-beacon-chain/contributors","subscribers_url":"https://api.github.com/repos/status-im/nim-beacon-chain/subscribers","subscription_url":"https://api.github.com/repos/status-im/nim-beacon-chain/subscription","commits_url":"https://api.github.com/repos/status-im/nim-beacon-chain/commits{/sha}","git_commits_url":"https://api.github.com/repos/status-im/nim-beacon-chain/git/commits{/sha}","comments_url":"https://api.github.com/repos/status-im/nim-beacon-chain/comments{/number}","issue_comment_url":"https://api.github.com/repos/status-im/nim-beacon-chain/issues/comments{/number}","contents_url":"https://api.github.com/repos/status-im/nim-beacon-chain/contents/{+path}","compare_url":"https://api.github.com/repos/status-im/nim-beacon-chain/compare/{base}...{head}","merges_url":"https://api.github.com/repos/status-im/nim-beacon-chain/merges","archive_url":"https://api.github.com/repos/status-im/nim-beacon-chain/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/status-im/nim-beacon-chain/downloads","issues_url":"https://api.github.com/repos/status-im/nim-beacon-chain/issues{/number}","pulls_url":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls{/number}","milestones_url":"https://api.github.com/repos/status-im/nim-beacon-chain/milestones{/number}","notifications_url":"https://api.github.com/repos/status-im/nim-beacon-chain/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/status-im/nim-beacon-chain/labels{/name}","releases_url":"https://api.github.com/repos/status-im/nim-beacon-chain/releases{/id}","deployments_url":"https://api.github.com/repos/status-im/nim-beacon-chain/deployments","created_at":"2018-07-20T13:45:21Z","updated_at":"2018-11-22T10:24:29Z","pushed_at":"2018-11-26T13:33:19Z","git_url":"git://github.com/status-im/nim-beacon-chain.git","ssh_url":"git@github.com:status-im/nim-beacon-chain.git","clone_url":"https://github.com/status-im/nim-beacon-chain.git","svn_url":"https://github.com/status-im/nim-beacon-chain","homepage":null,"size":149,"stargazers_count":11,"watchers_count":11,"language":"Nim","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":6,"license":{"key":"other","name":"Other","spdx_id":"NOASSERTION","url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":6,"watchers":11,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls/20"},"html":{"href":"https://github.com/status-im/nim-beacon-chain/pull/20"},"issue":{"href":"https://api.github.com/repos/status-im/nim-beacon-chain/issues/20"},"comments":{"href":"https://api.github.com/repos/status-im/nim-beacon-chain/issues/20/comments"},"review_comments":{"href":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls/20/comments"},"review_comment":{"href":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/status-im/nim-beacon-chain/pulls/20/commits"},"statuses":{"href":"https://api.github.com/repos/status-im/nim-beacon-chain/statuses/d1839dad9a77cb1b93f81879806d6b8b88a215f3"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"mratsim"}}