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

feat: Theoros v1.0 #86

Merged
merged 55 commits into from
Nov 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
231b850
dev(better_theoros): init
akhercha Oct 31, 2024
5817ccc
dev(better_theoros): pt1
akhercha Oct 31, 2024
527a497
dev(better_theoros):
akhercha Oct 31, 2024
58e0d43
dev(better_theoros):
akhercha Nov 1, 2024
3a7f411
dev(better_theoros): Hyperlane service
akhercha Nov 1, 2024
f3f7025
dev(better_theoros):
akhercha Nov 1, 2024
0282a02
dev(better_theoros):
akhercha Nov 1, 2024
7a6542d
dev(better_theoros):
akhercha Nov 1, 2024
4f877fb
dev(better_theoros): comms
akhercha Nov 1, 2024
ed2d9e8
dev(better_theoros): better
akhercha Nov 1, 2024
85d0ad2
dev(better_theoros): logs
akhercha Nov 1, 2024
ea11ed2
dev(better_theoros): added todo
akhercha Nov 1, 2024
f2a18e6
dev(better_theoros):
akhercha Nov 1, 2024
bd3453b
dev(better_theoros): updated README
akhercha Nov 1, 2024
149dd45
dev(better_theoros): Removed default active chain in websocket
akhercha Nov 1, 2024
2adf0e4
dev(better_theoros): better comment
akhercha Nov 1, 2024
ac4907d
dev(better_theoros): last nitpick 💀
akhercha Nov 1, 2024
733e8df
dev(better_theoros): Simpler struct
akhercha Nov 1, 2024
cb6bfa7
dev(better_theoros): used same terminology between structs
akhercha Nov 1, 2024
d9bfb57
dev(better_theoros): Added TODO for calldata
akhercha Nov 1, 2024
dc0d74e
dev(better_theoros): smol perf update
akhercha Nov 2, 2024
4fa9d6c
dev(better_theoros): reading improvements
akhercha Nov 2, 2024
00a86e5
fix: strum EnumString
EvolveArt Nov 2, 2024
4430538
dev(better_theoros): Fixed EnumString deserialisation
akhercha Nov 2, 2024
653d3dd
dev(better_theoros): Works with N signatures
akhercha Nov 2, 2024
efbed1e
dev(better_theoros):
akhercha Nov 2, 2024
28a5ad8
dev(better_theoros): better opti
akhercha Nov 2, 2024
f5f568f
dev(better_theoros): last commit - assert that the checkpoint is the …
akhercha Nov 2, 2024
496d79f
dev(better_theoros): Removed unused dependencies
akhercha Nov 2, 2024
54daadc
dev(better_theoros):
akhercha Nov 2, 2024
397d014
dev(better_theoros): 🔨 optimizations
akhercha Nov 2, 2024
66b5340
dev(better_theoros): 🔨 nitpicking optis
akhercha Nov 2, 2024
8172260
dev(better_theoros): supports N datafeeds + returns N calldata
akhercha Nov 2, 2024
2ff6699
dev(better_theoros): Updated openapi specs
akhercha Nov 2, 2024
3623e5d
dev(better_theoros): Send error to ws client
akhercha Nov 2, 2024
7478b5a
dev(better_theoros): ✅ Websocket finished
akhercha Nov 2, 2024
312734e
dev(better_theoros): Fixed loop
akhercha Nov 2, 2024
6561565
dev(better_theoros): Fixed js script to update EVM feeds
akhercha Nov 2, 2024
f00af53
dev(better_theoros): Theoros SDK
akhercha Nov 2, 2024
7fbb334
dev(better_theoros): updated README for SDk
akhercha Nov 2, 2024
0d89048
dev(better_theoros):
akhercha Nov 2, 2024
515e5da
dev(better_theoros): Better example + README
akhercha Nov 2, 2024
d3d810d
dev(better_theoros): ✅ theoros SDK
akhercha Nov 2, 2024
60a9760
dev(better_theoros): Updated SDK Readme
akhercha Nov 2, 2024
0dd0d5f
dev(better_theoros): 🔨 Fixed & Tested SDK
akhercha Nov 2, 2024
01b90f8
dev(better_theoros): Fixed example
akhercha Nov 2, 2024
a65dc5d
dev(better_theoros): Prevent overflows in indexer
akhercha Nov 3, 2024
34175f0
fix: nit picks
EvolveArt Nov 3, 2024
2fb8c6b
Update tsconfig.json
EvolveArt Nov 3, 2024
1266168
dev(better_theoros): Fixes from review
akhercha Nov 3, 2024
3e97722
dev(better_theoros): Lint
akhercha Nov 3, 2024
0e9a318
dev(better_theoros): docs
akhercha Nov 3, 2024
2ddc683
dev(better_theoros): Use DashMap / DashSet where applicable
akhercha Nov 3, 2024
98dffdd
fix: remove box
EvolveArt Nov 3, 2024
c6a2de3
dev(better_theoros): Removed useless Result
akhercha Nov 3, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 22 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,17 @@
# Pragma
# Pragma V2

[![GitHub Actions][gha-badge]][gha] [![codecov](https://codecov.io/gh/astraly-labs/pragma-monorepo/branch/main/graph/badge.svg?)](https://codecov.io/gh/astraly-labs/pragma-monorepo) [![Foundry][foundry-badge]][foundry] [![License: MIT][license-badge]][license]
[![GitHub Actions][gha-badge]][gha] [![Foundry][foundry-badge]][foundry] [![License: MIT][license-badge]][license]

[gha]: https://github.com/astraly-labs/pragma-monorepo/actions
[gha-badge]: https://github.com/PaulRBerg/prb-math/actions/workflows/ci.yml/badge.svg
[codecov-badge]: https://img.shields.io/codecov/c/github/astraly-labs/pragma-monorepo
[foundry]: https://getfoundry.sh/
[foundry-badge]: https://img.shields.io/badge/Built%20with-Foundry-FFDB1C.svg
[license]: https://www.apache.org/licenses/LICENSE-2.0
[license-badge]: https://img.shields.io/badge/License-Apache-blue.svg
[license]: https://opensource.org/license/mit
[license-badge]: https://img.shields.io/badge/License-MIT-blue.svg

## Rust

<a href="./rust/pragma-cli/">Pragma CLI</a>

CLI used to interact with the Pragma protocol.

- Register yourself as a data provider
- Schedule new data feeds
- Connect pragma to your protocol

<a href="./rust/theoros/">Theoros</a>

Request the API to construct the calldata necessary for cross-chain updates.
Expand All @@ -28,6 +20,16 @@ Request the API to construct the calldata necessary for cross-chain updates.
- Retrieves the signatures of the Hyperlane Validators
- Constructs the calldata for data feeds requested through HTTP/WebSocket

## Cairo

<a href="./cairo/oracle">Pragma Oracle</a>

Core Contacts of the Pragma Oracle.

<a href="./cairo/dispatcher">Pragma Dispatcher</a>

Wrapper around the Pragma Oracle that allows us to dispatch feed updates through Hyperlane.

## Solidity

<a href="./solidity/">Solidity SDK</a>
Expand All @@ -37,22 +39,18 @@ Solidity contracts & libraries.
- Set of contracts used to store data relayed from Pragma chain using Hyperlane.
- SDK that can be used by EVM protocols looking to integrate Pragma.

## Local Development
## Typescript

### Foundry
<a href="./typescript/theoros-sdk/">Theoros SDK</a>

First ensure you have Foundry installed on your machine.
A SDK used to query data from Theoros in a simple way.

Run the following to install `foundryup`:
- Fetch the latest calldata using either REST or Websocket endpoints.

```bash
curl -L https://foundry.paradigm.xyz | bash
```
<a href="./typescript/pragma-deployer/">Pragma Deployer</a>

Then run `foundryup` to install `forge`, `cast`, `anvil` and `chisel`.
The main scripts used to deploy all our contracts (Cairo, Solidity, ...) are located there.

```bash
foundryup
```
<a href="./typescript/pragma-scripts/">Pragma Scripts</a>

Check out the [Foundry Book](https://book.getfoundry.sh/getting-started/installation) for more information.
Utils scripts that we use to make some actions on-chain.
4 changes: 0 additions & 4 deletions monorepo.code-workspace
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,6 @@
"name": "theoros",
"path": "rust/theoros",
},
{
"name": "pragma-cli",
"path": "rust/pragma-cli",
},
{
"name": "pragma-utils",
"path": "rust/pragma-utils",
Expand Down
Loading
Loading