Remove Internal Tolerant Mode

Remove Internal Tolerant Mode

Notes

  • INTERNAL_TOLERANT mode was created to handle cases where the output of a function is not known before the execution of a transaction.
    • For example, Swap + Deposit where output of the Swap is not known until execution due to slippage.
  • This mode allowed the developer to use the remaining Internal (Farm) balance without having to underestimate the output amount.
  • This brings up security issues with regard to leakage of funds (if implemented improperly Beanstalk funds could be drained).
  • In BIP-30, AdvancedFarm was added—can be used as an alternative to INTERNAL_TOLERANT.
  • Once the Beanstalk UI and SDK remove their depedency on INTERNAL_TOLERANT, the goal is to remove it as soon as possible.
  • Root UI already used AdvancedFarm based swaps.
  • This change can be added to any BIP that is being proposed around the time that this is ready to change.