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

Query Limit is Stringified: Serialization Error (v0.8.1) #502

Closed
SethO opened this issue Apr 11, 2023 · 1 comment · Fixed by #503
Closed

Query Limit is Stringified: Serialization Error (v0.8.1) #502

SethO opened this issue Apr 11, 2023 · 1 comment · Fixed by #503

Comments

@SethO
Copy link
Contributor

SethO commented Apr 11, 2023

In both queryParams and scanParams, the code is incorrectly stringifying limit. As is, with all default configurations, the code throws "SerializationException: STRING_VALUE cannot be converted to Integer".

These are links to the two lines in Table.ts:

limit ? { Limit: String(limit) } : null,

limit ? { Limit: String(limit) } : null,

I believe the fix is as simple as just changing limit ? { Limit: String(limit) } : null to limit ? { Limit: limit } : null and adjusting the expectations in table.query.unit.test.ts and table.scan.unit.test.ts

@naorpeled
Copy link
Collaborator

Hey @SethO,
thanks so much for reporting this!

Merged the fix into main,
btw sorry for not co-authoring you on yesterday's fix, forgot 😢

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 a pull request may close this issue.

2 participants