-
Notifications
You must be signed in to change notification settings - Fork 33
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
[Utility] trustless relay e2e happy case (POC PR) #869
Open
adshmh
wants to merge
21
commits into
main
Choose a base branch
from
feat-trustless-relay-e2e-happy-case
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 15 commits
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
4a0530e
e2e v0 for trustless relay
adshmh 9bbc842
e2e test passing for ETH relaychain account balance
adshmh 8704b69
Parameterized e2e happy case for trustless relays
adshmh ef8eda4
Add a servicer config to LocalNet
adshmh 1f2e143
Address review comment
adshmh aee6009
Address review comment
adshmh 40d9964
Address review comment
adshmh 6df0ef2
Address review comment
adshmh e88fb2e
Address review comment
adshmh 027a69c
Address review comment
adshmh 00990a6
Address review comment
adshmh 14fd3f2
Address review comment
adshmh 6d6a383
Address review comments
adshmh bfe7ac5
Address review comment
adshmh f41039b
Address review comments
adshmh ed740db
Fix syntax error
adshmh fbb4c8f
remove ADD_IN_THIS_PR for updating all RPC ports
adshmh dea5b4d
Merge main
adshmh a48dc0d
Address IN_THIS_PR
adshmh 3c46849
Verify id and jsonrpc fields in e2e response
adshmh 0822a08
Add sad e2e test case: relay timeout
adshmh 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
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,14 @@ | ||
# - This is an override of the shared config: <https://github.com/pokt-network/pocket/blob/40f325305c1756bbfd069bf139fa67545419981c/charts/pocket/values.yaml#L116C12-L117> | ||
# - This is a reference of how we can utilize Helm to configure the service | ||
# - Configs can also be overrident without an explicit config file: https://github.com/pokt-network/pocket/blob/main/build/localnet/Tiltfile#L216 | ||
# - Settings specific to a single instance of the servicer, e.g. public key and address, are a good fit for this file | ||
config: | ||
adshmh marked this conversation as resolved.
Show resolved
Hide resolved
|
||
servicer: | ||
enabled: true | ||
# The address and public_key fields are taken from the genesis section of the config file: | ||
# https://github.com/pokt-network/pocket/blob/40f325305c1756bbfd069bf139fa67545419981c/build/localnet/manifests/configs.yaml#L1699 | ||
address: "001022b138896c4c5466ac86b24a9bbe249905c2" | ||
public_key: "56915c1270bc8d9280a633e0be51647f62388a851318381614877ef2ed84a495" | ||
adshmh marked this conversation as resolved.
Show resolved
Hide resolved
|
||
services: | ||
"0001": | ||
url: "https://eth-mainnet.gateway.pokt.network" | ||
adshmh marked this conversation as resolved.
Show resolved
Hide resolved
|
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,18 @@ | ||
Feature: Trustless Relays | ||
Olshansk marked this conversation as resolved.
Show resolved
Hide resolved
|
||
# Happy test case: An Application requests the account balance of a specific address at a specific height from a Servicer staked for the Ethereum RelayChain, and receives a successful response. | ||
|
||
# ADD_IN_THIS_PR: Add a servicer staked for the Ethereum relaychain to the genesis file | ||
Scenario: Application can send a trustless relay to a relaychain to get an account's balance at a specific height | ||
Given the application has a valid ethereum relaychain account | ||
Given the application has a valid ethereum relaychain height | ||
Given the application has a valid servicer | ||
adshmh marked this conversation as resolved.
Show resolved
Hide resolved
|
||
# INCOMPLETE: GeoZone | ||
When the application sends a get balance relay at a specific height to an Ethereum Servicer | ||
# Balance: 1,160,126.46817237178258965 ETH = 0xf5aa94f49d4fd1f8dcd2 | ||
Then the relay response contains 0xf5aa94f49d4fd1f8dcd2 | ||
# TECHDEBT: replace validator with client | ||
And the validator should have exited without error | ||
adshmh marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
# ADD_IN_THIS_PR: Sad test case: An Application requests the account balance of a specific address at a specific height from a Servicer staked for the Ethereum RelayChain in the same GeoZone, and the request times out without a response. | ||
|
||
# TODO: add an E2E test for a trustless relay, where the application retrieves the session first, using a new fetch session command |
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
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.
why did we update the port?
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.
Port
50832
is the configured RPC port, so42069
seems incorrect (encountered this while running the E2E test introduced in this PR)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 think we should update all the RPC ports then to avoid a discrepancy:
If you want to do it in a small separate PR (while this one is being reviewed), I support 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.
Is the intention to do it in this PR (given the comment)?
I still think a different small "micro PR" could be simpler & faster
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.
Yes, I will open a separate, small PR for this shortly.