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

Include expiration entry on ledger entries in getContractData/getLedgerEntries responses #161

Merged
merged 11 commits into from
Oct 12, 2023

Conversation

sreuland
Copy link
Contributor

This is a client-side approach to eagerly fetching the ledger entry expiration info(ExpirationEntry) automatically for any LedgerDataEntry requested through getLedgerEntries and getContractData, and then it embeds the ExpirationEntry found as expiration on each response item built from the LedgerDataEntry.

it's meant as interim solution until stellar/stellar-cli#1010 modifes the rpc server to include expiration entry info by default on ledger data entries in rpc responses.

Closes #153

@sreuland sreuland requested a review from Shaptic October 10, 2023 06:28
Copy link
Contributor

@Shaptic Shaptic left a comment

Choose a reason for hiding this comment

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

quick first-pass review, looks pretty good but hoping we can simplify this? great test coverage to kick it off though 👏

src/server.ts Outdated Show resolved Hide resolved
src/server.ts Outdated Show resolved Hide resolved
src/server.ts Outdated Show resolved Hide resolved
src/server.ts Outdated Show resolved Hide resolved
src/soroban_rpc.ts Outdated Show resolved Hide resolved
test/unit/server/get_ledger_entries_test.js Outdated Show resolved Hide resolved
test/unit/server/get_ledger_entries_test.js Show resolved Hide resolved
src/parsers.ts Outdated Show resolved Hide resolved
src/server.ts Outdated Show resolved Hide resolved
src/server.ts Outdated Show resolved Hide resolved
package.json Outdated Show resolved Hide resolved
@sreuland
Copy link
Contributor Author

quick first-pass review, looks pretty good but hoping we can simplify this? great test coverage to kick it off though 👏

@Shaptic , I've responded to feedback, all commits in, lmk, thanks!

@sreuland sreuland requested a review from Shaptic October 10, 2023 21:35
Copy link
Contributor

@Shaptic Shaptic left a comment

Choose a reason for hiding this comment

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

getting close, some minor comments and a few Qs about the parsing logic

package.json Outdated Show resolved Hide resolved
CHANGELOG.md Show resolved Hide resolved
src/server.ts Outdated Show resolved Hide resolved
src/server.ts Outdated Show resolved Hide resolved
src/server.ts Outdated Show resolved Hide resolved
src/soroban_rpc.ts Outdated Show resolved Hide resolved
src/soroban_rpc.ts Outdated Show resolved Hide resolved
test/unit/server/get_ledger_entries_test.js Show resolved Hide resolved
src/server.ts Outdated Show resolved Hide resolved
@sreuland sreuland requested a review from Shaptic October 11, 2023 21:38
Copy link
Contributor

@Shaptic Shaptic left a comment

Choose a reason for hiding this comment

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

awesome work and great test coverage 👏

@sreuland sreuland merged commit 4fe4c30 into stellar:main Oct 12, 2023
4 checks passed
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.

Add ability to get expiration information
2 participants