-
Notifications
You must be signed in to change notification settings - Fork 746
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 umbrella crate for minimal template #5155
Merged
kianenigma
merged 59 commits into
master
from
pg/use-umbrella-crate-for-minimal-template
Aug 28, 2024
Merged
Changes from 50 commits
Commits
Show all changes
59 commits
Select commit
Hold shift + click to select a range
275b4d3
Use umbrella crate for minimal template
pgherveou 6630adc
Add missing cargo changes
pgherveou 93d6364
format cargo.toml with taplo
pgherveou 694294d
Update cargo.toml formatting (2)
pgherveou a7c49f0
remove minimal/Cargo.toml
pgherveou b6d704d
Update cargo.toml
pgherveou 64910cf
Add experimental feature flag
pgherveou 1ef3029
Fix minimal template pallet::config check
pgherveou 59167aa
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
pgherveou d96d3b2
a few fixes from kian
kianenigma 4341776
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
kianenigma 8cea3d8
fix toml
kianenigma 122d3f2
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
kianenigma ce2238c
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
kianenigma 0cdcdcf
Merge branch 'master' of github.com:paritytech/polkadot-sdk into pg/u…
kianenigma 472c7d9
fix and prdoc
kianenigma 24d5e5c
Merge branch 'pg/use-umbrella-crate-for-minimal-template' of github.c…
kianenigma 903ab6f
Merge branch 'master' of github.com:paritytech/polkadot-sdk into pg/u…
kianenigma 4a4e46a
docs
kianenigma 53fa677
fix feature
kianenigma 24cf78c
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
kianenigma e9cbcb3
Test fix CI clippy job
pgherveou 525abf6
Tweak experimental flag for tests
pgherveou 4a60415
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
pgherveou 9b71984
Fix clippy
pgherveou ea08cc2
Fix clippy 2
pgherveou 4867813
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
pgherveou 9f60b3a
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
kianenigma 9867d6b
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
kianenigma 3e5f624
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
kianenigma 6a9ad9e
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
pgherveou 3f88968
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
kianenigma 09fd0a5
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
kianenigma 055ee73
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
kianenigma 9076909
use no-default-features for anyhow
pgherveou e987766
taplo fix
pgherveou 0f5e103
fix revive
pgherveou 6093140
Do not add pallet-contracts when arch = riscv
pgherveou 5d270ac
fixed anyhow dep
pgherveou 3ede08d
Fix prdoc
pgherveou 69968aa
Patch generate-umbrella for crate that do not support riscv
pgherveou 7b1d5e6
Add missing pallet prdoc complains about
pgherveou bb7f6f9
add missing :
pgherveou 2829fc5
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
kianenigma 3bc01aa
fix fmt
pgherveou 69d998e
fix missing default features
pgherveou f87dd47
Revert "fix missing default features"
pgherveou 1dc603d
Update Cargo.toml
pgherveou 5928b87
fixes
pgherveou f6c0d2b
fix
pgherveou 4f4256a
Rollback changes and update polkadot-sdk feature flags
pgherveou 6c3f759
Update substrate/frame/revive/src/wasm/runtime.rs
pgherveou 6fc20c3
rollback package.metadata.polkadot-sdk changes
pgherveou 4677583
use runtime-full instead of runtime
pgherveou 7031a43
Update umbrella
pgherveou 80f4dd0
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
kianenigma 5eff776
Update features runtime
pgherveou bb30654
Merge branch 'master' into pg/use-umbrella-crate-for-minimal-template
pgherveou fac0344
Update Cargo.lock
pgherveou File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# Schema: Polkadot SDK PRDoc Schema (prdoc) v1.0.0 | ||
# See doc at https://raw.githubusercontent.com/paritytech/polkadot-sdk/master/prdoc/schema_user.json | ||
|
||
title: Use umbrella crate for minimal template | ||
|
||
doc: | ||
- audience: Runtime Dev | ||
description: | | ||
Minor additions to the `polkadot-sdk-frame` crate and making it ready for usage in more templates. This PR already integrates it in the minimal template. | ||
|
||
|
||
crates: | ||
- name: polkadot-sdk | ||
bump: patch | ||
- name: polkadot-sdk-frame | ||
bump: patch | ||
- name: sp-wasm-interface | ||
bump: patch | ||
- name: pallet-revive | ||
bump: patch | ||
- name: pallet-revive-fixtures | ||
bump: patch | ||
- name: frame-support | ||
bump: patch | ||
- name: pallet-balances | ||
bump: patch | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. note to self: maybe this can be rolled back as well |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
Merge error? This shouldn't be necessary?
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.
Curious. I guess due to the difference in toolchain version then.
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.
so it does now when we build
because it pulls the umbrella crate that tries to build all the crates deps including pallet-revive to riscv.
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.
@kianenigma that explains why we are seeing all these compilations errors here and not in other PRs.
We could pick only the features we need in the Cargo.toml if we want to avoid that ...
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.
Hm, yea only selecting the needed dependencies should work.
It's a bit annoying though, since the umbrella crate is supposed to make things easier. I guess it is still easier than selecting each dependency version manually.
Would it be possible to feature-gate the RISCV compilation?
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.
I gated the pallets that were causing issue, the long term solution is probably to generate the umbrella trait with feature flags that declare all their dependencies, so that you can hand pick the one you need and optimize your build time
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.
Couldn't we encode the dependency graph into the features in the script? Like you only activate the pallets you want and then they automatically activate the other pallets they depend on.
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.
I would not support making the usage of umbrella crate in any of the templates sub-optimal, for the sake of
SUBSTRATE_RUNTIME_TARGET=riscv
which is more of an experimental thing.All people out there will not face the same compilation issue, and people do use these templates as a source of truth, so it should be in the simplest form possible.