Ethereum coinflip dapp discussion


I just copied and still see the same errors… Maybe it was in more than one file… I think I saw it on coinflip#4


trouble with missing files… may be rinkeby… see attached screenshot…

I get a 404 error when going to


Hello all,

Is it possible to publish a DApp from Superblocks to a Web Page?


In case you are still without I just sent you 10 eth to Rinkeby.


I have updated my github solutions now. Thank you for letting me know.


The contract in this case was not deployed. Therefore you have the missing files error. It didn’t deploy the contract because there was an error in compiling it. This seems like a change in the compiler that caused this. I have updated the code on github to resolve it.

You need to replace line 12 in the sol file to return address(this).balance;

Let me know if it works after that.


Thanks a lot! I was surprised when I saw them.


Seriously, Could you guys tell me how logical is that teaching smart contract on Superblocks website which is not used by anyone and there is no tutorial and nothing you can google about. I have been trying you publish the contract on a website. It has been a week and still couldn’t get a support. The problem is there is no source that I can look for. Because no one uses Superblocks.


hmmmm… interesting. Not sure what to think about this… we are in a very new field… do you know of other iDE’s for ethereum that have more documentation?


I’m sorry to hear that you are having issues. I don’t believe that there are any native way to publish dapps directly to a webpage using superblocks. I just sent an email to their CEO to ask about the best way to export the dapp.

The reason why we chose superblocks is because it’s the simplest way to get started building dapps imo. I’m not sure there is any other IDE out there to this day. Superblocks was the best choice I got my hands on while developing the course. If you have any suggestions for other IDEs or platforms that you think would be easier for the students here I would be glad to listen and maybe make some adjustments to the course.


I have gotten a reply from Superblocks.

If you have deployed your contract to a public network (rinkeby for example), you can click the checkbox “View source” in the Web view tab. You can simply copy all of the HTML and host it wherever you see fit.


I'm having a problem with running the app.

I can deploy the contract but it seems like my bet isn't getting placed. I submit through metamask but after the transaction is confirmed the dapp doesn't update or show a win/loss message. I'm using the most current github files.


From which repository? Part 5?

Do you see any errors in the console?


I had the same issue in Part 4 and I could fix it on line 48 in app.js
OLD instance.flip.sendTransaction({from: accounts[0], gas:100000, val}, function(error, txHash){
NEW instance.flip.sendTransaction({from: accounts[0], gas:100000, value: val}, function(error, txHash){

Filip, although trying to find an error could be usefull I think these errors can be easily be avoided by checking your github code.


OH GOD. I’m spended HOURS on this same problem. THANK YOU SIR.


Thank you for corrected the error. Really appreciate it. I have updated the github repos now. I continue to find errors and typos in my repos unfortunately and I try my best to look through them all.


I’m using the code from the most recent repository (UPDATED) and I’m having the same problem. Console is throwing an Uncaught ReferenceError at a bunch of web3 stuff. Any suggestions?


Fixed it! Apparently there’s a common problem with installing web3 on Windows 10.

Fixed by uninstalling/reinstalling Node and then using Powershell as admin to run:

npm install --global --production windows-build-tools

then installed web3 with

npm install --save web3@^0.20.0 


My Coinflip DApp seems to be working fine, but I get no “Won” or “Lost” message after submitting. The Transaction History shows the actual transaction was successful and I only see the result after I refresh the DApp and the Balance has changed. Anyone else experiencing this?


I am trying to deploy my contract to the rinkeby test net but continuously get the
“Uncaught Error: invalid address
at c (:1:20516)
at inputTransactionFormatter (:1:20998)
at :1:23523
at ()
at o.formatInput (:1:23496)
at o.toPayload (:1:23725)
at w.e [as sendTransaction] (:1:24031)
at /bundle.fae4e.js:1
at t.n._checkDeploy (/bundle.fae4e.js:1)
at /bundle.fae4e.js:1” error…

Any help is very appreciated. Thanks!