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

Remove vendor substrate #115

Merged
merged 7 commits into from
Sep 11, 2020

Conversation

xlc
Copy link
Contributor

@xlc xlc commented Sep 4, 2020

Closes #112

Using the same Substrate commit

Also fixed build issue on template runtime.

@xlc xlc changed the title Refactor substrate Remove vendor substrate Sep 4, 2020
@xlc
Copy link
Contributor Author

xlc commented Sep 4, 2020

I suspect I need to do similar changes to other two vendor repos to actually make this usable by other projects.

@crystalin
Copy link
Collaborator

The block import (including the clone part) is already done on this PR: #113

@drewstone
Copy link
Contributor

Can we also consider removing the evm submodule? It doesn't look like its used anywhere outside of pallet-evm and even then its not pegged to the submodule.

sc-consensus = { version = "0.8.0-dev", path = "../../vendor/substrate/client/consensus/common" }
sp-timestamp = { version = "2.0.0-dev", default-features = false, path = "../../vendor/substrate/primitives/timestamp" }
evm = { version = "2.0.0-dev", package = "pallet-evm", path = "../../vendor/substrate/frame/evm" }
sp-api = { version = "2.0.0-dev", git = "https://github.com/paritytech/substrate.git", rev = "8a35a14c2dd91bc5de77366f45a06fe45bdfd1d6" }
Copy link
Member

Choose a reason for hiding this comment

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

Maybe just branch = "master" and pin commit in Cargo.lock?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It will be hard to make sure the pinned version doesn't get updated when adding new deps

Copy link
Member

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 repo does use this strategy though. Another worry for me is how do we get this large amount of dependency pins updated each time.

Copy link
Contributor Author

@xlc xlc Sep 8, 2020

Choose a reason for hiding this comment

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

Global search & replace is easy enough.

Polkadot can constantly keep up to date because Substrate PR must have a companion Polkadot PR to fix the broken part. Unless frontier have same treatment, I don’t think pin to master branch is good idea.

Copy link
Collaborator

Choose a reason for hiding this comment

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

I agree with @sorpaas that updating the revision number is inconvenient, specially when switching from multiple remotes and versions during development.

Copy link
Contributor Author

@xlc xlc Sep 8, 2020

Choose a reason for hiding this comment

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

During development, you can use local version of substrate by updating your cargo config, see read me update in this PR

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I will prefer to pin to a branch instead of master, similar how cumulus is currently doing. But someone will need to setup that branch in Substrate first.

Copy link
Member

Choose a reason for hiding this comment

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

@xlc I created frontier branch in Substrate. Please update this PR to use that.

@xlc
Copy link
Contributor Author

xlc commented Sep 11, 2020

As Substrate is updated, I included #111 as well

@xlc xlc force-pushed the refactor-substrate branch from 5a6556e to 9963951 Compare September 11, 2020 09:13
@xlc xlc force-pushed the refactor-substrate branch from 9963951 to 6ed1bcb Compare September 11, 2020 09:14
@sorpaas sorpaas merged commit 4b700ee into polkadot-evm:master Sep 11, 2020
abhijeetbhagat pushed a commit to web3labs/frontier that referenced this pull request Jan 11, 2023
* remove Substrate as submodule, use git reference directly instead

* add instruction

* impl Clone for FrontierBlockImport

* remove evm as well

* use frontier branch

* update with latest master credits to @crystalin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use Substrate from crates.io or git
4 participants