News for hackers. Stuff that matters.
Re:Did I just lose half a million dollars? by masklinn on Sunday January 30, 2022 @04:57AM (#30135471)
From what I understood of afidrya explanation (in a sub-comment):

* there's a smart contract to which you can send ETH (directly), it sends WETH back

* however the inverse operation (WETH -> ETH) is not done by sending the WETH, you're supposed to call a special conversion function of the contract

I guess the smart contract only looks for ETH in its wallet (at its address), it ignores the WETH entirely, and thus the WETH become inaccessible.

So the contract is a deposit ATM where you can deposit cash and it spits out a bank check, but if you deposit a bank check it just shreds the check.

Or a currency conversion machine where you can shove USDs in the slot to get EURs, but if you shove EURs in, to the shredder they go,

Re:Did I just lose half a million dollars? by jaclaz on Sunday January 30, 2022 @05:46AM (#30135729)
>So the contract is a deposit ATM where you can deposit cash and it spits out a bank check, but if you deposit a bank check it just shreds the check.

>Or a currency conversion machine where you can shove USDs in the slot to get EURs, but if you shove EURs in, to the shredder they go,

Very good explanation, thanks, though the machine you describe would not probably be called a "smart" ATM.

Re:Did I just lose half a million dollars? by CydeWeys on Sunday January 30, 2022 @09:55AM (#30137703)
None of these explanations have ever covered what the hell WETH is, or the reason the person was trying to exchange it. Seems like there's still a lot of implicit assumptions in these explanations.
Re:Did I just lose half a million dollars? by runeks on Sunday January 30, 2022 @10:34AM (#30138011)
WETH is short for “wrapped Ether”. It’s a token issued on the Ethereum blockchain. This token conforms to the so-called ERC-20 standard, which is — essentially — the API of the token. Ether itself does not conform to the ERC-20 standard, which is why wrapping it is necessary to e.g. exchange it for other ERC-20 tokens via a smart contract designed for this purpose (confusingly called a “swap”).
Re:Did I just lose half a million dollars? by m3kw9 on Sunday January 30, 2022 @11:32AM (#30138548)
WETH is the ERC20(coins) version of ETH. It turns ETH into coins, so the contracts have an easier time interact with it
Re:Did I just lose half a million dollars? by tetha on Sunday January 30, 2022 @06:25AM (#30136035)
> Or a currency conversion machine where you can shove USDs in the slot to get EURs, but if you shove EURs in, to the shredder they go,

This example is kinda funny. If your bank notes were accidentally damaged in germany, you could send them to the federal bank and have them replaced as long as more than half of the bank note can be reconstructed. This is a service intended especially for victims of fire or flood catastrophes, though dog related accidents aren't unheard of either.

Re:Did I just lose half a million dollars? by masklinn on Sunday January 30, 2022 @11:17AM (#30138439)
AFAIK it's the same in the US (the US mint is in charge of both producing and destroying money), because treasuries want to keep track of the physical money supply.
Re:Did I just lose half a million dollars? by CRConrad on Tuesday February 01, 2022 @06:16PM (#30171066)
Returning to a browser tab I've had open for a while, I see you beat me to the "currency conversion ATM" analogy by two days.
Re:Did I just lose half a million dollars? by awb on Sunday January 30, 2022 @10:58AM (#30138248)
> but if you deposit a bank check it just shreds the check.

Why would you ever want to “shred the check”? Is this the intended functionality or a bug?

Re:Did I just lose half a million dollars? by masklinn on Sunday January 30, 2022 @11:16AM (#30138418)
> Why would you ever want to “shred the check”?

You don't, and it's not what technically happens, but it's the closest I could find as the actual behaviour can not be replicated in the real world.

The actual behaviour, at least in my understanding, is that the bank check goes in a box to which only the ATM has access, but the ATM was never coded to look for bank checks in the box, and it's not possible to update it, so it's not possible to get the bank checks out of the box.

In the real world you could take the box out and force it open, but in "the blockchain" the contract has sole control of the wallet, an updated version of the contract would be a different contract with a different address.

> Is this the intended functionality or a bug?

It is, in the broadest sense, a bug: the contract was not coded to handle anything other than ETH inputs, so it ignores everything else, but the other things were still moved into the box.