-
Notifications
You must be signed in to change notification settings - Fork 799
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
Use defaultConfig for pallet_contracts #1817
Conversation
* functions to benchmark messages pallet with linked to parachain * unused imports * fmt
@pgherveou Are we good to proceed here? Any blockers? |
Kind of forgot about it, will bring it up to date :) |
just merge conflicts, will re-go through the different types to pick sensible defaults |
The CI pipeline was cancelled due to failure one of the required jobs. |
cc @gupnik how does that look now? |
substrate/frame/contracts/mock-network/src/parachain/contracts_config.rs
Show resolved
Hide resolved
substrate/frame/contracts/src/lib.rs
Outdated
pub trait Config: frame_system::Config { | ||
/// The time implementation used to supply timestamps to contracts through `seal_now`. | ||
#[pallet::no_default] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not possible to provide a default here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah you would most likely want to override it, if you do anything that use that type in your tests, but I can provide an implementation that is unimplented!
type ChainExtension: chain_extension::ChainExtension<Self> + Default; | ||
|
||
/// Cost schedule and limits. | ||
#[pallet::constant] | ||
#[pallet::no_default] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tried with no_default_bounds
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -326,6 +339,7 @@ pub mod pallet { | |||
/// | |||
/// This setting along with [`MaxCodeLen`](#associatedtype.MaxCodeLen) directly affects | |||
/// memory usage of your runtime. | |||
#[pallet::no_default] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same, the trait is generic over T
No description provided.