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

dmp: Check that the para exist before delivering a message #6604

Open
wants to merge 15 commits into
base: master
Choose a base branch
from

Conversation

bkchr
Copy link
Member

@bkchr bkchr commented Nov 21, 2024

No description provided.

@bkchr bkchr added the T8-polkadot This PR/Issue is related to/affects the Polkadot network. label Nov 21, 2024
@bkchr
Copy link
Member Author

bkchr commented Nov 29, 2024

/cmd prdoc --audience runtime_dev --bump patch

prdoc/pr_6604.prdoc Outdated Show resolved Hide resolved
@bkontur
Copy link
Contributor

bkontur commented Nov 29, 2024

for those failed rococo/westend benchmarks, for ToParachainDeliveryHelper e.g. here adding some EnsureForParachain implementation which does that paras::Heads::<Runtime>::insert(p, HeadData(p.encode().into())); should fix it (this is needed just for relaychains, which does dmp)

@bkontur
Copy link
Contributor

bkontur commented Nov 29, 2024

there is also one place: https://github.com/paritytech/polkadot-sdk/blob/master/polkadot/runtime/parachains/src/hrmp.rs#L1886-L1898, I am not sure if this new Unroutable could happen in this place, maybe we could change that e.g.:

                // try to enqueue
		if let Err(error) =
			dmp::Pallet::<T>::queue_downward_message(&config, dest, notification_bytes)
		{
			// this should never happen unless the max downward message size is configured to a
			// jokingly small number or para is not registered/active.
			log::error!(
				target: "runtime::hrmp",
				"sending '{log_label}::notification_bytes' failed with error: {error:?}."
			);
			debug_assert!(false);
		}

@bkontur
Copy link
Contributor

bkontur commented Nov 30, 2024

for those failed rococo/westend benchmarks, for ToParachainDeliveryHelper e.g. here adding some EnsureForParachain implementation which does that paras::Heads::<Runtime>::insert(p, HeadData(p.encode().into())); should fix it (this is needed just for relaychains, which does dmp)

let me fix this for you

@bkchr
Copy link
Member Author

bkchr commented Nov 30, 2024

let me fix this for you

I already have it fixed locally :) Just need to fix more :D

@bkchr bkchr requested a review from a team as a code owner November 30, 2024 21:47
@bkontur
Copy link
Contributor

bkontur commented Nov 30, 2024

let me fix this for you

I already have it fixed locally :) Just need to fix more :D

:D :D nice, so at least please consider one small clean-up of my older code: #6714

@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/12099962839
Failed job name: run-frame-omni-bencher

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T8-polkadot This PR/Issue is related to/affects the Polkadot network.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants