Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Preimage requested twice for Referenda approved via Democracy #13534

Closed
2 tasks done
bernardo-xxnet opened this issue Mar 3, 2023 · 1 comment · Fixed by #13827
Closed
2 tasks done

Preimage requested twice for Referenda approved via Democracy #13534

bernardo-xxnet opened this issue Mar 3, 2023 · 1 comment · Fixed by #13827

Comments

@bernardo-xxnet
Copy link
Contributor

bernardo-xxnet commented Mar 3, 2023

Is there an existing issue?

  • I have searched the existing issues

Experiencing problems? Have you tried our Stack Exchange first?

  • This is not a support question.

Description of bug

When a Referendum is approved in the Democracy pallet, the preimage is held (requested) before the Scheduler is called.

T::Preimages::hold(&status.proposal);

The changes in #13340 make the Scheduler request a preimage for the call being scheduled.
This results in the preimage for any referendum passing via Democracy being requested twice.

When the Scheduled call runs, the preimage is unrequested only once, leaving a pending request for that preimage forever onchain.

This change is included in the latest release polkadot-v0.9.39.

I believe that the solution to this issue could be to not request the preimage in the Democracy pallet anymore, since the call to Scheduler will request it anyways.

Steps to reproduce

Run the dev network on Substrate branch polkadot-v0.9.3 and pass a proposal via Democracy.
After the proposal passes and is executed by the Scheduler, the preimage remains requested.

@bkchr
Copy link
Member

bkchr commented Mar 4, 2023

Ty for the report! Good find!

bkchr added a commit that referenced this issue Apr 5, 2023
The requesting of the proposal is actually done now in `pallet-scheduler`.

Fixes: #13534
bkchr added a commit that referenced this issue Apr 25, 2023
The requesting of the proposal is actually done now in `pallet-scheduler`.

Fixes: #13534
gpestana pushed a commit that referenced this issue May 4, 2023
The requesting of the proposal is actually done now in `pallet-scheduler`.

Fixes: #13534
nathanwhit pushed a commit to nathanwhit/substrate that referenced this issue Jul 19, 2023
…tech#13827)

The requesting of the proposal is actually done now in `pallet-scheduler`.

Fixes: paritytech#13534
taqtiqa-mark pushed a commit to subversive-upstream/polkadot-sdk-substrate-frame-democracy that referenced this issue Sep 14, 2023
The requesting of the proposal is actually done now in `pallet-scheduler`.

Fixes: paritytech/substrate#13534
taqtiqa-mark pushed a commit to subversive-upstream/polkadot-sdk-substrate-frame-support that referenced this issue Sep 14, 2023
The requesting of the proposal is actually done now in `pallet-scheduler`.

Fixes: paritytech/substrate#13534
bernardo-xxnet pushed a commit to xx-labs/substrate that referenced this issue Jun 12, 2024
…tech#13827)

The requesting of the proposal is actually done now in `pallet-scheduler`.

Fixes: paritytech#13534
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants