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

feat(graphql): Filter by affected address #19365

Merged
merged 7 commits into from
Sep 18, 2024
Merged

feat(graphql): Filter by affected address #19365

merged 7 commits into from
Sep 18, 2024

Conversation

amnn
Copy link
Contributor

@amnn amnn commented Sep 13, 2024

Description

Add TransactionBlockFilter.affectedAddress as a way to filter transactions by their relationship to an address without worrying about what kind of relationship that is.

Test plan

New E2E tests:

cargo nextest run -p sui-graphql-e2e-tests --features staging -- affected_address.move

Stack


Release notes

Check each box that your changes affect. If none of the boxes relate to your changes, release notes aren't required.

For each box you select, include information after the relevant heading that describes the impact of your changes that a user might notice and any actions they must take to implement updates.

  • Protocol:
  • Nodes (Validators and Full nodes):
  • Indexer:
  • JSON-RPC:
  • GraphQL:
  • CLI:
  • Rust SDK:
  • REST API:

Copy link

vercel bot commented Sep 13, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
sui-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Sep 18, 2024 1:56pm
3 Skipped Deployments
Name Status Preview Comments Updated (UTC)
multisig-toolkit ⬜️ Ignored (Inspect) Visit Preview Sep 18, 2024 1:56pm
sui-kiosk ⬜️ Ignored (Inspect) Visit Preview Sep 18, 2024 1:56pm
sui-typescript-docs ⬜️ Ignored (Inspect) Visit Preview Sep 18, 2024 1:56pm

Copy link
Contributor

@wlmyng wlmyng left a comment

Choose a reason for hiding this comment

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

We have some logic around the interaction between tx_kind and signer. Would that apply for affected address as well?

Comment on lines 105 to 106
/// If we don't query a lookup table that has a denormalized sender column, we need to
/// explicitly sp
/// explicitly specify the sender.
Copy link
Contributor

Choose a reason for hiding this comment

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

even though this was my comment, it took me some time to wrap my head around this. I recall now that explicit_sender is called when constructing the subqueries to determine whether to explicitly add a subquery against tx_senders

Base automatically changed from amnn/gql-docs to main September 13, 2024 18:36
@amnn
Copy link
Contributor Author

amnn commented Sep 13, 2024

We have some logic around the interaction between tx_kind and signer. Would that apply for affected address as well?

No, it does not -- tx_affected_addresses is conceptually closest to tx_recipients, not tx_sender.

@amnn amnn changed the base branch from amnn/tx-affected-ci to amnn/txn-test-sponsor September 16, 2024 20:24
@amnn amnn force-pushed the amnn/txn-test-sponsor branch 2 times, most recently from ee46926 to fd5b1a3 Compare September 17, 2024 18:16
Base automatically changed from amnn/txn-test-sponsor to main September 17, 2024 18:43
## Description

Add `TransactionBlockFilter.affectedAddress` as a way to filter
transactions by their relationship to an address without worrying about
what kind of relationship that is.

## Test plan

TBD
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@lxfind -- the first staging test.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

(not completed)

@amnn amnn merged commit 4f57565 into main Sep 18, 2024
49 of 50 checks passed
@amnn amnn deleted the amnn/tx-affected-gql branch September 18, 2024 15:59
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.

2 participants