Skip to content
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

nars - snars - collateral plugin #1217

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

ezequiel-num
Copy link

  • WIP:
  • Description: Collateral Plugins for NARS / SNARS Tokens

Tokens Description:

NARS: Token peged to ARS (Argentinean Peso)
Token Address: 0x5e40f26E89213660514c51Fb61b2d357DBf63C85 (Base)
Valuation: Chianlink Oracle 0xC3a426Ef79fd60A4cA785FC04a2C3cB09d2FEeae

SNARS: Yield Bearing Token nomitaned in NARS
Token Address: 0xC1F4C75e8925A67BE4F35D6b1c044B5ea8849a58 (Base)
Valuation: (amount * convertToAsset(Function in the SNARS token Address)) / NARS Oracle Price

common/configuration.ts Outdated Show resolved Hide resolved
contracts/plugins/assets/num/SnARSFiatCollateral.sol Outdated Show resolved Hide resolved
@@ -1003,6 +1004,32 @@ export default function fn<X extends CollateralFixtureContext>(
targetUnitOracle.address,
ORACLE_TIMEOUT
)
} else if (target == ethers.utils.formatBytes32String('ARS')) {
// ARS
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think we want to throw an error if not targetting Base, right? seems to be the only chain on which nARS is deployed

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed!

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why was this removed? my point was that we just need to check if we're running the tests against base

test/plugins/individual-collateral/num/constants.ts Outdated Show resolved Hide resolved

In this particular case we're incorporating through this plugin 2 nTokens.

- `nARS` is a stablecoin pegged to the `Argentine Peso (ARS)`.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please include a note on the oracle used here. iirc you run the oracle and update it rather frequently. detail the % deviation and timeout thresholds (assuming they are in your documentation, but would like to have it legible directly in this repo)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants