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

Fix ChainWithMessages::WeightInfo with correct values according to BridgeHub parachains #1640

Closed
Tracked by #1706 ...
bkontur opened this issue Nov 14, 2022 · 3 comments · Fixed by #1899
Closed
Tracked by #1706 ...

Comments

@bkontur
Copy link
Contributor

bkontur commented Nov 14, 2022

From Slava PR comment:

WeightInfo is used to compute message delivery transaction limits. I think it is fine to use () for initial estimations (relay leaves some reserve anyway && () weights are probably larger than actual weights), but later we'll need to use weights from the parachains.

@svyatonik
Copy link
Contributor

Just an idea for the future: maybe use something like this - https://github.com/ggwpez/substrate-weight-compare - and then just compare on upgrade

@svyatonik
Copy link
Contributor

Just got an idea when writing an answer - weights are used to compute maximal number of messages and their dispatch weight in delivery transaction. Maybe we should just provide CLI options for "foreign" chains for that? I.e. for Rialto/Millau we'll still have auto-computations and for RBH/WBH we'll have to use cli options like --max-messages-in-delivery-transaction 1024 --max-dispatch-weight-in-delivery-transaction "(866_600_106_667, 2_271_915)".

And maybe the best alternative for now is just to choose safe values for those limits and hardcode it somewhere in primitives. E.g. to call select_delivery_transaction_limits using RBH/WBH weights, div result by two and use it in RBH<>WBH bridge.

My first idea was that we should check/handle it in some way in this runtime-upgrade-helper-tool that we'll have somedeay I hope.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants