-
Notifications
You must be signed in to change notification settings - Fork 139
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
Bug: Parser's S3 event notifications schemas #2410
Comments
Hmm that's odd because the It would help to separate them and also narrow down the some of the field values to constants. Let me run some test events to see, I am a bit uncertain why the it happens "sometime" as stated in the original issue in PT python. |
Agree, the sometime is throwing me off as well. It would make more sense to me that the field is no longer there because the corresponding object has been removed, but the intermittent aspect is strange. |
I have decided to set the I need to think of possible scenarios how we could reproduce real event structures, because there is no other way yet to get them correct. |
This issue is now closed. Please be mindful that future comments are hard for our team to see. If you need more assistance, please either tag a team member or open a new issue that references this one. If you wish to keep having a conversation with other community members under this issue feel free to do so. |
This is now released under v2.1.1 version! |
Summary
Based on the finding in aws-powertools/powertools-lambda-python#4156 it appears that when S3 sends a notification for an object deleted and triggers a Lambda function, the
etag
field is optional.In looking at our implementation vs the types in
@types/aws-lambda
it seems that we have a singleS3EventNotificationEventBridgeDetailSchema
schema while DefinitelyTyped has multiple kinds, one for each notification type.I'm not sure if we should add schemas for each event type like DefinitelyTyped does or have a single one, however having multiple might help with addressing the subtle differences in field presence (i.e.
etag
not present in delete notifications) & values (i.e.deletion-type
equalsPermanently Deleted
).For now I'm opening this as a feature request, but if we decide to just make
etag
optional and keep the schema as-is, we can convert this as maintenance type.Why is this needed?
So that customers can use the schema to parse their events.
Which area does this relate to?
Parser
Solution
No response
Acknowledgment
Future readers
Please react with 👍 and your use case to help us understand customer demand.
The text was updated successfully, but these errors were encountered: