{"action":"created","issue":{"url":"https://api.github.com/repos/ConsenSys/ether-pudding/issues/5","labels_url":"https://api.github.com/repos/ConsenSys/ether-pudding/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/ConsenSys/ether-pudding/issues/5/comments","events_url":"https://api.github.com/repos/ConsenSys/ether-pudding/issues/5/events","html_url":"https://github.com/ConsenSys/ether-pudding/issues/5","id":100397171,"number":5,"title":"Endless RPC Call loop on return","user":{"login":"mhhf","id":446478,"avatar_url":"https://avatars.githubusercontent.com/u/446478?v=3","gravatar_id":"","url":"https://api.github.com/users/mhhf","html_url":"https://github.com/mhhf","followers_url":"https://api.github.com/users/mhhf/followers","following_url":"https://api.github.com/users/mhhf/following{/other_user}","gists_url":"https://api.github.com/users/mhhf/gists{/gist_id}","starred_url":"https://api.github.com/users/mhhf/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mhhf/subscriptions","organizations_url":"https://api.github.com/users/mhhf/orgs","repos_url":"https://api.github.com/users/mhhf/repos","events_url":"https://api.github.com/users/mhhf/events{/privacy}","received_events_url":"https://api.github.com/users/mhhf/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-08-11T20:05:51Z","updated_at":"2015-08-11T20:17:32Z","closed_at":null,"body":"Setup:\r\nweb3: 0.12.0\r\npudding: 0.10.0\r\ntestrpc: 0.1.14\r\n\r\nI've got a problem with the following contract:\r\n\r\n```\r\ncontract Store {\r\n  uint value;\r\n  \r\n  function Store(){\r\n    value = 9;\r\n  }\r\n  \r\n  function query() constant returns (uint val) {\r\n    return value;\r\n  }\r\n}\r\n```\r\n\r\nand the following JS Code:\r\n```\r\nStore\r\n  .new({ from: web3.eth.conbase, data: Store.binary })\r\n  .then( function( instance ){\r\n    return instance.query();\r\n  }).then(function( v ){\r\n    console.log( v );\r\n  });\r\n```\r\n\r\nThe strange thing is: as log as the value in Store is set to 0-9, Pudding shows the behavior described here: https://github.com/ConsenSys/ether-pudding/issues/4\r\nIf the value is set to 10 and above. Pudding works fine.\r\nThis is probably caused here: https://github.com/ConsenSys/ether-pudding/blob/master/build/ether-pudding.js#L244 as the response( tx ) is an BigNumber Object and not a transaction hash. But I have still to figure out why this works with value=10"},"comment":{"url":"https://api.github.com/repos/ConsenSys/ether-pudding/issues/comments/130051705","html_url":"https://github.com/ConsenSys/ether-pudding/issues/5#issuecomment-130051705","issue_url":"https://api.github.com/repos/ConsenSys/ether-pudding/issues/5","id":130051705,"user":{"login":"tcoulter","id":92629,"avatar_url":"https://avatars.githubusercontent.com/u/92629?v=3","gravatar_id":"","url":"https://api.github.com/users/tcoulter","html_url":"https://github.com/tcoulter","followers_url":"https://api.github.com/users/tcoulter/followers","following_url":"https://api.github.com/users/tcoulter/following{/other_user}","gists_url":"https://api.github.com/users/tcoulter/gists{/gist_id}","starred_url":"https://api.github.com/users/tcoulter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tcoulter/subscriptions","organizations_url":"https://api.github.com/users/tcoulter/orgs","repos_url":"https://api.github.com/users/tcoulter/repos","events_url":"https://api.github.com/users/tcoulter/events{/privacy}","received_events_url":"https://api.github.com/users/tcoulter/received_events","type":"User","site_admin":false},"created_at":"2015-08-11T20:17:32Z","updated_at":"2015-08-11T20:17:32Z","body":"Hi Denis, try this: \r\n\r\nInstead of passing your binary in the `new` function, put it in `Pudding.whisk()`, i.e.,:\r\n\r\n```\r\nStore = Pudding.whisk(abi, binary);\r\n```\r\n\r\nHowever, since you seem to already have the binary (`Store.binary`), I believe that to have already been done for you. So, your new call should now look like this:\r\n\r\n```\r\nStore.new({from: address}).then(function(instance) {});\r\n```\r\n\r\nI'm not sure why specific numbers worked for you and others didn't, but if you still have the problem after the above changes I'll take another look."}}