Skip to content

Commit

Permalink
WIP update to 0.39.0
Browse files Browse the repository at this point in the history
  • Loading branch information
magecnion committed Nov 19, 2024
1 parent 59ab462 commit f27853b
Show file tree
Hide file tree
Showing 36 changed files with 23,311 additions and 2,851 deletions.
21 changes: 21 additions & 0 deletions Cargo.lock

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

44 changes: 44 additions & 0 deletions pallets/parachain-staking-old/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
[package]
name = "pallet-parachain-staking-old"
authors = { workspace = true }
description = "parachain staking pallet for collator selection and reward distribution"
edition = "2021"
version = "3.0.0"

[dependencies]
log = { workspace = true }
serde = { workspace = true }

# Substrate
frame-benchmarking = { workspace = true, optional = true }
frame-support = { workspace = true }
frame-system = { workspace = true }
parity-scale-codec = { workspace = true, features = [ "derive" ] }
scale-info = { workspace = true, features = [ "derive" ] }
sp-consensus-slots = { workspace = true }
sp-runtime = { workspace = true }
sp-std = { workspace = true }
substrate-fixed = { workspace = true }

[dev-dependencies]
pallet-balances = { workspace = true, features = [ "insecure_zero_ed", "std" ] }
similar-asserts = { workspace = true }
sp-core = { workspace = true, features = [ "std" ] }
sp-io = { workspace = true, features = [ "std" ] }
sp-runtime = { workspace = true }
test-utils = { workspace = true }

[features]
default = [ "std" ]
std = [
"frame-benchmarking?/std",
"frame-support/std",
"frame-system/std",
"parity-scale-codec/std",
"scale-info/std",
"sp-consensus-slots/std",
"sp-runtime/std",
"sp-std/std",
]
runtime-benchmarks = [ "frame-benchmarking" ]
try-runtime = [ "frame-support/try-runtime" ]
28 changes: 28 additions & 0 deletions pallets/parachain-staking-old/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# DPoS Pallet for Parachain Staking

This pallet is forked from [`moonbeam v0.36.0`](https://github.com/moonbeam-foundation/moonbeam/tree/v0.36.0/pallets/parachain-staking), commit hash `d1087f3091726ffbe14b44655d848d00a1f14201`.

## Formatting Rules

- dependencies in alphabetical order in the `Cargo.toml` and at the top of each file
- prefer explicit imports to glob import syntax i.e. prefer `use::crate::{Ex1, Ex2, ..};` to `use super::*;`

## Description

Implements Delegated Proof of Stake to

1. select the active set of eligible block producers
2. reward block authors
3. enable delegators and collators to participate in inflationary rewards

Links:

- [Rust Documentation](https://moonbeam-foundation.github.io/moonbeam/pallet_parachain_staking/index.html)
- [Unofficial Documentation](https://meta5.world/parachain-staking-docs/)
- [(Outdated) Blog Post with Justification](https://meta5.world/posts/parachain-staking)

## History

Since January 2021, Moonbeam's team has maintained this Delegated Proof of Stake (DPoS) pallet designed specifically for parachains.

Since April 2021, the development of this pallet has been supported by [a Web3 Foundation grant](https://github.com/w3f/Grants-Program/pull/389). The [first milestone](https://github.com/w3f/Grant-Milestone-Delivery/pull/218) was approved in June 2021.
1 change: 1 addition & 0 deletions pallets/parachain-staking-old/migrations.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Migration History
Loading

0 comments on commit f27853b

Please sign in to comment.