Skip to content

Commit

Permalink
Merge develop-v0.5.4 into main (#1351)
Browse files Browse the repository at this point in the history
* Remove structs mentioned under TODO(#986) (#1342)

* Remove structs under TODO(#968)

* Remove OldOutcomeInfo and related structs

* Satisfy check-license

* Include buy/sell hybrid-router calls in proxy filters (#1343)

* Include buy/sell calls in proxy filters

* Add hybrid-router calls to HandleAssets

---------

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>

* Remove zrml-liquidity-mining (#1341)

* Remove zrml-liquidity-mining

* Fix formatting

* Fix copyright notices

* Remove zrml-liquidity-mining from benchmarks script

---------

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>

* Update style guide (#1339)

* Be more strict with feature branch size

* Clarify our workflow

* Fix formatting

---------

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>

* Revert "New Asset System (#1295)" (#1338)

* Revert "New Asset System (#1295)"

This reverts commit a956877.

* Fix formatting

* Update copyright

* Remove pallet-assets dependency

* Fix fuzz tests

* Remove zrml-rikiddo (#1340)

* Remove zrml-rikiddo

* Remove zrml-rikiddo from README

* Remove remnants of zrml-rikiddo

* Add note to changelog

* Remove Rikiddo constants from fuzz script

* Remove code owners

---------

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>

* Remove zrml-simple-disputes and migrate markets (#1344)

* Remove zrml-simple-disputes and migrate markets

* Fix formatting

* Minor improvement

* Fix redundant match guard

* Remove unused pallet constant

* Fix formatting

* Merge `main` into `develop` (#1345)

* Update dependencies to Polkadot v1.1.0 (#1331)

* Update dependencies (#1319)

* Update dependencies to polkadot-v1.1.0

* Format code

* Remove duplicate dependencies

* Update zrml-asset-router (#1321)

* Update zrml-primitives

* Partially update asset-router

* Finalize logic adjustments in asset-router

* Make asset-router tests compilable

* Correct Inspect routing for market assets in Currencies

* Directly invoke Inspect API for Currencies

* Add tests for remaining Unbalances functions

* Update remaining Zeitgeist pallets (#1322)

* Update zrml-asset-router (#1321)

* Upgrade zrml-market-commons

* Upgrade zrml-authorized && use MockBlock instead of MockBlockU32

* Upgrade zrml-court

* Upgrade zrml-global-disputes

* Upgrade liquidity mining

* Upgrade zrml-rikiddo

* Upgrade zrml-simple-disputes

* Upgrade zrml-styx

* Upgrade zrml-orderbook

* Upgrade zrml-parimutuel

* Upgrade zrml-swaps

* Upgrade zrml-prediction-markets

* Upgrade zrml-neo-swaps

* Upgrade zrml-hybrid-router

* Update license headers

* Update runtime (#1323)

* Update weight files & Runtime enum

* Use workspace metadata

* Always use serde serialization for asset types

* Make battery station standalone runtime compilable

* Make benchmark and try-runtime feature compilable

* Make BS build with all features

* Make parachain tests compile

* Partially fix xcm tests

* Use safe xcm version 2

* Update Zeitgeist runtime (except xcm tests)

* Format code

* Remove deprecated comment

* Integrate new xcm-emulator (#1324)

* Integrate new xcm-emulator environment

* Utilize new xcm-emulator interfaces

* Spawn relay-para network using patched xcm-emulator

* Use proper collator genesis config

* Fix Rococo tests

* Finalize Battery Station XCM tests

* Finalize Zeitgeist XCM tests

* Update client (#1327)

* Fix rpc and work on client update

* Finalize standalone client

* Update parachain client

* Use same try-runtime subcommand in every case

* Update node/src/cli.rs

Co-authored-by: Malte Kliemann <mail@maltekliemann.com>

* Update try-runtime* Makefile targets

---------

Co-authored-by: Malte Kliemann <mail@maltekliemann.com>

* Make CI succeed and add migrations (#1329)

* Fix rpc and work on client update

* Finalize standalone client

* Update parachain client

* Use same try-runtime subcommand in every case

* Satisfy Clippy

* Fix benchmarks

* Add migrations

* Satisfy Clippy

* Update moonkit depedencies

* Free disk space more aggressively

---------

Co-authored-by: Malte Kliemann <mail@maltekliemann.com>

* Update spec version, try-runtime Makefile

* Fix copyright notices

* Fix broken chain state (#1336)

* Add `StorageVersion` fix and contrats fix migrations

* Don't set pallet-balances' storage version

* Remove migrations from pallet-contracts config

* Clear storage tries of contracts

* Fix migration and info logs in try-runtime

* Fix licenses and comments

* Fix formatting

---------

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>

---------

Co-authored-by: Harald Heckmann <mail@haraldheckmann.de>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>

* Merge

* Fix benchmark

* Fix compiler error

* Fix tests and imports

* Fix imports (again...)

* Fix orderbook benchmarks

* Fix fuzz tests

* Fix formatting

* Fix orderbook fuzz

---------

Co-authored-by: Harald Heckmann <mail@haraldheckmann.de>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>

* Merge develop into develop-v0.5.4

* Update versions to v0.5.3

---------

Co-authored-by: Nikhil Saboo <36529278+saboonikhil@users.noreply.github.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Co-authored-by: Harald Heckmann <mail@haraldheckmann.de>
  • Loading branch information
4 people authored Aug 12, 2024
1 parent 838d67f commit 6133ceb
Show file tree
Hide file tree
Showing 106 changed files with 536 additions and 8,653 deletions.
2 changes: 0 additions & 2 deletions CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@
/zrml/orderbook/ @Chralt98
/zrml/parimutuel/ @Chralt98
/zrml/prediction-markets/ @maltekliemann
/zrml/rikiddo/ @sea212
/zrml/simple-disputes/ @Chralt98
/zrml/styx/ @yornaath
/zrml/swaps/ @maltekliemann

Expand Down
92 changes: 0 additions & 92 deletions Cargo.lock

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

12 changes: 0 additions & 12 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,12 @@ default-members = [
"zrml/court",
"zrml/hybrid-router",
"zrml/global-disputes",
"zrml/liquidity-mining",
"zrml/market-commons",
"zrml/neo-swaps",
"zrml/orderbook",
"zrml/parimutuel",
"zrml/prediction-markets",
"zrml/prediction-markets/runtime-api",
"zrml/rikiddo",
"zrml/simple-disputes",
"zrml/swaps",
"zrml/swaps/rpc",
"zrml/swaps/runtime-api",
Expand All @@ -42,7 +39,6 @@ members = [
"zrml/court",
"zrml/hybrid-router",
"zrml/global-disputes",
"zrml/liquidity-mining",
"zrml/market-commons",
"zrml/neo-swaps",
"zrml/orderbook",
Expand All @@ -51,9 +47,6 @@ members = [
"zrml/prediction-markets",
"zrml/prediction-markets/fuzz",
"zrml/prediction-markets/runtime-api",
"zrml/rikiddo",
"zrml/rikiddo/fuzz",
"zrml/simple-disputes",
"zrml/swaps",
"zrml/swaps/fuzz",
"zrml/swaps/rpc",
Expand Down Expand Up @@ -219,7 +212,6 @@ sp-session = { git = "https://github.com/paritytech/polkadot-sdk", branch = "rel
sp-std = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.1.0", default-features = false }
sp-transaction-pool = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.1.0", default-features = false }
sp-version = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.1.0", default-features = false }
substrate-fixed = { git = "https://github.com/encointer/substrate-fixed", default-features = false }

# Polkadot / XCM (client)
polkadot-cli = { git = "https://github.com/paritytech/polkadot-sdk", branch = "release-polkadot-v1.1.0" }
Expand All @@ -244,7 +236,6 @@ xcm-executor = { package = "staging-xcm-executor", git = "https://github.com/par
battery-station-runtime = { path = "runtime/battery-station" }
zeitgeist-runtime = { path = "runtime/zeitgeist" }
zrml-prediction-markets-fuzz = { path = "zrml/prediction-markets/fuzz" }
zrml-rikiddo-fuzz = { path = "zrml/rikkido/fuzz" }
zrml-swaps-fuzz = { path = "zrml/swaps/fuzz" }
zrml-swaps-rpc = { path = "zrml/swaps/rpc" }

Expand All @@ -256,15 +247,12 @@ zrml-authorized = { path = "zrml/authorized", default-features = false }
zrml-court = { path = "zrml/court", default-features = false }
zrml-global-disputes = { path = "zrml/global-disputes", default-features = false }
zrml-hybrid-router = { path = "zrml/hybrid-router", default-features = false }
zrml-liquidity-mining = { path = "zrml/liquidity-mining", default-features = false }
zrml-market-commons = { path = "zrml/market-commons", default-features = false }
zrml-neo-swaps = { path = "zrml/neo-swaps", default-features = false }
zrml-orderbook = { path = "zrml/orderbook", default-features = false }
zrml-parimutuel = { path = "zrml/parimutuel", default-features = false }
zrml-prediction-markets = { path = "zrml/prediction-markets", default-features = false }
zrml-prediction-markets-runtime-api = { path = "zrml/prediction-markets/runtime-api", default-features = false }
zrml-rikiddo = { path = "zrml/rikiddo", default-features = false }
zrml-simple-disputes = { path = "zrml/simple-disputes", default-features = false }
zrml-styx = { path = "zrml/styx", default-features = false }
zrml-swaps = { path = "zrml/swaps", default-features = false }
zrml-swaps-runtime-api = { path = "zrml/swaps/runtime-api", default-features = false }
Expand Down
4 changes: 0 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,6 @@ decentralized court.
user to create pools, provide liquidity or swap assets.
- [primitives](./zrml/primitives) - Contains custom and common types, traits and
constants.
- [rikiddo](./zrml/rikiddo) - The module contains a completely modular
implementation of our novel market maker [Rikiddo][rikiddo]. It also offers a
pallet that other pallets can use to utilize the Rikiddo market maker. Rikiddo
can be used by the automated market maker to determine swap prices.

## How to Build and Run a Zeitgeist Node

Expand Down
7 changes: 4 additions & 3 deletions docs/STYLE_GUIDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,10 +138,11 @@ duplicating documentation.

- Merges require one review. Additional reviews may be requested.
- Every merge into a feature branch requires a review.
- Feature branches are merged into `develop`, which is merged into
`release-vX.Y.Z` branches when we're publishing a release.
- Aim for at most 500 LOC added per PR. Only exceed 1,000 LOC lines added in a
PR in exceptional circumstances. Plan ahead and break a large PR into smaller
PRs targeting a feature branch. Feature branches are exempt from this rule.
- Reviews take priority over most other tasks.
PRs.
- Reviewing a PR should not take longer than two business days. Aim for shorter
PRs if the changes are complex.
- A PR should not be in flight (going from first `s:ready-for-review` to
Expand All @@ -163,7 +164,7 @@ duplicating documentation.
// In code logic
zeitgeist_macros::unreachable_non_terminating!(condition, log_target, message)
```

```rust
// In test
#[test]
Expand Down
5 changes: 5 additions & 0 deletions docs/changelog_for_devs.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ As of 0.3.9, the changelog's format is based on
components which query the chain's storage, the extrinsics or the runtime
APIs/RPC interface.

## v0.5.4

- ⚠️ Remove zrml-liquidity-mining from code base.
- ⚠️ Remove zrml-rikiddo from the code base.

## v0.5.2

[#1310]: https://github.com/zeitgeistpm/zeitgeist/pull/1310
Expand Down
1 change: 0 additions & 1 deletion node/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,6 @@ url = { workspace = true }
battery-station-runtime = { workspace = true, optional = true }
zeitgeist-primitives = { workspace = true, features = ["default"] }
zeitgeist-runtime = { workspace = true, optional = true }
zrml-liquidity-mining = { workspace = true, features = ["default"] }
zrml-swaps-rpc = { workspace = true }

[features]
Expand Down
8 changes: 1 addition & 7 deletions node/src/chain_spec/battery_station.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,7 @@ use battery_station_runtime::parameters::SS58Prefix;
use hex_literal::hex;
use sc_service::ChainType;
use sp_core::crypto::UncheckedInto;
use zeitgeist_primitives::{
constants::{
ztg::{LIQUIDITY_MINING, LIQUIDITY_MINING_PTD},
BASE,
},
types::AccountId,
};
use zeitgeist_primitives::{constants::BASE, types::AccountId};

#[cfg(feature = "parachain")]
use {
Expand Down
5 changes: 1 addition & 4 deletions node/src/chain_spec/dev.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,7 @@ use battery_station_runtime::{
};
use sc_service::ChainType;
use sp_core::sr25519;
use zeitgeist_primitives::{
constants::ztg::{LIQUIDITY_MINING, LIQUIDITY_MINING_PTD},
types::Balance,
};
use zeitgeist_primitives::types::Balance;
#[cfg(feature = "parachain")]
use {
super::battery_station::inflation_config,
Expand Down
4 changes: 0 additions & 4 deletions node/src/chain_spec/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -150,10 +150,6 @@ macro_rules! generate_generic_genesis_function {
authorities: acs.initial_authorities.iter().map(|x| (x.1.clone(), 1)).collect(),
..Default::default()
},
liquidity_mining: $runtime::LiquidityMiningConfig {
initial_balance: LIQUIDITY_MINING,
per_block_distribution: LIQUIDITY_MINING_PTD.mul_ceil(LIQUIDITY_MINING),
},
#[cfg(feature = "parachain")]
parachain_info: $runtime::ParachainInfoConfig {
parachain_id: acs.parachain_id,
Expand Down
2 changes: 0 additions & 2 deletions node/src/chain_spec/zeitgeist.rs
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@ use sc_service::ChainType;
use sp_core::crypto::UncheckedInto;
use zeitgeist_runtime::parameters::SS58Prefix;

use zeitgeist_primitives::constants::ztg::{LIQUIDITY_MINING, LIQUIDITY_MINING_PTD};

#[cfg(feature = "parachain")]
use {
super::{generate_inflation_config_function, Extensions},
Expand Down
5 changes: 1 addition & 4 deletions primitives/src/constants.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ pub const fn deposit(items: u32, bytes: u32) -> Balance {
items as Balance * 150 * CENT + (bytes as Balance) * 75 * MICRO
}

// Rikiddo and TokensConfig
parameter_types! {
// Returns the number of decimals used on chain.
pub const BalanceFractionalDecimals: u8 = {
let mut base = BASE;
let mut counter: u8 = 0;
Expand Down Expand Up @@ -114,9 +114,6 @@ pub const MAX_ORACLE_DURATION: BlockNumber = 14 * BLOCKS_PER_DAY;
/// Pallet identifier, mainly used for named balance reserves.
pub const PM_PALLET_ID: PalletId = PalletId(*b"zge/pred");

// Simple Disputes
pub const SD_PALLET_ID: PalletId = PalletId(*b"zge/sedp");

// Swaps
/// Max. assets in a swap pool.
pub const MAX_ASSETS: u16 = MAX_CATEGORIES + 1;
Expand Down
Loading

0 comments on commit 6133ceb

Please sign in to comment.