Coding Journey: An Idea turned Obsession

Forty Five Days ago my laptop had a boot sector loop error and I had just spent 30 days prior without a laptop. That night I found an old Toshiba running Kali Linux, it was a Pentium, but it would do. Spending 30 days on nothing but my phone and Twitter lead me to discover the #100DaysOfCode Challenge. In the past I had learned C++ and explored the ranks of the alt-coin craze. I wanted something new and challenging.

Ethereum was throwing out news and Bitcoin was pumping on Twitter and I had a humble Token (TRC10) on Tron, I did some research on Solidity gathered some resources, set my alarm to 6AM and that next morning I got to work. My first tutorial was on the Tron Blockchain and it was a token, but it left me with more questions than answers, as a beginner it was not good, but it did the job and I learned some new things. The next day I did some more research and found a Udemy Course on Ethereum and Solidity which would be the corner stone of my learning for the next 40 or so days.

Waking up an hour and a half early every day I dedicated time to learning Solidity and I tweeted my journey each day. It wasn’t until I finished the Udemy course that the obsession and need for a token of my own came back. Researching ERC20 and ERC777 standards brought me to OpenZeppelin, a person on Twitter shared “My Coding Journey: From Beginner to Pro” with me.

I had new resources now. I attempted to create an ERC900 Staking token and I felt like a noob doing it, something was wrong and I needed to go back to the beginning. I started the Ethernaut Hacking Series, the CryptoZombie tutorial, and work on my own token, to refresh my last 44 or so days. I’m excited to see where this forum will take me.

Beginning Days: https://www.udemy.com/course/ethereum-and-solidity-the-complete-developers-guide/ :
Github: https://github.com/n0rthbridge/:

Recap & Review on the Udemy Solidity Course:
My Udemy course started me off in Remix.Ethereum.Org and there I wrote my first true contract to store and call a message (Inbox.sol). I had no clue I would be learning Javascript but I was able to compile the contract locally. Next, I wrote the test file to test the functions of Inbox.sol. A MaxListeners error was thrown that wasn’t covered in the tutorial. I was proud of myself, I researched the error online and found a fix for it. I also learned how to interact with the functions of a contract. I ran into error between the tutorial web3 version and my downloaded version and changes in the language. I had to do some research and make some changes but I was able to deploy the contract by connecting through the Infuria API to the Rinnkeby network. Little did I know that I would need to learn ReactJS as well. The tutorial was thorough and came with an Appendix tutorial on React. I did not expect to be learning anything Front-End. React to me is a powerful library and it was exciting to start learning. This next week was spent learning React and creating a YouTube Search page. I learned about classes, constructors, this.state. I learned how to import files as well. It was a lot and I felt like I was thrown into the deep-end.

My next contract was a lottery contract. I learned about using pseudo-random in Solidity and was introduced to the manager of a contract as well as using require to restrict functions. Creating the Front End was fun for this contract. On this day I learned what an ABI is and I made use of React, a language that I had just started to learn. I learned more about async and methods. It was exiting to see how my code interacted with MetaMask. Seeing the Lottery contract run and work and understand how it operated on the Blockchain was a turning point for me in the tutorial.

The next project in the Udemy tutorial was a big one. It made use of Structs, Mapping, and restricted functions. It covered a lot and was to be the contract of a Kickstarter or Crowd Fund page. I followed the tutorial and wrote the tests. I spent what was about a week on the Front-End of this project. I wish I had better documentation and wrote more about my journey each day as I learned. I do have a daily log on twitter but I was restricted to the word count. I fought many errors and bugs as well. This project makes use of a contract factory to create campaigns for prospective projects. Each campaign can have contributors. Then the contract needs to be approved in order for it to be finalized and the funds be transferred to a designated address.

My Own Token:
Over the next few days I began work on my own Token on Ethereum this time, as apposed to Tron. I went from knowing absolutely nothing; writing and compiling blind code on Tron to being able to write a Token and follow what was going on in an ERC20 token to a greater degree than before.

Today Day46 or Day 1 on the Forum:


Today, I continued writing tests for my token. I successfully wrote many of them, however on the three key functions I get a BN error that I can’t seem to wrap my head around. I’ve tried Hex, number to string, and I’m just not sure how to finish these tests. The code runs on Remix and I’ve made use of the debugger to write most of these tests.

I am looking forward to documenting my journey here. I know I’m not at the level I want to be at yet. I can recall when I first learned C++ and took it to the next level, I was able to take a blank notepad page and craft code with no resources or help guides. I hope to know the fundamentals of Solidity that well in the comings days, weeks, and even months. For now, I need every bit of resources and help I can gather.

3 Likes

Last Night:
My obsession took hold and I couldn’t stop until I fixed my test.js file bugs and deploy the ERC20 token. I am proud to say that I found my error and corrected it. I found the error to be with the way I was calling the functions and passing values to it. It took several hours of hacking my own code and reading my past code from the Udemy tutorial to discover where I was wrong.

I deployed Shield Token to: 0x6bd1c40927A4B7915b4952D55f0c4a87AAEaEC56 on Rinkeby Testnetwork and sent a test transaction from one wallet to another.’

The Code I Corrected:

it('Approves a transaction', async () => {
		await ShieldToken.methods.approve(accounts[1], '10').send({
			from: accounts[0],
			to: accounts[1],
			gas: '1000000'
		});
	});

	it('Transfers from', async () => {

		try {
			await ShieldToken.methods.transferFrom(accounts[0], accounts[1], '10').send({
			from: accounts[0],
			gas: '1000000'
		});
			assert(false);
		} catch (err) {
			assert(err);
		}
		
	});

	it('Transfers', async () => {
		await ShieldToken.methods.transfer(
			acco20-04-05 10-03-51|690x373]

In addition, I also got trigger happy and drew up a ‘Mock-Up’ for a Blockchain Insurance Contract that makes use of staking, a token, and some wrapper concepts I’ve only heard of and think may be possible. My knowledge level is no where near ready to completely build the ‘Mock-Up’ but it’s nice to see I am thinking in solidity code enough to draw one up. The project is a decentralized way to insure Crypto-assets on Ethereum.

Day 2:


Today I completed the solidity portion of the CryptoZombies tutorial from Loom along with the web3 portion. I’m prepared to test and deploy the contract next. The ERC721 portion was a bit confusion and similar to writing an ERC20 token. While I could grasp the concepts of the game as a whole, when it comes to transfer logic I need to slow myself down and really think about the code and what it is doing. I’m going to take a break today and focus on some ‘infosec’ studies and possibly get back to solidity tonight with my next Ethernaut challenge.

2 Likes

Hi @Proteu5,

Thank you for sharing your journey. Absolutely :heart: it.

If you are not already, I suggest looking at inheriting from the OpenZeppelin Contracts implementation of ERC20: https://docs.openzeppelin.com/contracts/2.x/erc20#constructing-an-erc20-token-contract

I remember that pain of knowing exactly what I wanted to do (run a few unit tests) and getting stumped by syntax. It was days of going backwards and forwards. I think documentation, tooling and support have come a long way since then (those long ago days of 2017).

Feel free to post a question in the Community Forum too so that the community can help.

The Writing Automated Smart Contract Tests Learning guide could be very useful here. I recommend using OpenZeppelin Test Helpers especially for big numbers.
Another great resource is the OpenZeppelin Contracts tests themselves: https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/test/token/ERC20/ERC20.test.js

Congratulations on solving your testing issue and getting your token deployed to a public testnet: https://rinkeby.etherscan.io/address/0x6bd1c40927A4B7915b4952D55f0c4a87AAEaEC56

A useful step for your token is to verify your contract on Etherscan: Verifying a contract inheriting from OpenZeppelin Contracts

Look forward to following your journey.

It is my pleasure to be able to share, it keeps me focused and motivated.

I did have a look at the OpenZeppelin ERC20 implementation, I have not made use of it yet. I will make that the plan for tomorrow morning’s solidity block of my day.

I’m glad we have such great documentation. I will keep that in mind, I could always use a hand. Thank you for the great resources and being so helpful. I’ll have put them all to use for my coding journey. I had no idea about verifying a contract as well. Thank you for being so helpful. I look forward to sharing my progress tomorrow with the resources you have provided me.

For Day 3:
I wrote the tests for CryptoZombies from the Loom tutorial and ran them through Truffle Test. The code did have some versioning issues, I worked through most of them but got stuck on one big error I couldn’t crack today. But all in all I’m satisfied with how my learning is going.

2 Likes

Day 4
Yesterday, I ventured into the OpenZeppelin ERC20 tutorials and was able to deploy a Token. When I went through the pages I cam across a resource on CrowdSales and spent nearly an hour, if not more reading and planning my next project from Solidity to Front-End. I realized that do I have some gaps to fill in regards to React and JS but I’m looking forward to planning my next project. Can’t wait to see what I learn in today’s coding block of time.

1 Like

Great to follow your journey.

Please note Crowdsales are not included in OpenZeppelin Contracts 3.0. Where are Crowdsale contracts in OpenZeppelin Contracts 3.0?

I would have a look at how to lock up tokens for a period of time: https://docs.openzeppelin.com/contracts/2.x/api/token/erc20#TokenTimelock

It is worth having a play with OpenZeppelin Contracts v3.0 final release candidate and trying out the new features (and Solidity 0.6)

Thank you so much for the resources. I had to rethink my next project and begin my research into vested tokens, time-lock tokens.

Day 5 & 6


I know it’s not Solidity but I jumped into Solidity knowing minimal Javascript and ReactJs. With some advice, these past two days I’ve been filling in knowledge gaps in those areas so that when the time comes for a Front-End to my Dapp and Token I’ll be more ready.

I plotted out some resources for myself, after FreeCodeCamp - Javascript I have a ReactJs tutorial videos on YouTube to take. Next, I plan on implementing a time-lock token followed by several new Dapp tutorials that I will need to start on my Mock-up project. I also left a few lessons on CrypoZombies undone that I should complete today.

1 Like

JavaScript and React are my weakness.

If you find some good resources, would be great if you could share.

Right now I’m using Http://freecodecamp.com for Javascript it’s basic, but it is doing the job of giving me the basics I need that I skipped over. They are my weaknesses too.

Day 7


I compiled and deployed an ERC20 token and a TimeLock Contract. Inside of OpenZeppelin-Cli I was able to transfer the tokens to the contract and then have them unlock after 20min and transferred them to the beneficiary address! I do however run into issues running Mocha tests using (https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/test/token/ERC20/TokenTimelock.test.js). I came across an issue where I also needed to add a timeout to my package.json file >> “test”: “mocha --timeout 5000 --exit --recursive test”.

I did some digging into OpenZeppelin 3.0 and am looking into the changes and I can see why Crowdsales were dropped. This is causing me to rethink my project and for a good reason. Thank you. I hope to do more Solidity coding today, I am about 3 hours into it right now and want to explore the new features.

Thanks again for your help @abcoathup.

1 Like

Day 8, Day 9, Day 10
I got further in my Javascript challenge, 75% completed. I did this for two days. Covering switch cases and functions is making me think and work for each challenge.


I also built an Election dApp from a DappUniversity tutorial. The tutorial was thorough but I ran into issues with versioning that I had to fix. It’s never fun when I hit a bug wall but it is always exciting when I solve or find the resolution.

Today, I started my 2nd Udemy course on Soldity and Blockchain and I even made sure to choose one that made use of OpenZeppelin. I’ve also been reading about the changes in version 3.0 and even have been reading main Solidity 6.0 docs. I also chipped away at one of my last remaining courses on CryptoZombies by Loom.

I structured my goals are:

  • Build a foundation in Javascript & React for Front-End development
  • Continue following tutorials and building dApps for a steady learning curve
  • Complete this new 2020 Udemy course
  • Complete Ethernaut
  • Master OpenZeppelin 3.0 << The big challenge
    ++ I’m looking to bring an OpenZeppelin project to public deployment. I’m liking the idea of an ERC721 collectible even a complete Token as well. My ideas are flowing and I’m loving it.

Resources:
JS> Http://FreeCodeCamp.com
React> https://youtu.be/dGcsHMXbSOA
React> https://react-finder.netlify.com/courses
Election dApp> https://www.dappuniversity.com/articles/the-ultimate-ethereum-dapp-tutorial
CyrptoZombies> https://cryptozombies.io/en/course/

1 Like

Hi @Proteu5,

I have worked on two ERC721’s (see: What is your favorite collectible?)

It is definitely fun to do and with OpenZeppelin Contracts 3.0 ERC721 implementation is fairly straight forward.

1 Like

Day11 to Day16
I got lost for a few days in your replay. I found the world of NFTs; OpenSea, SuperRare, and KnownOrigin. I even used Mintable to quickly make an NFT of my own. I feel guilty I didn’t code it myself haha >> https://opensea.io/assets/0xa1096d7ffc8476923e3de66bf05841d87aa97e40/0

Thank you for opening the door to the Crypto Art world for me. It’s a wonderful direction to be in. I started an Instagram and got my artwork together @0rionArt. I’m going to be turning them into tokens. I’m just trying to figure out how to create an ERC20 and reward my art holders with a token.

Over the past six days I have been coding daily following a Udemy course. I’m going back over the basics to ensure I have a solid foundation

1 Like

Hi @Proteu5,

Congratulations on creating an NFT!!
Great art, did you create the artwork yourself?

Next step is to write the code yourself, though with ERC721PresetMinterPauserAutoId in OpenZeppelin Contracts 3 this should be straight forward on the smart contract side, just need to host the metadata somewhere.

Also worth thinking about what rights your artwork holders should have. I like having the right to print a physical copy whilst I own the NFT. See my experiment around this:

1 Like

Thanks for sharing that link, it was a great read and answered many questions I had.

As for my piece on OpenSea, I generated that from an AI Breeder website but I didn’t take the initial photograph that was used as the base before I did the photo breeding and added the Chaos elements. However, https://www.instagram.com/0rionart/ holds all of my original art that I plan to tokenize! Half of the art are my drawings and illustrations that I turned into digital art and the other half is my photography. This is what I spent the better part of last week doing haha.

Day 17


Last night I covered more about mappings in my udemy course and also dove into ERC721PresetMinterPauserAutoId in OpenZeppelin Contracts 3. This is going to be a fun journey. I found my progress slowing with Solidity as I go back to basics and yearn for more advanced topics. However, I am glad I did that as subjects such as mapping, memory and storage do give me trouble. It was a breath of fresh air looking into the ERC721Preset and the challenge it poses to me.

Thank you again @abcoathup and thanks for your tips and advice.

1 Like

What does an AI Breeder website do? Can you share a link?


I think the presets are awesome.

I have been playing with an ERC20 preset contract (https://docs.openzeppelin.com/contracts/3.x/api/presets#ERC20PresetMinterPauser) so the community can deploy without writing Solidity for prototyping and testing.

Create an ERC20 using OpenZeppelin CLI, without writing Solidity

Create an ERC20 using Truffle, without writing Solidity

I am thinking to do something similar for ERC721.

1 Like

This website has a wealth of AI and Art information and links: https://aiartists.org/ai-generated-art-tools

ArtBreeder, https://www.artbreeder.com/, was the website I used to create the image you are referring to.

Personally I like RunwayML and want to get into Blender3D and programming GANs after I master solidty a little better. I have to keep my focus.

That preset is awesome for ERC20s. It’s useful, I like writing my own code, even if I’m just typing what is already written over again so that I learn, but having a preset will help so much for testing.

Day18 & Day19


I compiled the OpenZeppelin ERC721 contract you mentioned in a previous post and created a Faux Token as a proof of concept. I also have been reading the notes on the docs and the source code to better learn what the token is doing. I also learned about TokenURI.

1 Like

Hi @Proteu5,

I need to have a play with some art on the weekend. Thanks for sharing the links. :pray:

I am a big fan of the automatic token URI to reduce minting costs.

Really pleased to see it included in an ERC721 preset:
https://docs.openzeppelin.com/contracts/3.x/api/presets#ERC721PresetMinterPauserAutoId

1 Like

I’m using art as my escape from coding burnout. It’s nice that I’ll be able to tie in my work with NFTs when the time comes.

Thanks for your resources, I love the ERC721 Preset.!
Day 20, 21, 22
20200429_181822|666x500
I spent day 20 and 21 taking my Udemy course covering structs and mapping. I also progressed my Javascript programming. In the interim I launched Http://Proteu5.art to showcase my works for NFT creation. The website was an HTML template I purchased from Http://themeforest.net to save time. I editing the code and added some custom Javascript for the photo gallerys. I also added a PHP email form.

I also attempted an outdated ERC721 tutorial using Solidity 0.4.X. I got stuck coding the test.js file due to version changes and breaking changes in mocha, chai, and such. It was a mess so I scratched the project and chose to go fully with the OpenZepplin preset the next day.

On Day 22 I compiled the ERC721MinterPreset and the supplied test.js file successfully. I love the OpenZeppelin tools and resources, it makes solidity much simpler and I’m always trying to complicate things when it comes to code.

Day 23 - 28 (I took 1 day of coding off)

I covered a lot of basics in the Udemy course I’ve been taking and learned more about Assertions, Exception Handeling, Mappings, Structure, Arrays. I also covered debugging, ABI code, gas and importing files. I finished a project by creating a Simple Allowance Wallet.


Yesterday I coded a Simple Auction Contract from a tutorial which turned out not to be simple. The tutorial is in solidity version 0.4.8. I want to port it over to 0.6.0 and use OpenZeppelin Cli with it. I ran into a plethora of issues with the developers Web3 integration. However it was great to learn how the solidity code looks for an auction. I definitely want to do something with this in the future with IPFS. I was able to recode some bugs that occurred due to changes in Web3 and Metamask and put in an IPFS section but I’m still erroring out on the deployment of the auction. (https://medium.com/@bryn.bellomy/solidity-tutorial-building-a-simple-auction-contract-fcc918b0878a)

This Morning I covered more on the Udemy Course regarding Web3.I Loaded Web3 into my browser and connected it to the Ganache Provider. I used Remix to compile my Auction smartcontract, injected the ABI and Contract Address and then interacted with the contract.

Sorry I waited 6 days to post, but I did miss coding for 1 day.

1 Like

Hi @Proteu5,

Everyone needs some time off, you sound like you are making good progress. Thanks for sharing as always.

1 Like