Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing events to nomination pool extrinsincs #7377

Merged
merged 18 commits into from
Feb 4, 2025

Conversation

rockbmb
Copy link
Contributor

@rockbmb rockbmb commented Jan 29, 2025

Found via open-web3-stack/polkadot-ecosystem-tests#165.

Closes #7370 .

Description

Some extrinsics from pallet_nomination_pools were not emitting events:

  • set_configs
  • set_claim_permission
  • set_metadata
  • chill
  • nominate

Integration

N/A

Review Notes

N/A

@rockbmb rockbmb added T1-FRAME This PR/Issue is related to core FRAME, the framework. T2-pallets This PR/Issue is related to a particular pallet. labels Jan 29, 2025
@rockbmb rockbmb self-assigned this Jan 29, 2025
@rockbmb rockbmb marked this pull request as ready for review January 29, 2025 16:08
@rockbmb rockbmb requested a review from Ank4n January 29, 2025 16:11
Copy link
Contributor

@Ank4n Ank4n left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some nits but okay with this PR.

prdoc/pr_7377.prdoc Show resolved Hide resolved
/// A pool member's claim permission has been updated.
MemberClaimPermissionUpdated { member: T::AccountId, permission: ClaimPermission },
/// A pool's metadata was updated.
MetadataUpdated { pool_id: PoolId, caller: T::AccountId },
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is adding caller useful here? Nothing against it, just trying to understand the rationale. Same for other events.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the case of set_metadata, both the pool's root and its bouncer can make that call - this is to disambiguate which did it, in case the two roles are performed by different accounts.

The same goes for the other calls: nominate/chill can be called by the pool's root/nominator.

substrate/frame/nomination-pools/src/lib.rs Outdated Show resolved Hide resolved
substrate/frame/nomination-pools/src/lib.rs Outdated Show resolved Hide resolved
substrate/frame/nomination-pools/src/lib.rs Outdated Show resolved Hide resolved
substrate/frame/nomination-pools/src/lib.rs Outdated Show resolved Hide resolved
substrate/frame/nomination-pools/src/lib.rs Outdated Show resolved Hide resolved
substrate/frame/nomination-pools/src/lib.rs Outdated Show resolved Hide resolved
substrate/frame/nomination-pools/src/lib.rs Outdated Show resolved Hide resolved
substrate/frame/nomination-pools/src/lib.rs Outdated Show resolved Hide resolved
@rockbmb rockbmb requested a review from kianenigma February 3, 2025 19:14
@rockbmb rockbmb enabled auto-merge February 4, 2025 12:29
@paritytech-workflow-stopper
Copy link

All GitHub workflows were cancelled due to failure one of the required jobs.
Failed workflow url: https://github.com/paritytech/polkadot-sdk/actions/runs/13137016060
Failed job name: test-linux-stable-no-try-runtime

@rockbmb rockbmb added this pull request to the merge queue Feb 4, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Feb 4, 2025
@rockbmb rockbmb added this pull request to the merge queue Feb 4, 2025
Merged via the queue into master with commit a883475 Feb 4, 2025
204 of 207 checks passed
@rockbmb rockbmb deleted the nom-pools-missing-events branch February 4, 2025 16:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T1-FRAME This PR/Issue is related to core FRAME, the framework. T2-pallets This PR/Issue is related to a particular pallet.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Extrinsics in nomination pool pallet are missing events
3 participants