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

Fix for xcm-emulator - Wrong Parachain processing message #2800

Merged
merged 3 commits into from
Jul 2, 2023

Conversation

NachoPal
Copy link
Contributor

@NachoPal NachoPal commented Jun 30, 2023

I found out that the condition to process messages by a Parachain is incomplete.

We did not notice because of the coincidence that for all our tests, the destination Parachain that is supposed to receive/process the message, had been declared always before the other Parachains.

Example of failing case:
We send a message to PenpalPolkadot. The message will never reach its destination because AssetHubPolkadot will try to process it first as it is a message to the same Network AssetHubPolkadot and PenpalPolkadot live.

		parachains = vec![
			AssetHubPolkadot,
			PenpalPolkadot,
		],

Same test would pass just switching Parachains order declarations.

		parachains = vec![
			PenpalPolkadot,
			AssetHubPolkadot,
		],

Solution: filter also by para_id and not only by Network.

@NachoPal NachoPal added B0-silent Changes should not be mentioned in any release notes T7-system_parachains This PR/Issue is related to System Parachains. A0-please_review Pull request needs code review. C1-low PR touches the given topic and has a low impact on builders. labels Jun 30, 2023
@NachoPal
Copy link
Contributor Author

NachoPal commented Jul 2, 2023

bot merge

@paritytech-processbot paritytech-processbot bot merged commit d978452 into master Jul 2, 2023
@paritytech-processbot paritytech-processbot bot deleted the nacho/fix-xcm-emulator branch July 2, 2023 09:35
NachoPal added a commit that referenced this pull request Jul 3, 2023
* fix

* forgot para_id

* remove unreachable code
NachoPal added a commit that referenced this pull request Jul 3, 2023
* fix

* forgot para_id

* remove unreachable code
paritytech-processbot bot pushed a commit that referenced this pull request Jul 3, 2023
* Xcm Emulator: prepare XCMP on init (#2711)

* std for pallet-glutton

* fix xcm-emulator init

* headers for it tests

* Fix for `xcm-emulator` - Wrong Parachain processing message (#2800)

* fix

* forgot para_id

* remove unreachable code

* remove glutton dep

---------

Co-authored-by: Muharem Ismailov <ismailov.m.h@gmail.com>
paritytech-processbot bot pushed a commit that referenced this pull request Jul 3, 2023
* Xcm Emulator: prepare XCMP on init (#2711)

* std for pallet-glutton

* fix xcm-emulator init

* headers for it tests

* remove glutton dep

* Fix for `xcm-emulator` - Wrong Parachain processing message (#2800)

* fix

* forgot para_id

* remove unreachable code

---------

Co-authored-by: Muharem Ismailov <ismailov.m.h@gmail.com>
girazoki pushed a commit to moondance-labs/cumulus that referenced this pull request Aug 11, 2023
…ritytech#2810)

* Xcm Emulator: prepare XCMP on init (paritytech#2711)

* std for pallet-glutton

* fix xcm-emulator init

* headers for it tests

* remove glutton dep

* Fix for `xcm-emulator` - Wrong Parachain processing message (paritytech#2800)

* fix

* forgot para_id

* remove unreachable code

---------

Co-authored-by: Muharem Ismailov <ismailov.m.h@gmail.com>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A0-please_review Pull request needs code review. B0-silent Changes should not be mentioned in any release notes C1-low PR touches the given topic and has a low impact on builders. T7-system_parachains This PR/Issue is related to System Parachains.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants