Skip to content
This repository has been archived by the owner on Jan 13, 2025. It is now read-only.

Support RPC filters in web3.js #18256

Closed
tomjohn1028 opened this issue Jun 28, 2021 · 1 comment · Fixed by #18257
Closed

Support RPC filters in web3.js #18256

tomjohn1028 opened this issue Jun 28, 2021 · 1 comment · Fixed by #18257

Comments

@tomjohn1028
Copy link
Contributor

Problem

I'm looking to subscribe to a program via the web3.js Connection.onProgramAccountChange, but I'd like to use the optional filter that comes with the underlying RPC programSubscribe request.

Proposed Solution

Update the build arguments of a subscription to include optional filters argument. As of writing the _buildArgs method seems to only take in a programId and commitment. It seems like it could be easily passed in to the extra argument of the buildArgs.

  1. Update onProgramAccountChange to include optional filters in the subscription object
  2. update program subscription builder (here) to pass in the filters as the extra arg
@github-actions
Copy link
Contributor

github-actions bot commented Apr 2, 2022

This issue has been automatically locked since there has not been any activity in past 7 days after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Apr 2, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant