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

Workspace dependencies #68

Merged
merged 7 commits into from
Dec 20, 2023
Merged

Workspace dependencies #68

merged 7 commits into from
Dec 20, 2023

Conversation

4meta5
Copy link
Contributor

@4meta5 4meta5 commented Dec 19, 2023

Closes #44 by defining all dependencies once in a workspace Cargo.toml.

This improves developer experience for dependency upgrades in 2 ways:

  1. After this change, dependencies only need to be updated in one file (workspace Cargo.toml) instead of requiring the exact same changes to every Cargo.toml which contains the dependency.
  2. This ensures the same version of the same dependency are used within this workspace to ensure and enforce compatibility between the provided template node/runtime/pallet.

@4meta5 4meta5 added this to the 1st Deliverable MVP milestone Dec 19, 2023
@4meta5 4meta5 self-assigned this Dec 19, 2023
Copy link

netlify bot commented Dec 19, 2023

Deploy Preview for docs-oz-polkadot canceled.

Name Link
🔨 Latest commit a462b60
🔍 Latest deploy log https://app.netlify.com/sites/docs-oz-polkadot/deploys/658218a97d845a0008668329

@4meta5 4meta5 added the enhancement New feature or request label Dec 19, 2023
@4meta5 4meta5 marked this pull request as ready for review December 19, 2023 22:34
/// The wasm builder is deactivated when compiling
/// this crate for wasm to speed up the compilation.
#[cfg(not(feature = "std"))]
fn main() {}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you inform us on why this part is removed, and why it was not necessary?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The build.rs file is intended to compile the runtime in wasm. This code was preventing the correct compilation so I changed it to match every other runtime build.rs I've seen.

I've never seen this in any other substrate project. In the future, I'd suggest PRing the polkadot-sdk build.rs file before making changes like this in the future to get feedback and confirmation that it works as intended.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://github.com/paritytech/polkadot-sdk/blob/master/cumulus/parachain-template/runtime/build.rs

in case there was a misunderstanding, we didn't make any changes. This is from substrate

Copy link
Collaborator

@ozgunozerk ozgunozerk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good to me.

I have two questions above, but they are not blocking for this PR

@4meta5 4meta5 enabled auto-merge (squash) December 20, 2023 15:36
@4meta5 4meta5 merged commit b734abf into main Dec 20, 2023
5 checks passed
@4meta5 4meta5 deleted the amar-workspace-deps branch December 20, 2023 15:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: ✅ Done
Development

Successfully merging this pull request may close these issues.

Declare dependencies in workspace.dependencies
3 participants