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

Make conversion of Stellar DIA assets unique (bi-directionally) #396

Open
ebma opened this issue Sep 7, 2023 · 6 comments
Open

Make conversion of Stellar DIA assets unique (bi-directionally) #396

ebma opened this issue Sep 7, 2023 · 6 comments
Labels
priority:low Do it some day

Comments

@ebma
Copy link
Member

ebma commented Sep 7, 2023

Right now, the DiaOracleKeyConvertor does not take the issuer of stellar assets into account. We should think about changing that. We should find a way to translate between Stellar assets and DIA identifiers bi-directionally meaning that a Stellar asset (issuer + code) is uniquely defined by a DIA asset and vice versa.
For this to work, we might also have to touch the dia-batching-server implementation because this responds to the prices for DIA assets.

@ebma ebma mentioned this issue Sep 7, 2023
2 tasks
@ebma ebma changed the title Improve and deduplicate the DiaOracleKeyConvertor. Right now, the DiaOracleKeyConvertor does not take the issuer of stellar assets into account. We should think about changing that. We should find a way to translate between Stellar assets and DIA identifiers bi-directionally meaning that a Stellar asset (issuer + code) is uniquely defined by a DIA asset and vice versa. For this to work, we might also have to touch the dia-batching-server implementation because this responds with the prices for DIA assets. Make conversion of Stellar DIA assets unique (bi-directionally) Sep 7, 2023
@ebma
Copy link
Member Author

ebma commented Sep 7, 2023

@pendulum-chain/product this is a follow-up ticket of #234.
The motivation for this ticket is to disambiguate the conversion of Stellar assets in the DIA oracle pallet. As it is right now, we only check the code of a Stellar asset and then assign a price to it. E.g. for the GABCD...:USDC Stellar asset, we only check the code which is USDC, and conclude that we should use the USD fiat price. We don't take into account the issuer, however, so the GABCD...:USDC asset will be treated the same as a GDCBA...:USDC asset. While this works, we eventually might want to be able to differentiate between the two. That's what this ticket is about.

@ebma ebma added the priority:low Do it some day label Sep 7, 2023
@vadaynujra
Copy link

Differentiate wrt the price or other factors as well i.e. is the benefit of this disambiguation only to be able to assign separate price feeds or to differentiate between the two assets, in general?

@ebma
Copy link
Member Author

ebma commented Sep 8, 2023

Since this ticket is only about changes regarding the price oracle it's only in regard to separate price feeds.
Imagine that for some USDC we want to assign the FIAT price and for another, we want to assign some blockchain price (ie. the price of USDC on Ethereum). This is not possible right now but would be possible afterward.
Not saying that we want or should do this anytime soon or ever.

@prayagd
Copy link
Collaborator

prayagd commented Oct 31, 2023

Hey team! Please add your planning poker estimate with Zenhub @b-yap @ebma @gianfra-t @TorstenStueber

@prayagd
Copy link
Collaborator

prayagd commented Dec 7, 2023

@ebma candidate for icebox?

@ebma
Copy link
Member Author

ebma commented Dec 7, 2023

Yes, it's not urgent right now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority:low Do it some day
Projects
None yet
Development

No branches or pull requests

3 participants