-
Notifications
You must be signed in to change notification settings - Fork 338
Update add-gas-currency.md #1970
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for celo-docs ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
### Reporting | ||
#### Creating an equivalent Oracle | ||
|
||
SortedOracles supports flagging two tokens as "equivalent". This is example do that no new oracle has to be deployed and useful for fiat-backed stablecoins. [Here is an exampl](https://github.com/celo-org/governance/pull/419/files#diff-ba5ba5397b269ceb4b93f3876bedabac605daeec083a364a270675242fe7c424)e of this approach. Using this approach, it is not needed to submit to proposals and can be done in only one. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do
--> so
exampl
--> example
### Reporting | ||
#### Creating an equivalent Oracle | ||
|
||
SortedOracles supports flagging two tokens as "equivalent". This is example do that no new oracle has to be deployed and useful for fiat-backed stablecoins. [Here is an exampl](https://github.com/celo-org/governance/pull/419/files#diff-ba5ba5397b269ceb4b93f3876bedabac605daeec083a364a270675242fe7c424)e of this approach. Using this approach, it is not needed to submit to proposals and can be done in only one. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SortedOracles supports flagging two tokens as "equivalent". This is example do that no new oracle has to be deployed and useful for fiat-backed stablecoins. [Here is an exampl](https://github.com/celo-org/governance/pull/419/files#diff-ba5ba5397b269ceb4b93f3876bedabac605daeec083a364a270675242fe7c424)e of this approach. Using this approach, it is not needed to submit to proposals and can be done in only one. | |
SortedOracles supports flagging two tokens as "equivalent". This way, no new oracle has to be deployed, which is useful for fiat-backed stablecoins. [Here is an example](https://github.com/celo-org/governance/pull/419/files#diff-ba5ba5397b269ceb4b93f3876bedabac605daeec083a364a270675242fe7c424) of this approach. Using this approach, it is not needed to submit two proposals, the change can be done in only one. |
|
||
Before submitting the second proposal, at least one of the oracle addresses need to call `report(address token, uint256 value, address lesserKey, address greaterKey)`. This will make a price available to the protocol for gas pricing. | ||
|
||
### Enabling as Gas Token | ||
|
||
The second proposal enables the gas token by calling `addToken(address tokenAddress)`. After this proposal passes, EOAs should be able to pay for gas in the enabled token. | ||
The second proposal enables the gas token by calling `FeeCurrencyDirectory.setCurrencyConfig(address token, address oracle, uint256 intrinsicGas)`. `intrinsicGas` is the estimated average amount of gas used by the functions `creditGasFees(...)`and `debitGasFees(...)`. A benchmark is recommended as an attachment to the governance proposal. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The second proposal enables the gas token by calling `FeeCurrencyDirectory.setCurrencyConfig(address token, address oracle, uint256 intrinsicGas)`. `intrinsicGas` is the estimated average amount of gas used by the functions `creditGasFees(...)`and `debitGasFees(...)`. A benchmark is recommended as an attachment to the governance proposal. | |
The second proposal enables the gas token by calling `FeeCurrencyDirectory.setCurrencyConfig(address token, address oracle, uint256 intrinsicGas)`. `intrinsicGas` is the estimated average amount of gas used by the functions `creditGasFees(...)` and `debitGasFees(...)`. A benchmark is recommended as an attachment to the governance proposal. |
The page needs to be added to the sidebar
No description provided.