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

Sync current changes. #1

Open
wants to merge 222 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
222 commits
Select commit Hold shift + click to select a range
440185e
Improve docker compose setup
MJYoung114 May 10, 2024
f1702ea
add restart always
MJYoung114 May 10, 2024
af2ab56
Setup hydra in docker compose
MJYoung114 May 13, 2024
dcc9790
add back remove generated
MJYoung114 May 13, 2024
b04a4d6
Merge pull request #110 from enviodev/improve-docker-setup
moose-code Jul 15, 2024
729cd2c
bump envio version
moose-code Jul 15, 2024
bd51ae9
Merge pull request #113 from enviodev/bump-version
moose-code Jul 15, 2024
c873c98
add
moose-code Sep 26, 2024
6b3d22a
Merge pull request #119 from enviodev/fix-merge
moose-code Sep 26, 2024
00e794e
improve how we handle rpc requests for user tokens. Log out informati…
moose-code Sep 26, 2024
f6ce730
update cache
moose-code Sep 26, 2024
27e4dbf
add numeric precision
moose-code Sep 27, 2024
baf9cde
add cl factory
moose-code Sep 27, 2024
6be2ffe
Add all the swap and sync activity enriched
moose-code Sep 27, 2024
edbfb5a
Add all cl pools events
moose-code Sep 27, 2024
6e38aaa
Finish adding cl pools
moose-code Sep 27, 2024
c4e4c4f
Correct start block
moose-code Sep 27, 2024
d20bcc8
Merge pull request #123 from enviodev/jj/add-cl
moose-code Sep 27, 2024
80ed7e0
Merge pull request #122 from enviodev/jj/add-all-info
moose-code Sep 27, 2024
ee3bf38
Merge pull request #121 from enviodev/add-cl-factory
moose-code Sep 27, 2024
6717523
Merge pull request #120 from enviodev/improve-rpc-handling
moose-code Sep 27, 2024
9d237dd
Refactor Event Handlers into separate files, and convert timestamps.
jfarid27 Sep 27, 2024
471670a
Merge pull request #125 from enviodev/refactor/event-handlers
moose-code Sep 29, 2024
68f52a7
Adding burns and mint collection to indexer.
jfarid27 Oct 2, 2024
b740376
Merge pull request #127 from enviodev/feature/burning-mint
moose-code Oct 2, 2024
f46bf1d
Bump version
moose-code Oct 2, 2024
0bf5a73
Merge pull request #129 from enviodev/bump-v2.4.1
moose-code Oct 3, 2024
c7bb071
fix
moose-code Oct 4, 2024
6090462
Merge pull request #131 from enviodev/fix-precision
moose-code Oct 4, 2024
f314029
Adding concentrated liquidity tracking and transaction hashes.
jfarid27 Oct 5, 2024
c6f4dc3
Fixing merge conflict error.
jfarid27 Oct 5, 2024
f6596d8
Fix merge conflict errors.
jfarid27 Oct 5, 2024
28a196b
Merge pull request #133 from enviodev/feature/track-hash-transfers
moose-code Oct 7, 2024
6720ccd
Adding price oracle fetching.
jfarid27 Oct 9, 2024
adcfa42
Add price checks through velo oracle.
jfarid27 Oct 9, 2024
6190afc
Update price oracle every hour.
jfarid27 Oct 9, 2024
c7891c9
Add price fetch call by block number.
jfarid27 Oct 10, 2024
01ae5dc
Refactoring price updates and removing PriceFetcher.
jfarid27 Oct 11, 2024
23e638b
Refactor out whitelisted tokens.
jfarid27 Oct 11, 2024
d42e176
Move check logic to Price Oracle.
jfarid27 Oct 11, 2024
1df96ff
Clean LPs.
jfarid27 Oct 11, 2024
be916a6
Merge pull request #135 from enviodev/feature/oracle-pricing-data-64
moose-code Oct 11, 2024
a632ae7
Bump version
moose-code Oct 11, 2024
84c141b
Merge pull request #136 from enviodev/bump-v2.4.4
moose-code Oct 11, 2024
19666e1
Starting to cache token prices
moose-code Oct 11, 2024
5021257
add try catch to rpc calls, set 0 price if it fails
moose-code Oct 11, 2024
9b78526
rather set -1 for oracle call errors in cache to debug and figure out…
moose-code Oct 11, 2024
74313b1
Add whitelisted full list.
jfarid27 Oct 12, 2024
1cd026f
Multiple chains in one step. Update prices.
jfarid27 Oct 13, 2024
41ecc2a
Fixing units.
jfarid27 Oct 13, 2024
a512d60
Normalize all tokenIDs with getter function.
jfarid27 Oct 13, 2024
66d8e0c
Merge pull request #137 from enviodev/tokenprice-cache
jfarid27 Oct 14, 2024
788ba6a
Merge remote-tracking branch 'origin/main' into feature/add-whitelist…
jfarid27 Oct 14, 2024
0e76396
Store address hash of prices.
jfarid27 Oct 14, 2024
5dcbe5e
Remove tokenprice cache.
jfarid27 Oct 14, 2024
0e4884b
Keep checksums for token addresses.
jfarid27 Oct 14, 2024
ea14e81
Add price oracle checksums.
jfarid27 Oct 14, 2024
efc2b2c
bugfix.
jfarid27 Oct 14, 2024
d3f79ff
Merge pull request #138 from enviodev/feature/add-whitelisted-tokens
moose-code Oct 14, 2024
74cb438
Update cache
moose-code Oct 15, 2024
d3e3ddf
Merge pull request #140 from enviodev/update-cache
moose-code Oct 15, 2024
b569873
Fixing old test specs and adding PR test github actions.
jfarid27 Oct 15, 2024
2d2ff7c
Run codegen instead of build.
jfarid27 Oct 15, 2024
03313af
Update test threshold.
jfarid27 Oct 15, 2024
107c3e7
Update threshold.
jfarid27 Oct 15, 2024
2bb2ef4
Comment out noisy logs and remove unused imports
moose-code Oct 15, 2024
25eb4bd
Merge pull request #139 from enviodev/feature/add-testing
moose-code Oct 15, 2024
b635c1a
Bump the npm_and_yarn group with 4 updates
dependabot[bot] Oct 15, 2024
543f814
Merge pull request #142 from enviodev/dependabot/npm_and_yarn/npm_and…
moose-code Oct 15, 2024
8fd601f
Fix Pool Event Swap to exclude whitelisted tokens.
jfarid27 Oct 15, 2024
0b805b4
Merge pull request #143 from enviodev/bugfix/pool-swap-missing-tokens
moose-code Oct 15, 2024
6e0f683
Adding loaders to improve historic sync speed
moose-code Oct 15, 2024
ec83369
Remove unnecessary checksums
moose-code Oct 15, 2024
704fecd
Merge pull request #145 from enviodev/jj/add-loaders
moose-code Oct 15, 2024
9837818
Log missing token event but don't error.
jfarid27 Oct 16, 2024
2f42545
Merge pull request #147 from enviodev/feature/remove-missing-token-lo…
jfarid27 Oct 16, 2024
f3be3a2
Feature/add whitelists voter (#148)
jfarid27 Oct 16, 2024
77037d4
Feature/update whitelisted (#149)
jfarid27 Oct 17, 2024
404f40c
Feature/pool liquidity updates (#150)
jfarid27 Oct 18, 2024
054a19d
Bump the npm_and_yarn group with 4 updates
dependabot[bot] Oct 18, 2024
3691706
Merge pull request #151 from enviodev/dependabot/npm_and_yarn/npm_and…
moose-code Oct 21, 2024
19affd8
Feature/agg stats (#152)
jfarid27 Oct 21, 2024
f926582
Log whitelisted events on token data. (#153)
jfarid27 Oct 22, 2024
0623ddb
Start adding CL Pool aggregator initialization to CL pool create event.
jfarid27 Oct 22, 2024
f75f149
Add CLPoolAggregator and tests.
jfarid27 Oct 23, 2024
2f036e9
Adding CLAggregator to factory and pool.
jfarid27 Oct 23, 2024
5ec0a99
Add CL pool swap tests.
jfarid27 Oct 23, 2024
d335ba5
Assert pool volumes are always positive.
jfarid27 Oct 23, 2024
a41e89e
Minor formatting update.
jfarid27 Oct 23, 2024
608eebd
Merge pull request #155 from enviodev/feature/capture-CL-pool-aggrega…
moose-code Oct 23, 2024
7b026da
Feature: Adds collection of CL fees to aggregator. (#159)
jfarid27 Oct 24, 2024
64de87d
Log error when pool_created is not found in a CLPool Swap event. (#158)
jfarid27 Oct 24, 2024
1d248f7
fix version
moose-code Oct 25, 2024
d34e92b
Merge pull request #161 from enviodev/fix-v
moose-code Oct 25, 2024
1cb5b7c
Update version
moose-code Oct 28, 2024
d19026c
Merge pull request #163 from enviodev/update-v2.6.1
moose-code Oct 28, 2024
97a0a98
Refactor test specs.
jfarid27 Oct 28, 2024
595ee7c
Add emissions aggregation check.
jfarid27 Oct 28, 2024
d81944d
Add bribes aggregation check.
jfarid27 Oct 28, 2024
bba29ed
Merge pull request #166 from enviodev/feature/emissions-bribes
moose-code Oct 29, 2024
cfc008e
v
MJYoung114 Oct 31, 2024
e07e5a5
x
MJYoung114 Oct 31, 2024
ebf03c5
x
MJYoung114 Oct 31, 2024
742684c
x
MJYoung114 Oct 31, 2024
a78939d
x
MJYoung114 Oct 31, 2024
e31140d
x
MJYoung114 Oct 31, 2024
5247a06
x
MJYoung114 Oct 31, 2024
d232402
x
MJYoung114 Oct 31, 2024
47d4e23
x
MJYoung114 Oct 31, 2024
4fca555
x
MJYoung114 Oct 31, 2024
d2d3395
x
MJYoung114 Oct 31, 2024
ff0221e
2.0.0
MJYoung114 Oct 31, 2024
31cd4cc
x
MJYoung114 Oct 31, 2024
fd5d3fa
x
MJYoung114 Oct 31, 2024
7e309dc
x
MJYoung114 Oct 31, 2024
bee1459
x
MJYoung114 Oct 31, 2024
97bf24d
x
MJYoung114 Oct 31, 2024
aef744c
x
MJYoung114 Oct 31, 2024
51fa35f
x
MJYoung114 Oct 31, 2024
df82ed2
x
MJYoung114 Oct 31, 2024
4917857
x
MJYoung114 Oct 31, 2024
86dbd86
Bugfix/clean liquidity (#169)
jfarid27 Nov 1, 2024
65bd01f
Adding liquidity management for burn events. (#170)
jfarid27 Nov 4, 2024
92f2f62
bump v2.7.2
moose-code Nov 4, 2024
73955b7
lockfile
moose-code Nov 4, 2024
af05d4b
Merge pull request #171 from enviodev/bump-to-v2.7.2
moose-code Nov 4, 2024
f4736d3
cleaning snapshots and keeping pool value unless updated. (#172)
jfarid27 Nov 5, 2024
2ec95e9
Refactor to merge CLPoolAggregator into a single LP Aggregator entity…
jfarid27 Nov 6, 2024
3d675a6
Force checksum addresses on gauge cache.
jfarid27 Nov 6, 2024
ad5956f
Adding a quick fix to update pool naming conventions to show CL. (#176)
jfarid27 Nov 6, 2024
c9c5011
Merge pull request #175 from enviodev/bugfix/force-checksum-address
moose-code Nov 7, 2024
1515696
Merge pull request #173 from enviodev/main
moose-code Nov 7, 2024
05f23e1
Mode network addition.
jfarid27 Nov 7, 2024
8db0af2
Feature: Cleanup emissions/bribes handlers (#178)
jfarid27 Nov 8, 2024
3575290
ALso bump version
moose-code Nov 8, 2024
fc6eea7
Merge pull request #177 from enviodev/feature/mode
moose-code Nov 8, 2024
c9f3134
Merge pull request #179 from enviodev/main
moose-code Nov 8, 2024
c107dee
Remove token normalization in general counts. (#180)
jfarid27 Nov 9, 2024
d1fe675
Remove token normalization in general counts. (#180) (#181)
jfarid27 Nov 9, 2024
7a42a2e
Fixing starter prices for Mode price oracle. (#182)
jfarid27 Nov 11, 2024
5409869
Bump hyperindex version (#183)
jfarid27 Nov 11, 2024
fc6c731
Bugfix: Price oracle mode (#184)
jfarid27 Nov 12, 2024
0d71d78
Deployment: Mode v2 (#185)
jfarid27 Nov 12, 2024
2a32924
Add fixes for CL pool burns. (#186)
jfarid27 Nov 13, 2024
8b733f0
Merge branch 'v2-hyperindex' into main
jfarid27 Nov 13, 2024
077f5a6
Bump hyperindex (#187)
jfarid27 Nov 13, 2024
b12385c
Adding Lisk. (#188)
jfarid27 Nov 14, 2024
2f26343
Adding whitelisted tokens and cleaning up cl pool. (#189)
jfarid27 Nov 14, 2024
0dd53ea
Bump Hyperindex (#190)
jfarid27 Nov 14, 2024
8ad6b51
Subtract CL pool reserves during Collect instead of Burn. (#191)
jfarid27 Nov 16, 2024
cba7728
Merge remote-tracking branch 'origin/v2-hyperindex'
jfarid27 Nov 16, 2024
50880e1
Merge pull request #192 from enviodev/main
jfarid27 Nov 16, 2024
d925f99
Adds swap deltas for reserve amounts.
jfarid27 Nov 16, 2024
ab1c57e
Merge pull request #193 from enviodev/feature/count-swap-deltas-reserve
jfarid27 Nov 16, 2024
4752ce7
Merge pull request #194 from enviodev/main
jfarid27 Nov 16, 2024
b0039cb
Update List oracle start block.
jfarid27 Nov 17, 2024
23547ff
Merge pull request #195 from enviodev/jfarid27-patch-1
jfarid27 Nov 17, 2024
5617e33
Merge pull request #196 from enviodev/main
jfarid27 Nov 17, 2024
da54020
Merge pull request #197 from enviodev/v2-hyperindex
jfarid27 Nov 18, 2024
3998b56
Add fee collection to reserve counts.
jfarid27 Nov 18, 2024
2208286
Merge pull request #198 from enviodev/feature/add-collect-fees-counts
jfarid27 Nov 18, 2024
92361f5
Feature: Track Superchain Factory Events (#200)
jfarid27 Nov 19, 2024
e691c35
Stores standard pool reserves as nominal token values, and cleans up …
jfarid27 Nov 19, 2024
c080f43
Add fee collection to reserve counts.
jfarid27 Nov 18, 2024
695f1d0
Feature: Track Superchain Factory Events (#200)
jfarid27 Nov 19, 2024
b4eeea3
Stores standard pool reserves as nominal token values, and cleans up …
jfarid27 Nov 19, 2024
6441992
Feature: Tracking Votes for Distribute Rewards (#202)
jfarid27 Nov 20, 2024
4f41fa4
Update CL pool names to include tickspacing. (#204)
jfarid27 Nov 20, 2024
a4d0019
Adding Superchain Factories tests.
jfarid27 Nov 20, 2024
0f8e30d
Weekly Indexer Deployment (#205)
jfarid27 Nov 20, 2024
d60409d
Include pnpm in readme. (#207)
jfarid27 Nov 21, 2024
c21a0e4
Merge pull request #208 from enviodev/v2-hyperindex
jfarid27 Nov 21, 2024
9bc1b4d
Store gauge active state in liquidity pool aggregator.
jfarid27 Nov 22, 2024
95077e1
Fetch single bribe reward prices.
jfarid27 Nov 24, 2024
8d26a79
Merge pull request #211 from enviodev/feature/track-bribes-prices
jfarid27 Nov 25, 2024
9f0a8fd
Merge pull request #206 from enviodev/feature/add-superchain-factorie…
jfarid27 Nov 25, 2024
a4d8ae9
Merge pull request #210 from enviodev/feature/store-gauge-alive
jfarid27 Nov 25, 2024
c51152e
Adding SuperchainVoter split.
jfarid27 Nov 27, 2024
d0e2744
Adding tests.
jfarid27 Nov 27, 2024
7fd3d21
Refactor common test code.
jfarid27 Nov 27, 2024
3cf899b
Merge pull request #212 from enviodev/feature/data-154-superchain-gauge
jfarid27 Nov 27, 2024
a838642
Merge pull request #213 from enviodev/main
jfarid27 Nov 29, 2024
89bdea3
Tap Readme.
jfarid27 Nov 29, 2024
a55e42f
Merge pull request #214 from enviodev/main
jfarid27 Nov 29, 2024
ae90fb6
Update README.md
jfarid27 Dec 2, 2024
3cd7d15
Merge pull request #215 from enviodev/jfarid27-patch-1
jfarid27 Dec 2, 2024
166fd2f
Merge pull request #216 from enviodev/v2-hyperindex
jfarid27 Dec 2, 2024
f442fb9
Update Constants.ts
jfarid27 Dec 2, 2024
c3f23ac
Merge pull request #217 from enviodev/fix-lisk-rpc
jfarid27 Dec 2, 2024
6004043
Merge branch 'v2-hyperindex'
jfarid27 Dec 2, 2024
9e08f93
Remove errernous rpc calls and bump version
moose-code Dec 2, 2024
76af975
Merge pull request #218 from enviodev/deploy-candidate
moose-code Dec 2, 2024
774acff
Remove mismatched ABIs.
jfarid27 Dec 2, 2024
3df9d35
Merge remote-tracking branch 'origin/v2-hyperindex' into bugfix/voter…
jfarid27 Dec 2, 2024
954d448
Adding warning context.
jfarid27 Dec 2, 2024
352a601
Add better logging.
jfarid27 Dec 3, 2024
917969a
Merge pull request #219 from enviodev/bugfix/voter-fix
jfarid27 Dec 3, 2024
f52de90
Merge pull request #221 from enviodev/main
jfarid27 Dec 3, 2024
25dfb3f
Bugfix: Moving RPC calls to loader. (#223)
jfarid27 Dec 3, 2024
38e82af
Kelvin, Trigger Deployment
Piroddi Dec 3, 2024
52f1a16
update docker file
MJYoung114 Dec 4, 2024
9144c32
push
MJYoung114 Dec 4, 2024
8a475ce
Add pool address to voting incentives data. (#226)
jfarid27 Dec 4, 2024
a176a2f
Bugfix: Catch Viem Token Detail Exceptions (#227)
jfarid27 Dec 4, 2024
7190182
Merge pull request #228 from enviodev/main
jfarid27 Dec 4, 2024
1cf7d88
Feature: Price Tokens on Swap (#229)
jfarid27 Dec 8, 2024
9b4ea42
Merge pull request #230 from enviodev/main
jfarid27 Dec 8, 2024
340df31
Adding fetching prices using all connectors.
jfarid27 Dec 9, 2024
f72a7af
Merge pull request #231 from enviodev/bugfix/fetch-all-connector-prices
jfarid27 Dec 9, 2024
b4e9fb4
Merge pull request #232 from enviodev/main
jfarid27 Dec 9, 2024
49f4bbd
Bugfix: Hardcode price connectors (#234)
jfarid27 Dec 10, 2024
1966698
Merge pull request #235 from enviodev/main
jfarid27 Dec 10, 2024
cbc838a
Adding back whitelisted tokens.
jfarid27 Dec 11, 2024
ea84bf4
Merge pull request #236 from enviodev/hotfix/price-oracle-old
jfarid27 Dec 11, 2024
29d8986
Merge pull request #237 from enviodev/main
jfarid27 Dec 11, 2024
96beb89
Use price connector list and fix price update timing calculation.
jfarid27 Dec 11, 2024
8cdbf10
Merge pull request #238 from enviodev/hotfix/price-update-2
jfarid27 Dec 11, 2024
5e78ff3
Better prices.
jfarid27 Dec 11, 2024
5752016
Merge pull request #240 from enviodev/hotfix/price-update-3
jfarid27 Dec 11, 2024
77df18b
Bump indexer (#239)
jfarid27 Dec 11, 2024
10fec48
Add back token price snapshot entity. (#242)
jfarid27 Jan 2, 2025
ebebf87
Merge branch 'v2-hyperindex'
jfarid27 Jan 2, 2025
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
2 changes: 1 addition & 1 deletion .cache/bribetopool-10.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions .cache/bribetopool-1135.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"0x308754336Cdd9eE6F773e0C1D9F2D1f9c20d8Ce7":{"poolAddress":"0x79a7dBF4d7eA058F0d3B94db7fF86F1c1A7BDb25"},"0xF1303a5Ca8d0caf8BEeE8eC8A0ab709fA822f857":{"poolAddress":"0xe36926807aa151C89125057742656AF8669d4cB1"},"0xE672729F55C70fB16b935FE0E7a0269f2eeac89c":{"poolAddress":"0xc2026f3fb6fc51F4EcAE40a88b4509cB6C143ed4"},"0x6990B78e7Cb273A1E10c59f359f5fB6d1E4082Bf":{"poolAddress":"0x5C2bb5Fcb384D7244e5892926985bF5Ec6cE3488"},"0xd9F5cF355191610B04F1936192bd898829C9b2d7":{"poolAddress":"0x25B559e6E64226C0A1637B8E94f3f4740fa0D562"},"0x020F2C9B09148E4F3FDe956C780F330011A54D9e":{"poolAddress":"0xa913882766Af5fFD34E72Bdd646e8E8957Fe1842"},"0x6dDD1349FF177ebC008AcEA6Bd8aBCe171728FaD":{"poolAddress":"0x18Eb25a15eC48Db3C42A0F41EC0a716Ba6b54514"},"0x2B760c6787fF783C83E2Ef3FcbE54f1b9e7758C2":{"poolAddress":"0xDC1479FD1Db51cA0079ceCfaA879232e168c8246"}}
2 changes: 1 addition & 1 deletion .cache/bribetopool-8453.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion .cache/guagetopool-10.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions .cache/guagetopool-1135.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"0xAD6a17F3DeB425371730198073D69c83052351D6":{"poolAddress":"0x79a7dBF4d7eA058F0d3B94db7fF86F1c1A7BDb25"},"0x68229065b476d7426d82930E906b3C8A42e2706D":{"poolAddress":"0xe36926807aa151C89125057742656AF8669d4cB1"},"0x001DAD1CC0354C90de8f7304EEaCA732E3e25115":{"poolAddress":"0xc2026f3fb6fc51F4EcAE40a88b4509cB6C143ed4"},"0x0277d114BD08E3Ffdc25D289A2094A9E0aB801cF":{"poolAddress":"0x5C2bb5Fcb384D7244e5892926985bF5Ec6cE3488"},"0xD7FE1e0C17C34874B65b75c88f3B17d422837e61":{"poolAddress":"0x25B559e6E64226C0A1637B8E94f3f4740fa0D562"},"0x8bB8d6e5151FFfe9B1d1260360747A4371079D44":{"poolAddress":"0xa913882766Af5fFD34E72Bdd646e8E8957Fe1842"},"0xa170926d2f6506D0145187e46067Fe8E7cB239f4":{"poolAddress":"0x18Eb25a15eC48Db3C42A0F41EC0a716Ba6b54514"},"0x3aF261A143280f8a945aeBdC40747122Bb813a5B":{"poolAddress":"0xDC1479FD1Db51cA0079ceCfaA879232e168c8246"}}
2 changes: 1 addition & 1 deletion .cache/guagetopool-8453.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion .cache/token-10.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions .cache/token-1135.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"0x4200000000000000000000000000000000000006":{"decimals":18,"name":"Wrapped Ether","symbol":"WETH"},"0xac485391eb2d7d88253a7f1ef18c37f4242d1a24":{"decimals":18,"name":"Lisk","symbol":"LSK"},"0x05d032ac25d322df992303dca074ee7392c117b9":{"decimals":6,"name":"Tether USD","symbol":"USDT"},"0xf242275d3a6527d877f2c927a82d9b057609cc71":{"decimals":6,"name":"Bridged USDC (Lisk)","symbol":"USDC.e"},"0x7f9adfbd38b669f03d1d11000bc76b9aaea28a81":{"decimals":18,"name":"Superchain Velodrome","symbol":"XVELO"},"0x03c7054bcb39f7b2e5b2c7acb37583e32d70cfa3":{"decimals":8,"name":"Wrapped BTC","symbol":"WBTC"},"0x03b8dc577b89a94b86eaa32249f86b1bf792959f":{"decimals":6,"name":"NTEST","symbol":"NTEST"},"0x4900900a850153ea6eb7d172362a37354ad04828":{"decimals":6,"name":"USDN","symbol":"USDN"}}
1 change: 1 addition & 0 deletions .cache/token-34443.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"0x4200000000000000000000000000000000000006":{"decimals":18,"name":"Wrapped Ether","symbol":"WETH"},"0xd988097fb8612cc24eec14542bc03424c656005f":{"decimals":6,"name":"USD Coin","symbol":"USDC"},"0xdfc7c877a950e49d2610114102175a06c2e3167a":{"decimals":18,"name":"Mode","symbol":"MODE"},"0xf0f161fda2712db8b566946122a5af183995e2ed":{"decimals":6,"name":"Tether USD","symbol":"USDT"},"0xcdd475325d6f564d27247d1dddbb0dac6fa0a5cf":{"decimals":8,"name":"Wrapped BTC","symbol":"WBTC"},"0x59889b7021243db5b1e065385f918316cd90d46c":{"decimals":18,"name":"Merlin BTC","symbol":"M-BTC"},"0x18470019bf0e94611f15852f7e93cf5d65bc34ca":{"decimals":18,"name":"Ionic","symbol":"ION"},"0x04c0599ae5a44757c0af6f9ec3b93da8976c150a":{"decimals":18,"name":"Wrapped eETH","symbol":"weETH.mode"},"0x2416092f143378750bb29b79ed961ab195cceea5":{"decimals":18,"name":"Renzo Restaked ETH","symbol":"ezETH"},"0x4186bfc76e2e237523cbc30fd220fe055156b41f":{"decimals":18,"name":"KelpDao Restaked ETH","symbol":"rsETH"},"0x80137510979822322193fc997d400d5a6c747bf7":{"decimals":18,"name":"StakeStone Ether","symbol":"STONE"},"0xe7798f023fc62146e8aa1b36da45fb70855a77ea":{"decimals":18,"name":"Dai Stablecoin","symbol":"DAI"},"0x6a660e56fa3b630a786cc4ae98859f8532d03de9":{"decimals":18,"name":"BeastMode","symbol":"BEAST"},"0x7906c8893362f1475e05c0647ed40c76a4ec9b72":{"decimals":0,"name":"","symbol":""},"0xe12f0247433a150a1ad957a4f56189a2fd3a4c02":{"decimals":0,"name":"","symbol":""}}
2 changes: 1 addition & 1 deletion .cache/token-8453.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions .cache/tokenprices-10.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions .cache/tokenprices-1135.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions .cache/tokenprices-8453.json

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
ENVIO_OPTIMISM_RPC_URL=https://rpc.ankr.com/optimism
ENVIO_BASE_RPC_URL=https://base.publicnode.com
ENVIO_MODE_RPC_URL=https://mainnet.mode.network
ENVIO_LISK_RPC_URL=https://lisk.drpc.org
47 changes: 47 additions & 0 deletions .github/workflows/pnpm-pr-test.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: PNPM Build and Test

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
build-and-test:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'

- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: 8

- name: Get pnpm store directory
id: pnpm-cache
shell: bash
run: |
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT

- uses: actions/cache@v3
name: Setup pnpm cache
with:
path: ${{ steps.pnpm-cache.outputs.STORE_PATH }}
key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }}
restore-keys: |
${{ runner.os }}-pnpm-store-

- name: Install dependencies
run: pnpm install

- name: Build
run: pnpm run codegen

- name: Run tests
run: pnpm test
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,4 @@ generated
logs
*.bs.js
build
.env
8 changes: 3 additions & 5 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@

ARG ARCH=
FROM ${ARCH}mcr.microsoft.com/devcontainers/javascript-node:20-bookworm
FROM ${ARCH}node:20-bookworm
ARG TARGETARCH
WORKDIR /app/base-template

RUN npm install -g npm@latest
COPY . .

ENV PNPM_HOME /usr/local/binp
RUN npm install --global pnpm
RUN npm install --global pnpm@9.10.0

RUN pnpm install

RUN pnpm envio codegen
CMD ./envio-entrypoint.sh
19 changes: 19 additions & 0 deletions Dockerfile-hydra
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@

ARG ARCH=
FROM ${ARCH}mcr.microsoft.com/devcontainers/javascript-node:20-bookworm
WORKDIR /app/base-template

RUN npm install -g npm@latest
COPY . .

ENV PNPM_HOME /usr/local/binp
RUN npm install --global pnpm

RUN pnpm install

RUN pnpm envio codegen

COPY ./hack/hydra-mode/TrackTables.res ./generated/src
COPY ./hack/hydra-mode/HydraMigrate.res ./generated/src

CMD ./envio-entrypoint-hydra.sh
17 changes: 16 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,11 +1,21 @@
.PHONY: start
start:
docker compose up --build -d
docker stats envio-indexer

.PHONY: start-hydra
start-hydra:
docker compose -f docker-compose-hydra.yaml up --build -d
docker stats envio-indexer

.PHONY: hard-stop
hard-stop:
docker compose down -v
make remove-generated
.PHONY: hard-stop-hydra
hard-stop-hydra:
docker compose -f docker-compose-hydra.yaml down -v
make remove-generated

.PHONY: remove-generated
remove-generated:
Expand All @@ -15,11 +25,16 @@ remove-generated:
stop:
docker compose down

.PHONY: stop-dev
.PHONY: hard-restart
hard-restart:
make hard-stop
make start

.PHONY: hard-restart-hydra
hard-restart-hydra:
make hard-stop-hydra
make start-hydra

.PHONY: restart
restart:
make stop
Expand Down
44 changes: 37 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
## Multi-chain indexer for Velodrome V2 and Aerodrome

This repo contains the indexer for [Velodrome V2](https://velodrome.finance/) on Optimism and [Aerodrome](https://aerodrome.finance/) on Base.

This repo contains the indexer for [Velodrome V2](https://velodrome.finance/) and
[Aerodrome](https://aerodrome.finance/) across multiple chains.
The indexer is written in TypeScript.

### Overview of user-defined files
Expand All @@ -23,39 +23,53 @@ The indexer is written in TypeScript.
- The event handlers are written in TypeScript for Velodrome indexer.
- Consists of a `loader` and a `handler` function for each event - see [here](https://docs.envio.dev/docs/event-handlers) for detailed explanation of the purpose of the two functions.
- Makes use of custom helper functions and types in `/src` directory - these have been added to minimize code duplication and refactored to increase readability of the overall codebase.
- `.env`
- Remove `.example` from `.env` and add variables to customize secrets in the handlers and configuration.
- `.env` variables will be included using the [dotenv](https://www.dotenv.org/docs/) library.
- Assert in deployment that the variables are included if they are necessary for the project.

### Development

To develop the indexer further, refer to the [Envio documentation](https://docs.envio.dev/docs/overview) for additional guidelines.
To develop the indexer further, refer to the [Envio documentation](https://docs.envio.dev/docs/overview) for additional guidelines. It is expected to run the
indexer with [pnpm](https://pnpm.io/).

### Installation

To install the necessary packages and dependencies, run pnpm's installation. The current system
is running with pnpm version 9.11.0.

```bash
pnpm i
```

#### Notable Envio CLI commands

This command will generate the `generated` folder for the repo based on the latest `config.yaml` and `schema.graphql` files.

```bash
envio codegen
pnpm envio codegen
```

During local testing, this command will drop all the existing information in the database and create new tables for a new local run.

```bash
envio local db-migrate setup
pnpm envio local db-migrate setup
```

### Running the indexer

Clone this repo and then run (this single command will spin up the required docker images, run DB migrations, perform codegen for any changes and start the indexer)

```bash
envio dev
pnpm envio dev
```

> Make sure you have Docker application running

To stop the indexer, run

```bash
envio stop
pnpm envio stop
```
### Hydra-mode

Expand Down Expand Up @@ -89,6 +103,22 @@ To push the Envio indexer container to a container registry login to the registr

example: `make build-push-indexer TAG="velodrome-indexer-prod-1" ARCH="linux/amd64"`


### Hydra setup

Similar to the above, but uses a hydra postgres instance with no hasura.

Setup files:

- `docker-compose-hydra.yaml`
- `Dockerfile-hydra`
- `envio-entrypoint-hydra.sh`

Make commands:
- `make start-hydra`
- `make hard-stop-hydra`
- `make hard-restart-hydra`

### Testing

To run the tests inside `/test` directory, run
Expand Down
1 change: 1 addition & 0 deletions abis/SuperchainPoolABI.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[{"inputs":[],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"AlreadyInitialized","type":"error"},{"inputs":[],"name":"chainid","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"factory","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"_chainid","type":"uint256"},{"internalType":"address","name":"_token0","type":"address"},{"internalType":"address","name":"_token1","type":"address"},{"internalType":"bool","name":"_stable","type":"bool"}],"name":"initialize","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"stable","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"token0","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"token1","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"}]
26 changes: 26 additions & 0 deletions abis/VeloPriceOracleABI.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
[
{
"inputs": [
{
"internalType": "uint8",
"name": "src_len",
"type": "uint8"
},
{
"internalType": "contract IERC20Metadata[]",
"name": "connectors",
"type": "address[]"
}
],
"name": "getManyRatesWithConnectors",
"outputs": [
{
"internalType": "uint256[]",
"name": "rates",
"type": "uint256[]"
}
],
"stateMutability": "view",
"type": "function"
}
]
1 change: 1 addition & 0 deletions abis/VoterABI.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"isAlive","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}]
Loading