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

Moves precompile-utils into frontier (#2181) #2427

Closed
wants to merge 6 commits into from

Conversation

rimbi
Copy link
Contributor

@rimbi rimbi commented Aug 8, 2023

What does it do?

Moves precompile-utils from moonbeam into frontier.

  • Moves the following crates to frontier repo:
    • precompile-utils
    • precompile-utils-macro
    • precompile-utils-tests-external
  • Extracts the XCM related part of the precompile-utils into a separate crate called precompile-utils-xcm-codec and leaves it in moonbeam.

Here is the complementary PR: moonbeam-foundation/frontier#177

What important points reviewers should know?

Is there something left for follow-up PRs?

What alternative implementations were considered?

Are there relevant PRs or issues in other repositories (Substrate, Polkadot, Frontier, Cumulus)?

What value does it bring to the blockchain users?

@rimbi rimbi added A0-pleasereview Pull request needs code review. B3-apinoteworthy Changes should be mentioned in the release notes of the next minor version release. C1-low Does not elevate a release containing this beyond "low priority". B0-silent Changes should not be mentioned in any release notes labels Aug 8, 2023
@rimbi rimbi self-assigned this Aug 9, 2023
@rimbi rimbi changed the title Moves precompile-utils into frontier Moves precompile-utils into frontier (#2181) Aug 9, 2023
@@ -733,45 +733,42 @@ fn read_complex_solidity_function() {
#[test]
fn junctions_decoder_works() {
let writer_output = Writer::new()
.write(Junctions::X1(Junction::OnlyChild))
.write(XCMJunctions(Junctions::X1(Junction::OnlyChild)))
Copy link
Contributor

Choose a reason for hiding this comment

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

Small grumble: Following Rust naming conventions it should be XcmJunctions.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

done, thanks! 👍

Cargo.lock Outdated
@@ -2971,7 +2941,7 @@ dependencies = [
"fc-rpc-core",
"fc-storage",
"fp-ethereum",
"fp-evm",
"fp-evm 3.0.0-dev (git+https://github.com/moonbeam-foundation/frontier?branch=moonbeam-polkadot-v0.9.43)",
Copy link
Collaborator

Choose a reason for hiding this comment

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

Theses kind of lines reveals that you have a problem of git dependencies duplication, please fix it

Copy link
Contributor Author

Choose a reason for hiding this comment

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

removed

@librelois
Copy link
Collaborator

librelois commented Aug 11, 2023

@rimbi Can you please fix the conflicts with master? this is needed for the CI to run.

@librelois librelois added the D5-nicetohaveaudit⚠️ PR contains trivial changes to logic that should be properly reviewed. label Aug 11, 2023
@github-actions
Copy link
Contributor

Coverage generated "Fri Aug 11 13:34:36 UTC 2023":
https://d3ifz9vhxc2wtb.cloudfront.net/pulls/2427/html/index.html

Master coverage: 87.39%
Pull coverage:

@crystalin
Copy link
Collaborator

@rimbi If this is ready for review, please move it from draft to PR

@@ -876,7 +876,7 @@ fn transfer_multi_assets_is_not_sorted_error() {
PCall::transfer_multi_assets {
assets: assets.into(),
fee_item: 0,
destination: destination.clone(),
destination: destination.clone().into(),
Copy link
Contributor

Choose a reason for hiding this comment

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

There are a lot of changes like this (adding a .into() call), do you know why?

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 reason is that I had to use new type pattern for the types like MultiLocation here.

Copy link
Contributor

Choose a reason for hiding this comment

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

Oh, is this because Codec is no longer defined in the same crate? Hmmm...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Exactly

@rimbi
Copy link
Contributor Author

rimbi commented Aug 16, 2023

@rimbi If this is ready for review, please move it from draft to PR

@crystalin It will be ready for review only after:

  • the changes in parity/frontier merge
  • and then the changes are reflected to our frontier repo

This PR and the corresponding one in our frontier repo was used to show that the changes work.

@crystalin
Copy link
Collaborator

Pleease move the PR to "ready for review" and merge master into it, thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A0-pleasereview Pull request needs code review. B0-silent Changes should not be mentioned in any release notes B3-apinoteworthy Changes should be mentioned in the release notes of the next minor version release. C1-low Does not elevate a release containing this beyond "low priority". D5-nicetohaveaudit⚠️ PR contains trivial changes to logic that should be properly reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants