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

Fetch UCO price from coinPaprika #728

Closed
Neylix opened this issue Nov 30, 2022 · 0 comments
Closed

Fetch UCO price from coinPaprika #728

Neylix opened this issue Nov 30, 2022 · 0 comments
Assignees
Labels
feature New feature request oracle chain Involve OracleChain

Comments

@Neylix
Copy link
Member

Neylix commented Nov 30, 2022

Is your feature request related to a problem?

As #727 will permit to have multiple data source for an oracle value, we should get the uco price from other source.

Describe the solution you'd like

Coin paprika expose a free API to fetch the price of a currency from multiple platform:

https://api.coinpaprika.com/v1/coins/uco-uniris/markets?quotes=USD,EUR

For each platform returned by the API, we can add it's price into the aggregator

Additional context

No response

@Neylix Neylix added feature New feature request oracle chain Involve OracleChain labels Nov 30, 2022
@Neylix Neylix changed the title Fetch oracle price from coinPaprika Fetch UCO price from coinPaprika Nov 30, 2022
@tenmoves tenmoves self-assigned this Dec 9, 2022
netboz added a commit to netboz/archethic-node that referenced this issue Dec 13, 2022
netboz added a commit to netboz/archethic-node that referenced this issue Jan 6, 2023
Neylix added a commit that referenced this issue Jan 11, 2023
* Update UCO service provider to list of providers #727
[Config Change]

* Updating UCO service to compute mean of provider results #727

* Updating tests #727

* Formatting #727

* Removing unneeded duplicate service #727

* refactor services prices fetching

* formatting code #727

* Refactor to integrate with #728 and #729 wip

* Fixing tests and formatting

* Adding tests for error cases, formatting

* Parallelize service values fetching

* Linting

* Fixing test after mock renaming

* Adding general failsafe clause

* add coin marketcap and coin paprika as uco price providers

* Integrating #769

* Fixing legacy tests

* Fixing tests

* Adding option to kill task on timeout

* Increase log severity when no data returned by service

* Slight optimisation

* Compute median instead of mean

* transform prices from keyword list to map in coingecko

* Make service result parsing more resilient

* lowercasing key for code resilience

* Fixing index issue

* Fixing flaky test

* Unlink fetching processes to avoid termination of scheduler if service crash

* updated coin marketcap and coin paprika

* updated marketcap implementation

* Refactoring median function

* Refactoring Agregator, adapting tests accordingly.

* Reducing max nesting level to please credo plus format big numbers

* Fix remaining bugs

Co-authored-by: tenmoves <hamza.belhaj07@gmail.com>
Co-authored-by: Neylix <julien.leclerc05@protonmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature request oracle chain Involve OracleChain
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants