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

Connectors v0.1.0 #1160

Merged
merged 55 commits into from
Feb 16, 2023
Merged

Connectors v0.1.0 #1160

merged 55 commits into from
Feb 16, 2023

Conversation

NunoAlexandre
Copy link
Contributor

@NunoAlexandre NunoAlexandre commented Jan 5, 2023

Connectors v1

The latest revision of this PR has been tested on the Moonbase Alpha testnet and has passed all the tests where all the connectors messages (AddPool, AddTranche, UpdateMember, UpdateTokenPrice, and Transfer) were successfully sent from the Centrifuge development runtime through XCM to Moonbase, where they were forwarded through ethereum_xcm to the Moonbase EVM down to our ConnectorXcmRouter smart contract.

The changes which close the v1 are:

  1. Several fixes in the encoding of messages, where numbers need to be encoded as big-endian to be correctly decoded on the Solidity side
  2. Redesign of the Domain and DomainAddress types to best map the mental model we have for connectors
  3. Add price field to the AddTranche message with the latest tranche price
  4. More++ unit and integration tests (the latter for covering all the setup requirements needed to send the respective messages)

To Do

  • Add initial_price to Message::AddTranche (Connectors v1 liquidity-pools#16 (comment))
  • Fix transfer message encoding test
  • Set gas_limit to max or have user pass it down when submitting a call
  • Fix/Test update_member derivation of DomainAddress
  • Test all messages' requirements

@NunoAlexandre NunoAlexandre self-assigned this Jan 5, 2023
@NunoAlexandre NunoAlexandre marked this pull request as draft January 5, 2023 15:36
Copy link
Contributor Author

@NunoAlexandre NunoAlexandre left a comment

Choose a reason for hiding this comment

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

Some notes for the reviewers

pallets/connectors/src/lib.rs Show resolved Hide resolved
pallets/connectors/src/lib.rs Outdated Show resolved Hide resolved
Domain only needs ConnectorEncode and let's drop Decode since it's not
needed for now.
@NunoAlexandre NunoAlexandre marked this pull request as ready for review February 13, 2023 15:55
lemunozm
lemunozm previously approved these changes Feb 14, 2023
Copy link
Contributor

@lemunozm lemunozm left a comment

Choose a reason for hiding this comment

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

LGTM! I left some minor comments

pallets/connectors/src/lib.rs Show resolved Hide resolved
pallets/connectors/src/message.rs Outdated Show resolved Hide resolved
Copy link
Contributor

@wischli wischli left a comment

Choose a reason for hiding this comment

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

LGTM! I have a few minor comments

pallets/connectors/src/lib.rs Show resolved Hide resolved
pallets/connectors/src/lib.rs Show resolved Hide resolved
pallets/connectors/src/lib.rs Show resolved Hide resolved
pallets/connectors/src/message.rs Outdated Show resolved Hide resolved
pallets/connectors/src/message.rs Outdated Show resolved Hide resolved
Copy link
Contributor

@wischli wischli left a comment

Choose a reason for hiding this comment

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

LGTM!

@NunoAlexandre NunoAlexandre merged commit 186a9d3 into main Feb 16, 2023
@NunoAlexandre NunoAlexandre deleted the connectors-v0.1.0 branch February 16, 2023 16:41
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.

None yet

4 participants