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

fix(util-dynamodb): fix signature overload resolution for marshall() fn #6195

Merged
merged 2 commits into from
Jun 13, 2024

Conversation

kuhe
Copy link
Contributor

@kuhe kuhe commented Jun 13, 2024

Issue

fixes #4828

this re-attempts #4829 (reverted)

reported issue causing the revert #4901. I don't think this was valid in retrospect, we reverted hastily.

Description

Fix overload signature resolution for marshall(), with tests this time.

Testing

type-checked unit tests

  • ran lib dynamodb e2e

@kuhe kuhe requested a review from a team as a code owner June 13, 2024 18:05
data: Map<string, NativeAttributeValue> | Record<string, NativeAttributeValue>,
options?: marshallOptions
): Record<string, AttributeValue>;
export function marshall(data: any, options?: marshallOptions): any;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

added this any => any signature to prevent inputs typed as any from matching to some other signature.

@kuhe kuhe merged commit 3682a43 into aws:main Jun 13, 2024
5 checks passed
@kuhe kuhe deleted the fix/dynamodb-types branch June 13, 2024 20:20
Copy link

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.

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

Successfully merging this pull request may close these issues.

[util-dynamodb] marshall overload signatures are broken due to more general overload matching first
2 participants