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

ALL-2078 Update RPC response types #855

Merged
merged 3 commits into from
Jul 11, 2023

Conversation

oliverjantar
Copy link
Contributor

@oliverjantar oliverjantar commented Jul 10, 2023

Description

Change response types for all RPC calls to return unmodified data

Type of change

  • New feature (non-breaking change which adds functionality)

@TatumBot
Copy link

@oliverjantar oliverjantar force-pushed the feature/ALL-2078-rpc-responses branch 2 times, most recently from 4cd9528 to aceba83 Compare July 10, 2023 14:41
@oliverjantar oliverjantar marked this pull request as ready for review July 10, 2023 14:44
@oliverjantar oliverjantar requested a review from Smrecz July 10, 2023 14:44
@Smrecz
Copy link
Member

Smrecz commented Jul 11, 2023

Doesn't it have the same issue now, just with different wrapping object? I thought we'll be returning just the T from JsonRpcResponse or an error.

@samuelsramko
Copy link
Contributor

We should return the full JSON RPC response here - which means format like this
{ "id": number|string, "jsonrpc":number|string, "error"?: any "result"?: any }

@oliverjantar oliverjantar force-pushed the feature/ALL-2078-rpc-responses branch from aceba83 to 998aa23 Compare July 11, 2023 07:14
@oliverjantar
Copy link
Contributor Author

It is returning what @samuelsramko mentioned, apart from Xrp that returns the result as it is - it doesn't have the "id" or "jsonRpc" fields.

@Smrecz
Copy link
Member

Smrecz commented Jul 11, 2023

Ok, so this is not wrapper, it's a DTO to cast to, I see now

@oliverjantar oliverjantar merged commit a955c6a into master Jul 11, 2023
7 checks passed
@oliverjantar oliverjantar deleted the feature/ALL-2078-rpc-responses branch July 11, 2023 07:31
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.

4 participants