You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
expressionBuilder is referenced putParams (as parseConditions in Entity.js:755). It returns an empty values object by default, which is later assigned to ExpressionAttributeValues.
So exists and other functions will result in the EmptyExpressionAttributeValues error you see. My relatively primitive workaround replaces Entity.js:795 with
…lbox#51)
When only using conditions like {attr: 'id', exists: true}
there aren't any attribute values created but the option is still passed.
The DynamoDB api sees this as a ValidationException.
Thanks @RavyuS and @Nemo62. The pull request only fixed put, but the same issue was possible with the delete method as well. I've added a fix that puts an isEmpty function in the utils and then uses that to check the parameters when they are assembled. Thanks for everyone's input on this!
Writing something like:
Results in an
ExpressionAttributeValues: {}
, which AWS rejects.Workaround is to add:
delete params.ExpressionAttributeValues;
If you know they're empty.
The text was updated successfully, but these errors were encountered: