manifoldfinance / mevETH2

mevETH LST Protocol - Repo has migrated see link
https://github.com/MEV-Protocol/meveth
27 stars 2 forks source link

Deposit minimum consensus #50

Closed sandybradley closed 1 year ago

sandybradley commented 1 year ago

Problem

MevEth deposit minimum is currently hard coded as 1,000 wei. This should be parametrized and agreed upon. 0xBeans contract had the deposit minimum as 1,000,000,000,000,000,000 wei by comparison. https://github.com/manifoldfinance/mevETH/blob/1d28743e81f192fd31340ec8cc724c529847bfad/src/MevEth.sol#L287

Solution

Agree upon a value and implement with: DEPOSIT_MINIMUM constant / immutable / global set in MevEth. e.g.

// deposit minimum set at 0.001 eth (1,000,000,000,000,000 wei)
unit256 public constant DEPOSIT_MINIMUM = 1_000_000_000_000_000;
ControlCplusControlV commented 1 year ago

We discussed this at the call last week, we settled on a minimum deposit amount of 0.01 eth, or 10 finney (I think?)

sambacha commented 1 year ago

We discussed this at the call last week, we settled on a minimum deposit amount of 0.01 eth, or 10 finney (I think?)

to be sure ETH (wei, fei, etc) isn't a type, so the semantics:

cause it to inherit the smallest type.

e.g. a type of uint16 with max value 65535, 0.001 ether has no explicit type, the compiler will implicitly give it the smallest datatype it accepts i.e uint56 with a max value of 72057594037927935.