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: integrate stableswap pallet #612

Merged
merged 107 commits into from
Sep 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
107 commits
Select commit Hold shift + click to select a range
979f2d4
integrate stableswap pallet
enthusiastmartin Jun 16, 2023
f301ed6
Merge branch 'master' into feat/stableswap-runtime
enthusiastmartin Jul 3, 2023
0df37f6
reformat
enthusiastmartin Jul 3, 2023
e561ce1
update cargofile
enthusiastmartin Jul 3, 2023
b7e59f4
Merge branch 'master' into feat/stableswap-runtime
enthusiastmartin Jul 8, 2023
11bfc55
bump runtime version
enthusiastmartin Jul 8, 2023
9bd206f
Merge branch 'master' into feat/stableswap-runtime
enthusiastmartin Jul 14, 2023
2b25bc6
bump runtime version and add stableswap to router
enthusiastmartin Jul 14, 2023
b30874a
Merge branch 'master' into feat/stableswap-runtime
enthusiastmartin Jul 17, 2023
7577579
add stableswap to benchmark script
enthusiastmartin Jul 17, 2023
fcaf52e
Add stableswap to benchmark support
enthusiastmartin Jul 17, 2023
a80f64b
new weights
enthusiastmartin Jul 17, 2023
382a887
pallet weight
enthusiastmartin Jul 17, 2023
c03c2bf
add router benchmark for sell including stableswap
dmoka Jul 26, 2023
884d9e4
add router benchmark for buy including stableswap
dmoka Jul 26, 2023
b30582f
change the max number of trades to 3 in router as we benchmark only u…
dmoka Jul 27, 2023
7c8bc09
wip - temporary trades for subpool-omnipool-subpool
dmoka Jul 27, 2023
0de31a3
adjust router benchmarking according to the router params
dmoka Jul 28, 2023
3f39f23
add safety net for not supported router pools. These should fail when…
dmoka Jul 28, 2023
1085d1c
add integration tests for router
dmoka Jul 28, 2023
7175721
adjust todo comment and benchmark for router execution
dmoka Jul 28, 2023
3b42683
review comments
enthusiastmartin Jul 28, 2023
2d02d38
Merge branch 'master' into feat/stableswap-runtime
enthusiastmartin Jul 28, 2023
3cf4edf
Merge branch 'master' into feat/stableswap-runtime
enthusiastmartin Jul 31, 2023
3d2f6e8
fix dca runtime benchmarks build
enthusiastmartin Jul 31, 2023
14993a6
include stableswap in dca benchmark - WIP
dmoka Jul 31, 2023
8ac3dcf
Merge remote-tracking branch 'origin/feat/stableswap-runtime' into fe…
dmoka Jul 31, 2023
70332ba
adjust lock file
dmoka Jul 31, 2023
5ea72dd
make update balance compile
dmoka Jul 31, 2023
54172d3
make work of updating balance in benchmark
dmoka Jul 31, 2023
5f88def
add benchmarks for sell and buy omniswap
dmoka Aug 1, 2023
61cb9eb
extract calculate shares functionality
dmoka Aug 1, 2023
e43717c
fix warnings
dmoka Aug 1, 2023
69b86fe
Revert "extract calculate shares functionality"
dmoka Aug 1, 2023
efa7a8a
Revert "Revert "extract calculate shares functionality""
dmoka Aug 1, 2023
2bf4e21
WIP - add support for trading share tokens in the router
dmoka Aug 1, 2023
9ade4d7
add dca-stableswap support for getting share asset from stable
dmoka Aug 1, 2023
77a061d
duplicate the stableswap calculation functions in the router implemen…
dmoka Aug 2, 2023
6b5f62a
Revert "extract calculate shares functionality"
dmoka Aug 2, 2023
7d9a7ec
fix compilation error
dmoka Aug 2, 2023
7a1814f
add calculate shares for amount
enthusiastmartin Aug 2, 2023
c1064f2
WIP - add support for buying stableswap involving share asset
dmoka Aug 3, 2023
e28179d
Merge branch 'master' into feat/stableswap-runtime
enthusiastmartin Aug 9, 2023
c28b777
Merge branch 'master' into feat/stableswap-runtime-dca
enthusiastmartin Aug 17, 2023
b72b062
Merge branch 'fix/stableswap-precision' into feat/stableswap-runtime-dca
enthusiastmartin Aug 17, 2023
6265519
Merge remote-tracking branch 'origin/feat/stableswap-runtime' into fe…
dmoka Aug 21, 2023
876cec6
fix compilation error after having new changes with the addition of s…
dmoka Aug 21, 2023
0e9d96e
remove support of stableswap buy in the router
dmoka Aug 21, 2023
1f6f38c
refactoring
dmoka Aug 21, 2023
0b3abd7
remove warnings
dmoka Aug 21, 2023
4335cce
make benchmark test compule due to new precision changes in stableswap
dmoka Aug 21, 2023
109f18f
add missing dependency
dmoka Aug 21, 2023
66e0f45
use real asset registry in stableswap pallet so we can set decimals
dmoka Aug 22, 2023
d72e459
fix runtime router benchmark test
dmoka Aug 22, 2023
0f2b821
regenerate benchmarks locally for route executor
dmoka Aug 22, 2023
dcf7613
remove unnecessary comment
dmoka Aug 22, 2023
1b51408
adjust route executor test for stableswap to have the worst case
dmoka Aug 22, 2023
92f355a
merge fix/stableswap-precision to feat/stableswap-runtime-dca
dmoka Aug 30, 2023
5053ccd
wip - add back stableswap router buy support when asset in is share a…
dmoka Aug 30, 2023
8e74f53
use calculate shares method instead of math for buy shares calculation
dmoka Aug 30, 2023
7206dcb
WIP - use withdraw asset for buy stableswap reouter when asset in is …
dmoka Aug 30, 2023
8f41663
fix test assertion
dmoka Aug 30, 2023
f7f10cd
add back withdraw fee to make the test more realistic
dmoka Aug 30, 2023
9699a78
WIP - enable buy when asset out is share asset
dmoka Aug 30, 2023
cec98df
formatting
dmoka Aug 30, 2023
1ea25f7
renaming and cleaning up
dmoka Aug 30, 2023
a26030b
add test case for buying omnuipool token for stable
dmoka Aug 30, 2023
7fdd262
Add function to calc amount of asset to provide to obtain exact shares
enthusiastmartin Aug 30, 2023
1cecaf2
use new way to calculate add-one-asset-liquidty
dmoka Aug 30, 2023
408c152
return 1 share less in add liquidiuty
enthusiastmartin Aug 31, 2023
f5d3847
fixed failing tests due to off-by-one share adjustment
dmoka Sep 1, 2023
df331a3
fix router test assertion
dmoka Sep 1, 2023
3bad59f
add failing test for router having only one stableswap trade with ass…
dmoka Sep 1, 2023
766985f
wip - add buy stableswap benchmark - fails with off by one error
dmoka Sep 1, 2023
5fe3c71
Merge stableswap-precision to feat/stableswap-runtime-dca, now testin…
dmoka Sep 4, 2023
d442970
delete accidentally commited weight file
dmoka Sep 4, 2023
4e2ed8a
Merge stableswap-precision to feat/stableswap-runtime-dca
dmoka Sep 5, 2023
a95b199
make code compile and fix tests after the change of having only one f…
dmoka Sep 5, 2023
d5f9853
fix trade execution impl for stableswap as the fee is handled in math…
dmoka Sep 5, 2023
313225f
remove temporarly assertion
dmoka Sep 5, 2023
dcf8b49
regenerate router benchmarks
dmoka Sep 5, 2023
697b508
merge router tests
dmoka Sep 5, 2023
1bcb5fc
remove warnings
dmoka Sep 5, 2023
c67dfbb
make clippy happy
dmoka Sep 5, 2023
de1f2c7
formatting
dmoka Sep 5, 2023
d6c1046
merge master to feat/stableswap-runtime
dmoka Sep 5, 2023
a19e7f4
bump versions
dmoka Sep 5, 2023
fec6cab
update lock
dmoka Sep 6, 2023
d2f1725
remove todo as we wont do for now
dmoka Sep 6, 2023
b57ce14
merge fix/stableswap-precision to feat/stableswap-runtime
dmoka Sep 7, 2023
5ab004c
fix tests
dmoka Sep 7, 2023
5565be0
Merge branch 'master' into feat/stableswap-runtime
mrq1911 Sep 12, 2023
59eecf9
make clippy happy
dmoka Sep 12, 2023
2e0c535
Add missing weight functions
enthusiastmartin Sep 12, 2023
397ed4f
remove unused imports
enthusiastmartin Sep 12, 2023
81305f2
rollback changes in dca so it won't depend on stableswap and also we …
dmoka Sep 12, 2023
4a7c84d
remove unused decimals information
enthusiastmartin Sep 12, 2023
2579e76
reverted unnecesary changes
mrq1911 Sep 12, 2023
b12df9c
lock
mrq1911 Sep 12, 2023
1b625d6
reverted dca cargo
mrq1911 Sep 12, 2023
79bbaaf
reverted traits cargo
mrq1911 Sep 12, 2023
1eb1933
lock
mrq1911 Sep 12, 2023
acbe9ca
inlined
mrq1911 Sep 12, 2023
5be578e
Add stableswap benchmark helper
enthusiastmartin Sep 12, 2023
5bbb4fe
update stableswap weight
enthusiastmartin Sep 12, 2023
ed91623
happy clippy happy life
enthusiastmartin Sep 12, 2023
506fa20
bump versions
enthusiastmartin Sep 12, 2023
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
10 changes: 6 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion integration-tests/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "runtime-integration-tests"
version = "1.11.0"
version = "1.12.0"
description = "Integration tests"
authors = ["GalacticCouncil"]
edition = "2021"
Expand All @@ -19,6 +19,7 @@ pallet-omnipool = { workspace = true }
pallet-circuit-breaker = { workspace = true }
pallet-omnipool-liquidity-mining = { workspace = true }
pallet-bonds = { workspace = true }
pallet-stableswap = { workspace = true }

# Warehouse dependencies
pallet-asset-registry = { workspace = true }
Expand Down
1 change: 0 additions & 1 deletion integration-tests/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
mod bonds;
mod call_filter;
mod circuit_breaker;
mod cross_chain_transfer;
Expand Down
Loading
Loading