SIP-78: iSynth limit reset must not trip circuit breaker


Simple Summary

Ensure the repricing of an iSynth does not trigger the decentralized circuit breaker.


When the protocolDAO resets an iSynth, it must also update the pricing for the iSynth in the last exchange price tracker in the Exchanger contract.


SIP-65 introduced a decentralized circuit breaker which is tripped when a price on-chain is detected more than some given factor. When an iSynth is reset with a new entryPoint however, this changes the price quite significantly, and can trip the circuit breaker when there is a previous lastExchangeRate in Exchanger for that synth. This makes the synth unusable unless the factor is bumped up sufficiently to handle the iSynth repricing (or any iSynth repricing if many are performed simultaneously), and since the factor setting is system-wide, a much higher factor makes SIP-65 less useful overall.



When the protocolDAO resets an iSynth, the lastExchangeRate in Exchanger must be updated to the current iSynth rate with the latest entryPoint, to indicate a refreshed price for the synth.


The protocolDAO already has the power to invoke ExchangeRates.setInversePricing(). It's at this point that the Exchanger must be told to update any previous exchange rate with the one calculated at the time of repricing.

Technical Specification


Test Cases

  • Given iETH is an inverse synth tracking ETH
  • And there exists a previous exchange into or out of iETH, ensuring Exchanger.lastExchangeRate(iETH) has an entry
  • When the protocolDAO invokes setInversePricing, changing the rate more than the Exchanger.priceDeviationThresholdFactor
  • And a user exchanges into or out of iETH
  • Then the exchange completes successfully and iETH is not suspended due to a price spike

Configurable Values (Via SCCP)


Copyright and related rights waived via CC0.