{"action":"created","issue":{"url":"https://api.github.com/repos/poanetwork/mana/issues/439","repository_url":"https://api.github.com/repos/poanetwork/mana","labels_url":"https://api.github.com/repos/poanetwork/mana/issues/439/labels{/name}","comments_url":"https://api.github.com/repos/poanetwork/mana/issues/439/comments","events_url":"https://api.github.com/repos/poanetwork/mana/issues/439/events","html_url":"https://github.com/poanetwork/mana/pull/439","id":362667804,"node_id":"MDExOlB1bGxSZXF1ZXN0MjE3MzIxNzQy","number":439,"title":"Do not overwrite account balances when creating contracts (#437)","user":{"login":"masonforest","id":229473,"node_id":"MDQ6VXNlcjIyOTQ3Mw==","avatar_url":"https://avatars0.githubusercontent.com/u/229473?v=4","gravatar_id":"","url":"https://api.github.com/users/masonforest","html_url":"https://github.com/masonforest","followers_url":"https://api.github.com/users/masonforest/followers","following_url":"https://api.github.com/users/masonforest/following{/other_user}","gists_url":"https://api.github.com/users/masonforest/gists{/gist_id}","starred_url":"https://api.github.com/users/masonforest/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/masonforest/subscriptions","organizations_url":"https://api.github.com/users/masonforest/orgs","repos_url":"https://api.github.com/users/masonforest/repos","events_url":"https://api.github.com/users/masonforest/events{/privacy}","received_events_url":"https://api.github.com/users/masonforest/received_events","type":"User","site_admin":false},"labels":[{"id":925629498,"node_id":"MDU6TGFiZWw5MjU2Mjk0OTg=","url":"https://api.github.com/repos/poanetwork/mana/labels/status:%20in%20progress","name":"status: in progress","color":"cccccc","default":false}],"state":"open","locked":false,"assignee":{"login":"masonforest","id":229473,"node_id":"MDQ6VXNlcjIyOTQ3Mw==","avatar_url":"https://avatars0.githubusercontent.com/u/229473?v=4","gravatar_id":"","url":"https://api.github.com/users/masonforest","html_url":"https://github.com/masonforest","followers_url":"https://api.github.com/users/masonforest/followers","following_url":"https://api.github.com/users/masonforest/following{/other_user}","gists_url":"https://api.github.com/users/masonforest/gists{/gist_id}","starred_url":"https://api.github.com/users/masonforest/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/masonforest/subscriptions","organizations_url":"https://api.github.com/users/masonforest/orgs","repos_url":"https://api.github.com/users/masonforest/repos","events_url":"https://api.github.com/users/masonforest/events{/privacy}","received_events_url":"https://api.github.com/users/masonforest/received_events","type":"User","site_admin":false},"assignees":[{"login":"masonforest","id":229473,"node_id":"MDQ6VXNlcjIyOTQ3Mw==","avatar_url":"https://avatars0.githubusercontent.com/u/229473?v=4","gravatar_id":"","url":"https://api.github.com/users/masonforest","html_url":"https://github.com/masonforest","followers_url":"https://api.github.com/users/masonforest/followers","following_url":"https://api.github.com/users/masonforest/following{/other_user}","gists_url":"https://api.github.com/users/masonforest/gists{/gist_id}","starred_url":"https://api.github.com/users/masonforest/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/masonforest/subscriptions","organizations_url":"https://api.github.com/users/masonforest/orgs","repos_url":"https://api.github.com/users/masonforest/repos","events_url":"https://api.github.com/users/masonforest/events{/privacy}","received_events_url":"https://api.github.com/users/masonforest/received_events","type":"User","site_admin":false}],"milestone":null,"comments":1,"created_at":"2018-09-21T15:30:22Z","updated_at":"2018-09-25T15:11:16Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/poanetwork/mana/pulls/439","html_url":"https://github.com/poanetwork/mana/pull/439","diff_url":"https://github.com/poanetwork/mana/pull/439.diff","patch_url":"https://github.com/poanetwork/mana/pull/439.patch"},"body":"Transaction [0x9aac76c9ed191da631b5e70c8824f2ad106a0f5147d57c611ed64653734dd85f](https://etherscan.io/tx/0x9aac76c9ed191da631b5e70c8824f2ad106a0f5147d57c611ed64653734dd85f) was failing consensus at [block 243826](https://etherscan.io/block/243826) because it was a `Contract Create` to an account that already had a\r\nbalance.\r\n\r\nBefore creating a contract we make sure that contract doesn't already\r\nexist. Before this commit we were using using `Account.exists?` for that\r\ncheck. `Account.exists?` checks the balance of an account as well as\r\nwhether it's contract code is set. This was incorrect. Instead now use\r\n`Account.is_simple_account?` which just checks if an account has it's\r\ncontract code set. This allows for a sneaky trick called hiding ether\r\ndescribed here as [Quirk #1 - hiding in plain sight](http://swende.se/blog/Ethereum_quirks_and_vulns.html)."},"comment":{"url":"https://api.github.com/repos/poanetwork/mana/issues/comments/424383700","html_url":"https://github.com/poanetwork/mana/pull/439#issuecomment-424383700","issue_url":"https://api.github.com/repos/poanetwork/mana/issues/439","id":424383700,"node_id":"MDEyOklzc3VlQ29tbWVudDQyNDM4MzcwMA==","user":{"login":"germsvel","id":3245976,"node_id":"MDQ6VXNlcjMyNDU5NzY=","avatar_url":"https://avatars0.githubusercontent.com/u/3245976?v=4","gravatar_id":"","url":"https://api.github.com/users/germsvel","html_url":"https://github.com/germsvel","followers_url":"https://api.github.com/users/germsvel/followers","following_url":"https://api.github.com/users/germsvel/following{/other_user}","gists_url":"https://api.github.com/users/germsvel/gists{/gist_id}","starred_url":"https://api.github.com/users/germsvel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/germsvel/subscriptions","organizations_url":"https://api.github.com/users/germsvel/orgs","repos_url":"https://api.github.com/users/germsvel/repos","events_url":"https://api.github.com/users/germsvel/events{/privacy}","received_events_url":"https://api.github.com/users/germsvel/received_events","type":"User","site_admin":false},"created_at":"2018-09-25T15:11:16Z","updated_at":"2018-09-25T15:11:16Z","author_association":"CONTRIBUTOR","body":"@masonforest I think this PR addresses https://github.com/poanetwork/mana/issues/437"}}
{"actor":{"display_login":"germsvel"}}