mirror of
https://github.com/datahaven-xyz/datahaven
synced 2026-05-24 09:50:01 +00:00
## Summary - guard `DataHavenServiceManager.submitRewards` by `(startTimestamp, duration, token)` so each reward window can only be submitted once per token - expose the replay-guard state and error in the interface, add Foundry coverage, wire the missing runtime `std` features, and regenerate the Wagmi/storage/state-diff artifacts - fix the local slash E2E path by aligning the `anvil` Snowbridge `messageOrigin` with `stagenet-local`, refreshing the tracked anvil deployment metadata, and waiting for `ServiceManager.SlashingComplete` ## Testing - `cargo fmt --all -- --check` - `forge test --match-contract RewardsSubmitterTest` - `forge test --match-contract StorageLayoutTest -vvv` - `./scripts/check-storage-layout.sh` - `./scripts/check-storage-layout-negative.sh` - `bun ./scripts/check-generated-state.ts` - `bun generate:wagmi` - `bun test ./e2e/suites/slash.test.ts --timeout 1200000 --test-name-pattern "verify we have the agent origin set|Activate slashing|use sudo to slash operator"` ## Notes - Slash E2E verification reran the previously failing sudo slash path; the long liveness scenario was not rerun end to end.
73 lines
2 KiB
TOML
73 lines
2 KiB
TOML
[package]
|
|
name = "pallet-external-validator-slashes"
|
|
authors = { workspace = true }
|
|
description = "External validator info slashes"
|
|
edition = "2021"
|
|
license = "GPL-3.0-only"
|
|
version = "0.1.0"
|
|
|
|
[package.metadata.docs.rs]
|
|
targets = ["x86_64-unknown-linux-gnu"]
|
|
|
|
[lints]
|
|
workspace = true
|
|
|
|
[dependencies]
|
|
frame-benchmarking = { workspace = true, optional = true }
|
|
frame-support = { workspace = true }
|
|
frame-system = { workspace = true }
|
|
log = { workspace = true }
|
|
pallet-session = { workspace = true }
|
|
parity-scale-codec = { workspace = true, features = ["derive", "max-encoded-len"] }
|
|
scale-info = { workspace = true }
|
|
snowbridge-core = { workspace = true }
|
|
snowbridge-outbound-queue-primitives = { workspace = true }
|
|
sp-core = { workspace = true }
|
|
sp-runtime = { workspace = true }
|
|
pallet-external-validators = { workspace = true }
|
|
sp-staking = { workspace = true }
|
|
serde = { features = ["alloc", "derive"], workspace = true }
|
|
|
|
[dev-dependencies]
|
|
pallet-timestamp = { workspace = true, features = ["std"] }
|
|
fp-account = { workspace = true, features = ["serde"] }
|
|
sp-io = { workspace = true }
|
|
|
|
[features]
|
|
default = ["std"]
|
|
std = [
|
|
"frame-benchmarking/std",
|
|
"frame-support/std",
|
|
"frame-system/std",
|
|
"log/std",
|
|
"pallet-session/std",
|
|
"pallet-timestamp/std",
|
|
"parity-scale-codec/std",
|
|
"pallet-external-validators/std",
|
|
"scale-info/std",
|
|
"serde/std",
|
|
"snowbridge-core/std",
|
|
"snowbridge-outbound-queue-primitives/std",
|
|
"sp-core/std",
|
|
"sp-io/std",
|
|
"sp-runtime/std",
|
|
"sp-staking/std",
|
|
]
|
|
runtime-benchmarks = [
|
|
"frame-benchmarking/runtime-benchmarks",
|
|
"frame-support/runtime-benchmarks",
|
|
"frame-system/runtime-benchmarks",
|
|
"pallet-timestamp/runtime-benchmarks",
|
|
"pallet-external-validators/runtime-benchmarks",
|
|
"snowbridge-core/runtime-benchmarks",
|
|
"sp-runtime/runtime-benchmarks",
|
|
"sp-staking/runtime-benchmarks",
|
|
]
|
|
|
|
try-runtime = [
|
|
"frame-support/try-runtime",
|
|
"frame-system/try-runtime",
|
|
"pallet-session/try-runtime",
|
|
"pallet-timestamp/try-runtime",
|
|
"sp-runtime/try-runtime",
|
|
]
|