{"action":"created","issue":{"url":"https://api.github.com/repos/mimblewimble/grin/issues/702","repository_url":"https://api.github.com/repos/mimblewimble/grin","labels_url":"https://api.github.com/repos/mimblewimble/grin/issues/702/labels{/name}","comments_url":"https://api.github.com/repos/mimblewimble/grin/issues/702/comments","events_url":"https://api.github.com/repos/mimblewimble/grin/issues/702/events","html_url":"https://github.com/mimblewimble/grin/pull/702","id":296455424,"number":702,"title":"[WIP] Take the 'Sum' out of 'Sumtree'","user":{"login":"yeastplume","id":7074070,"avatar_url":"https://avatars3.githubusercontent.com/u/7074070?v=4","gravatar_id":"","url":"https://api.github.com/users/yeastplume","html_url":"https://github.com/yeastplume","followers_url":"https://api.github.com/users/yeastplume/followers","following_url":"https://api.github.com/users/yeastplume/following{/other_user}","gists_url":"https://api.github.com/users/yeastplume/gists{/gist_id}","starred_url":"https://api.github.com/users/yeastplume/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yeastplume/subscriptions","organizations_url":"https://api.github.com/users/yeastplume/orgs","repos_url":"https://api.github.com/users/yeastplume/repos","events_url":"https://api.github.com/users/yeastplume/events{/privacy}","received_events_url":"https://api.github.com/users/yeastplume/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"yeastplume","id":7074070,"avatar_url":"https://avatars3.githubusercontent.com/u/7074070?v=4","gravatar_id":"","url":"https://api.github.com/users/yeastplume","html_url":"https://github.com/yeastplume","followers_url":"https://api.github.com/users/yeastplume/followers","following_url":"https://api.github.com/users/yeastplume/following{/other_user}","gists_url":"https://api.github.com/users/yeastplume/gists{/gist_id}","starred_url":"https://api.github.com/users/yeastplume/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yeastplume/subscriptions","organizations_url":"https://api.github.com/users/yeastplume/orgs","repos_url":"https://api.github.com/users/yeastplume/repos","events_url":"https://api.github.com/users/yeastplume/events{/privacy}","received_events_url":"https://api.github.com/users/yeastplume/received_events","type":"User","site_admin":false},"assignees":[{"login":"yeastplume","id":7074070,"avatar_url":"https://avatars3.githubusercontent.com/u/7074070?v=4","gravatar_id":"","url":"https://api.github.com/users/yeastplume","html_url":"https://github.com/yeastplume","followers_url":"https://api.github.com/users/yeastplume/followers","following_url":"https://api.github.com/users/yeastplume/following{/other_user}","gists_url":"https://api.github.com/users/yeastplume/gists{/gist_id}","starred_url":"https://api.github.com/users/yeastplume/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yeastplume/subscriptions","organizations_url":"https://api.github.com/users/yeastplume/orgs","repos_url":"https://api.github.com/users/yeastplume/repos","events_url":"https://api.github.com/users/yeastplume/events{/privacy}","received_events_url":"https://api.github.com/users/yeastplume/received_events","type":"User","site_admin":false}],"milestone":null,"comments":2,"created_at":"2018-02-12T17:12:49Z","updated_at":"2018-02-16T16:38:28Z","closed_at":null,"author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/mimblewimble/grin/pulls/702","html_url":"https://github.com/mimblewimble/grin/pull/702","diff_url":"https://github.com/mimblewimble/grin/pull/702.diff","patch_url":"https://github.com/mimblewimble/grin/pull/702.patch"},"body":"Took on https://github.com/mimblewimble/grin/issues/695 to get a tour of the current state of the core, @ignopeverell can you just have a quick look over core/core/pmmr.rs as is and make sure this amount of chop isn't too much? (i.e. I've removed a level of abstraction you might want to keep) This version is just working on a plain and simple core::Hash with the backend just working on a Writeable."},"comment":{"url":"https://api.github.com/repos/mimblewimble/grin/issues/comments/366287997","html_url":"https://github.com/mimblewimble/grin/pull/702#issuecomment-366287997","issue_url":"https://api.github.com/repos/mimblewimble/grin/issues/702","id":366287997,"user":{"login":"yeastplume","id":7074070,"avatar_url":"https://avatars3.githubusercontent.com/u/7074070?v=4","gravatar_id":"","url":"https://api.github.com/users/yeastplume","html_url":"https://github.com/yeastplume","followers_url":"https://api.github.com/users/yeastplume/followers","following_url":"https://api.github.com/users/yeastplume/following{/other_user}","gists_url":"https://api.github.com/users/yeastplume/gists{/gist_id}","starred_url":"https://api.github.com/users/yeastplume/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yeastplume/subscriptions","organizations_url":"https://api.github.com/users/yeastplume/orgs","repos_url":"https://api.github.com/users/yeastplume/repos","events_url":"https://api.github.com/users/yeastplume/events{/privacy}","received_events_url":"https://api.github.com/users/yeastplume/received_events","type":"User","site_admin":false},"created_at":"2018-02-16T16:38:28Z","updated_at":"2018-02-16T16:38:28Z","author_association":"MEMBER","body":"@ignopeverell Okay, not complete, but I think this is ready for a bit of review and a couple of pointers if you wouldn't mind indulging (sorry). This has been a good education so far but I think I'm still missing something conceptually.\r\n\r\nTravis issues aside, the unit tests all pass which means appending and rewinding seem to be working properly. However, the flat files themselves aren't being pruned in any way (even though the flatfile implementation supports it), and I think I need to educate myself a bit more on what happens when a PMMR gets pruned. I'm kind of working on the assumption that when a leaf goes into the tree at h=0, it's 'leaf index', i.e. just assuming a flat index from 1..n counting the nodes at the bottom of the tree (outputs), never changes.. but I think I'm missing something here.\r\n\r\nSo from what I gather now, what needs to happen is:\r\n* Pruning spent outputs from the flat-files and ensuring their index in the file always matches the entries along the bottom row of the PMMR (which I understand how to do in the append and rewind case, but what happens if/when the leaves are re-orged)\r\n* A bit rename-athon to remove the word 'sumtree' from all over the place (and in the comments) and perhaps replace with 'hashtree' where it's publicly visible and 'pmmrtree' when referring to the implementation\r\n\r\n"}}
{"actor":{"display_login":"yeastplume"}}