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

Add Adapter for RPC client #152

Merged
merged 9 commits into from
Nov 21, 2024
Merged

Conversation

joaop21
Copy link
Contributor

@joaop21 joaop21 commented Nov 18, 2024

Why:

There is an implicit coupling with ethereumex, which causes bad decisions to spread from ethereumex to elixir_ethers, which is not desirable at all.

How:

By implementing an adapter for Ethereumex that formats and transforms inputs so that they are digested correctly by ethereumex.

Resolves: #151

@alisinabh
Copy link
Member

Thank you @joaop21 this looks very good. I would rather to also be backwards compatible with fromBlock and toBlock so the updates will be effortless. If you don't have time to do that I can make the changes just let me know.

Thanks again.

lib/ethers/rpc_client/adapter.ex Outdated Show resolved Hide resolved
lib/ethers/rpc_client.ex Show resolved Hide resolved
@joaop21 joaop21 force-pushed the js/rpc-client-adapter branch from ed01dcf to c1a63d9 Compare November 19, 2024 15:41
@joaop21
Copy link
Contributor Author

joaop21 commented Nov 19, 2024

@alisinabh I think it's done on my side 👌

@alisinabh
Copy link
Member

Also according to tests, eth_send_transaction (and maybe some others) seem to be left out.

@alisinabh
Copy link
Member

Thank you for the contribution 💚 💜

@alisinabh alisinabh merged commit 5e62d9d into ExWeb3:main Nov 21, 2024
4 checks passed
@joaop21
Copy link
Contributor Author

joaop21 commented Nov 22, 2024

hey @alisinabh thank you for making the required changes 🚀

@joaop21 joaop21 deleted the js/rpc-client-adapter branch November 22, 2024 17:26
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.

Default to snake case in the Ethers.get_logs/2 overrides and options
2 participants