{"action":"created","issue":{"url":"https://api.github.com/repos/habanoz/tezos-reward-distributor/issues/7","repository_url":"https://api.github.com/repos/habanoz/tezos-reward-distributor","labels_url":"https://api.github.com/repos/habanoz/tezos-reward-distributor/issues/7/labels{/name}","comments_url":"https://api.github.com/repos/habanoz/tezos-reward-distributor/issues/7/comments","events_url":"https://api.github.com/repos/habanoz/tezos-reward-distributor/issues/7/events","html_url":"https://github.com/habanoz/tezos-reward-distributor/issues/7","id":386423509,"node_id":"MDU6SXNzdWUzODY0MjM1MDk=","number":7,"title":"FR: Remove dependency on tzscan","user":{"login":"utdrmac","id":4413670,"node_id":"MDQ6VXNlcjQ0MTM2NzA=","avatar_url":"https://avatars1.githubusercontent.com/u/4413670?v=4","gravatar_id":"","url":"https://api.github.com/users/utdrmac","html_url":"https://github.com/utdrmac","followers_url":"https://api.github.com/users/utdrmac/followers","following_url":"https://api.github.com/users/utdrmac/following{/other_user}","gists_url":"https://api.github.com/users/utdrmac/gists{/gist_id}","starred_url":"https://api.github.com/users/utdrmac/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/utdrmac/subscriptions","organizations_url":"https://api.github.com/users/utdrmac/orgs","repos_url":"https://api.github.com/users/utdrmac/repos","events_url":"https://api.github.com/users/utdrmac/events{/privacy}","received_events_url":"https://api.github.com/users/utdrmac/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2018-12-01T04:59:09Z","updated_at":"2018-12-02T22:05:29Z","closed_at":null,"author_association":"NONE","body":"**Describe the solution you'd like**\r\nAll functionality of this application is dependent on tzscan.io. If tzscan is down, or inaccurate, or delayed, this tool carries the same issues.\r\n\r\n**Describe alternatives you've considered**\r\nThis application should be using the local node's RPC-API to collect information.\r\n\r\n**Additional context**\r\nAs of this posting, alpha.tzscan.io is incompatible with the new 003 protocol and is not showing accurate data. Because this application is dependent on data from tzscan, no testing using this app can happen at this time on alphanet.\r\n"},"comment":{"url":"https://api.github.com/repos/habanoz/tezos-reward-distributor/issues/comments/443546588","html_url":"https://github.com/habanoz/tezos-reward-distributor/issues/7#issuecomment-443546588","issue_url":"https://api.github.com/repos/habanoz/tezos-reward-distributor/issues/7","id":443546588,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0MzU0NjU4OA==","user":{"login":"utdrmac","id":4413670,"node_id":"MDQ6VXNlcjQ0MTM2NzA=","avatar_url":"https://avatars1.githubusercontent.com/u/4413670?v=4","gravatar_id":"","url":"https://api.github.com/users/utdrmac","html_url":"https://github.com/utdrmac","followers_url":"https://api.github.com/users/utdrmac/followers","following_url":"https://api.github.com/users/utdrmac/following{/other_user}","gists_url":"https://api.github.com/users/utdrmac/gists{/gist_id}","starred_url":"https://api.github.com/users/utdrmac/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/utdrmac/subscriptions","organizations_url":"https://api.github.com/users/utdrmac/orgs","repos_url":"https://api.github.com/users/utdrmac/repos","events_url":"https://api.github.com/users/utdrmac/events{/privacy}","received_events_url":"https://api.github.com/users/utdrmac/received_events","type":"User","site_admin":false},"created_at":"2018-12-02T22:05:29Z","updated_at":"2018-12-02T22:05:29Z","author_association":"NONE","body":"So this gives me snapshots I can access:\r\n```\r\n$ ./tezos-client rpc get /chains/main/blocks/head/context/raw/json/rolls/owner/snapshot\r\n[ 7, 6, 5, 4, 3, 2, 1, 0 ]\r\n```\r\n\r\nThen I can query a specific (the current) cycle:\r\n```\r\n$ ./tezos-client rpc get /chains/main/blocks/head | jq -r '.metadata.level.cycle'\r\n2\r\n$ ./tezos-client rpc get /chains/main/blocks/head/context/raw/json/rolls/owner/snapshot/2/\r\n[ 0 ]\r\n```\r\n\r\nWhat does that 0 mean here?\r\nIf I look at mainnet, current cycle 51:\r\n```\r\nhttps://rpc.tezrpc.me/chains/main/blocks/head/context/raw/json/rolls/owner/snapshot/51/\r\n\"[1]\"\r\n```\r\n\r\nFetching that:\r\n```\r\n$ ./tezos-client rpc get /chains/main/blocks/head/context/raw/json/rolls/owner/snapshot/2/0/\r\n[ 2403, 2147, 1891, 1635, 1379, 1123, 867, 611, 2659, 355, 99, 2402, 2146,\r\n  1890, 1634, 1378, 1122, 866, 610, 2658, 354, 98, 2401, 2145, 1889, 1633,\r\n...\r\n```\r\n\r\nFetching one of these:\r\n```\r\n$ ./tezos-client rpc get /chains/main/blocks/head/context/raw/json/rolls/owner/snapshot/2/0/596/\r\n\"p2pk66EmFoQS6b2mYLvCrwjXs7XT1A2znX26HcT9YMiGsyCHyDvsLaF\"\r\n```\r\n\r\nAnd that is?"}}
{"actor":{"display_login":"utdrmac"}}