7 ms·
> At the same time, smart contracts have some deeply problematic constraints: > Smart contracts can’t be upgraded. Smart contracts are deployed once and run for
by jude- 5y ago
> At the same time, smart contracts have some deeply problematic constraints:
> Smart contracts can’t be upgraded. Smart contracts are deployed once and run forever; their code cannot be changed. The software development industry has literally zero experience with such a deployment model.
I stopped reading here. First, this is factually wrong -- the software industry has tons of experience dealing with software that can't be upgraded. Ever try to upgrade the firmware on a chip with no I/O facility for doing so? The answer is you don't; you instead focus on getting the code correct the first time, and possibly you build out a way to recall the product and replace it with a fixed version and price in the risk of needing to do so into the product itself. It can be done; it just takes discipline.
Second, if you don't understand why smart contracts being immutable is a necessary and desirable feature of the system, not a bug, then you're not going to understand much of web3. Like, think about it for five minutes -- if your smart contracts can be upgraded by default, and this code manages valuable digital assets, then their code can be replaced with code that steals those assets. Making this very, very, very hard is deliberate.
- davepeck 5y agoOriginal author here. I strongly disagree. While it’s certainly true that firmware on many devices can’t be or simply isn’t updated, it’s also the case that bugs ship. Because of this, engineers design and ship their more complex devices with the facility to upgrade firmware. Even my ages old stereo receiver is upgradable (although painfully so). But this is about smart contracts: code that in many cases moves money. I’d put that in the category of code that really could benefit from carefully controlled upgradability. I’m not the only one. For instance, the primary USDC contract on Ethereum is a proxy contract — it’s upgradable by design. I think that makes a lot of sense, and apparently so do the engineers managing those many billions of dollars: they’ve weighed the balance of “trust” in the abstract with “make sure it doesn’t break” in the real and made their decision. Beyond that, a guiding principle of some newer blockchains (like Tezos) is that code will need to evolve over time. Like many things Web3, it’s too soon to tell how things will shake out in the long run, and a variety of approaches seems desirable.
- sharemywin 5y agoI think that's what's interesting about "blockchains" versus on specific chain. 1. polygon is a cheap(as in transaction fees) knock off of Ethereum, competition good. bad from the perspective of capture value in the protocol. 2. as far as I can tell as long as one oracle doesn't become dominate that provides competition 3. Defi is enabling users value across other networks. uniswap, etc. 4. On a side note, not sure why there's not an api that encrypts an nft on ipfs and only returns the watermarked version unless you send it a fee. or your the owner.
- toolz 5y agobecause it's not a real problem. The same way you can buy a mona lisa t-shirt in the gift shop and that doesn't steal any of the value away from the owner. What you describe could be rather easily implemented, but why would anyone build or use that?
- sharemywin 5y agoI guess was thinking like a CDN/istockphoto type marketplace.
- serverholic 5y agoSo you deploy a new contract and tell users why they should update. Then they can choose to use the new version or not. I don't think you really understand this idea.
- davepeck 5y agoWhat you’re describing does indeed happen — and in many cases I think it’s a good approach — but it’s not the same as what I’m talking about. You might find these two blog posts useful: 1. OpenZeppelin’s post on the Ethereum proxy pattern: https://blog.openzeppelin.com/proxy-patterns/ https://blog.openzeppelin.com/proxy-patterns/ 2. USDC’s adventure in upgrading their contract: https://blog.coinbase.com/usdc-v2-upgrading-a-multi-billion-dollar-erc-20-token-b57cd9437096 https://blog.coinbase.com/usdc-v2-upgrading-a-multi-billion-...
- rodiger 5y agoIt's not very, very hard currently though. It's just slightly more complex and more error prone. Most complex DeFi protocols are upgradeable by design these days.
- jt2190 5y ago> ...instead focus on getting the code correct the first time This is a threshold that real-world contracts don't typically have to achieve. They leave lots of details out, or vaguely defined, because the odds are low that that part of the contract will have to come into play, and it's not worth the extraordinary effort and time and expense to negotiate every tiny very-unlikely-to-happen case. To quote Lawrence Lessig [1]: "Often obscurity is a real value. Obscurity is what you want... In principle we should be negotiating all of these [possible things that could happen to our deal]... What contracts do all the time [instead] is they create these fuzzy or vague or ambiguous places as a gamble... And if it turns out [that this .002% occurrence does] happen, we'll ask... a judge to figure them out. Also, if you're just going to replace one immutable contract with another, you're back to meatspace and re-negotiation, which can be time consuming and expensive. [1] MIT 15.S12 Blockchain and Money, Fall 2018. "Smart Contracts and DApps" https://youtu.be/JPkgJwJHYSc?t=3543 https://youtu.be/JPkgJwJHYSc?t=3543
- jude- 5y ago> This is a threshold that real-world contracts don't typically have to achieve And boy does it show! How do you debug your smart contract? Your users tell you their money got stolen out of it. I wish that was a joke. > Also, if you're just going to replace one immutable contract with another, you're back to meatspace and re-negotiation, which can be time consuming and expensive. Is upgrading them in place somehow better? At least by keeping the old systems around, the people who still get mileage out of them aren't sold up-river.
- jimmySixDOF 5y agoI think here you need to draw the comparison to an Irrevocable Letter of Credit (LOC) and those are intentionally set in stone.
- abeaclark 5y agoIsn’t the proxy setup on ethereum a loophole in this tho? You just deploy a new contract and redirect the proxy
- deleted 5y ago[deleted]