-
Notifications
You must be signed in to change notification settings - Fork 573
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
Overloading confusion on marshall
#6253
Comments
Could you make a reproduction repository of this? I don't get a compiler error with the example. |
export declare function marshall(data: Map<string, NativeAttributeValue> | Record<string, NativeAttributeValue>, options?: marshallOptions): Record<string, AttributeValue>; which matches the type of |
Your result is definitely what I was expecting. I wonder if my
|
My test works with that tsconfig too, so you'll have to provide a reproduction sample repository. |
I'm seeing this issue as well, though I don't have a concise reproduction handy. I believe the cause is this change: https://github.com/aws/aws-sdk-js-v3/pull/6195/files#diff-5cb8b8aa06642c3dd60ce3fd1ebdcd54c5258b790d3956fb1b6ade503b00654cL42 |
Should be fixed in today's release by PR #6261. The expected version is https://github.com/aws/aws-sdk-js-v3/releases/tag/v3.614.0. |
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. |
Checkboxes for prior research
Describe the bug
Starting with
3.598.0
when callingmarshall
on a variable typed as a simple object, the following error is reported:NOTE: the problem only occurs when using a typed variable. Having a literal object as the param directly still works fine. Also, the problem does NOT occur in
3.596.0
or before.SDK version number
@aws-sdk/package-name@version, ...
Which JavaScript Runtime is this issue in?
Node.js
Details of the browser/Node.js/ReactNative version
v18.18.2
"typescript": "^5.5.3"
Reproduction Steps
Try to compile this file, marshallTest.ts:
Observed Behavior
above error occurred
Expected Behavior
no error should occur
Possible Solution
probably something to do with the order of type declarations (it appears reordering has already been attempted several times)
Additional Information/Context
No response
The text was updated successfully, but these errors were encountered: