Files
pezkuwi-subxt/prdoc/pr_3636.prdoc
T
Dónal Murray aa35328371 [pallet_broker] Fix adapt_price behaviour at zero (#3636)
This fixes the behaviour of `Linear` which is the default implementation
of the `AdaptPrice` trait in the broker pallet. Previously if cores were
offered but not sold in only one sale, the price would be set to zero
and due to the logic being purely multiplicative, the price would stay
at 0 indefinitely.

This could be further paired with a configurable minimum in the broker
pallet itself, which will be a future PR.

This affects the Rococo and Westend Coretime chains, but Kusama has a
different implementation so this isn't required for the Kusama launch. I
actually thought I opened this a while ago.

---------

Co-authored-by: Bastian Köcher <git@kchr.de>
2024-03-11 14:12:27 +00:00

16 lines
635 B
Plaintext

# Schema: Polkadot SDK PRDoc Schema (prdoc) v1.0.0
# See doc at https://raw.githubusercontent.com/paritytech/polkadot-sdk/master/prdoc/schema_user.json
title: "[pallet_broker] Fix `Linear::adapt_price` behavior at zero"
doc:
- audience: Runtime Dev
description: |
This fixes the behaviour of `Linear` which is the default implementation of the `AdaptPrice`
trait in the broker pallet. Previously if cores were offered but not sold in only one sale,
the price would be set to zero and due to the logic being purely multiplicative, the price
would stay at 0 indefinitely.
crates:
- name: pallet-broker