Smart-contracts: Ethereum vs. Obyte

Stankevicius MGM
Jun 18, 2019 · 3 min read
Image for post
Image for post

Smart-contracts have become synonymous with Solidity scripts on Ethereum and they can be used to create many things: multi-signature wallets, fungible and non-fungible tokens, payments with the escrow and so on. In most cases, you don’t need to decentralize all user interactions, so smart-contracts should do as less as possible. Some people have found out about that the hard way when their smart-contracts cannot be executed anymore because of block gas limit and unbounded loops.

There are endless ways how the same functionality can be written differently in Solidity, which means that these smart-contracts are usually not readable for regular users (even after the source code has been verified) and each implementation of the same functionality can have different bugs because a developer might have forgotten to restrict access to something that should have been limited by default (Parity hack). It’s good to see standardization of basic functionalities (ERC20, ERC721, SafeMath) on Solidity code, but it’s usually too late if your broken code is already up there and you didn’t think about how to replace the broken parts of you smart-contract. Also, ERC20 only defines required functions for the token, but every developer can still write their own implementation — so not all ERC20 tokens are the same. The possibility to implement functions to replace some parts of your smart-contract could also mean that the same ERC20 standard token can tomorrow have different spending rules or even paused by the developer.

Image for post
Image for post

Smart-contracts on Obyte are readable for developers and users.

Features built-into Obyte platform

Fortunately, this is not the only way to have smart-contracts. Obyte is an open cryptocurrency platform built using DAG (directed acyclic graph) and it has human readable smart-contracts, which have a set of conditions that need to be true to transfer funds out of them. Obyte platform also has multi-signature wallets, user-created tokens, payments with the escrow and many other usual smart-contract use cases already built-into the platform. It is still possible for a developer to miss some conditions in smart-contracts that can leave bugs in those deployed smart-contracts, but it’s more difficult to make other mistakes because the smart-contract language is declarative on Obyte.

Cost predictability

On Ethereum, in most cases, the developer would have to pay only for deploying the smart-contract, users pay will pay for all other interactions. In reality, the business is also another counterpart for the users and needs to execute some functions too. Since every operation in Ethereum smart-contract costs gas, if a developer added a function that needs to go through the growing list of user addresses, the cost of executing that function will also go up as the list gets longer. Ethereum throughput is limited with block size the same way like Bitcoin, so when there are more users, the fees go up too.

On Obyte, every payment and every data posted by oracles costs as much as it takes space in public database, which means that the fees are predictable for the developers and businesses can estimate how many Obyte Bytes (native coin) they need to acquire for the next year or more. This is possible because DAG architecture doesn’t have block size limit and no block time limit.

Last, but not least, Solidity is a Javascript-like language, but it’s not Javascript, which means it has a steeper learning curve than other existing languages. This means more costs for developing and more bugs. Obyte is written on well-known NodeJS and Obyte smart-contracts are just nested conditions in JSON code.

HackerNoon.com

#BlackLivesMatter

Sign up for Get Better Tech Emails via HackerNoon.com

By HackerNoon.com

how hackers start their afternoons. the real shit is on hackernoon.com. Take a look

By signing up, you will create a Medium account if you don’t already have one. Review our Privacy Policy for more information about our privacy practices.

Check your inbox
Medium sent you an email at to complete your subscription.

Thanks to hackerhodl

Stankevicius MGM

Written by

Stankevicius MGM - Masters in Global Media. Professional PR and advertising firm helping clients to maximize branding efforts through media. 环球媒体专家.

HackerNoon.com

Elijah McClain, George Floyd, Eric Garner, Breonna Taylor, Ahmaud Arbery, Michael Brown, Oscar Grant, Atatiana Jefferson, Tamir Rice, Bettie Jones, Botham Jean

Stankevicius MGM

Written by

Stankevicius MGM - Masters in Global Media. Professional PR and advertising firm helping clients to maximize branding efforts through media. 环球媒体专家.

HackerNoon.com

Elijah McClain, George Floyd, Eric Garner, Breonna Taylor, Ahmaud Arbery, Michael Brown, Oscar Grant, Atatiana Jefferson, Tamir Rice, Bettie Jones, Botham Jean

Medium is an open platform where 170 million readers come to find insightful and dynamic thinking. Here, expert and undiscovered voices alike dive into the heart of any topic and bring new ideas to the surface. Learn more

Follow the writers, publications, and topics that matter to you, and you’ll see them on your homepage and in your inbox. Explore

If you have a story to tell, knowledge to share, or a perspective to offer — welcome home. It’s easy and free to post your thinking on any topic. Write on Medium

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store