Skip to content

fix(parser): ddb base schema + other exports #3741

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

Merged
merged 5 commits into from
Mar 19, 2025
Merged

Conversation

dreamorosi
Copy link
Contributor

Summary

Changes

Please provide a summary of what's being changed

This PR fixes the missing export discussed in the linked issue and also takes the opportunity to review the overall structure of the Parser exports to simplify it and provide a better IDE experience for customers.

While doing so, I also updated the structure of the files within the package to more closely align with the exports, which allows us to use star exports more effectively (i.e. @aws-lambda-powertools/parser/schemas/<module-name>). This required some import changes, mainly in tests, which made the diff big.

Finally, I also reviewed all the example snippets and made sure they all use scoped sub-path exports rather than the barrel file export. This way customers copying the snippet from the code will have a smaller bundle size, since they'll be importing only the schemas/envelopes that they're actually using rather than all of them. This also increased the diff considerably.

Please add the issue number below, if no issue is present the PR might get blocked and not be reviewed

Issue number: fixes #3740


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Disclaimer: We value your time and bandwidth. As such, any pull requests created on non-triaged issues might not be successful.

@dreamorosi dreamorosi self-assigned this Mar 19, 2025
@boring-cyborg boring-cyborg bot added dependencies Changes that touch dependencies, e.g. Dependabot, etc. documentation Improvements or additions to documentation parser This item relates to the Parser Utility tests PRs that add or change tests labels Mar 19, 2025
@pull-request-size pull-request-size bot added the size/L PRs between 100-499 LOC label Mar 19, 2025
@dreamorosi dreamorosi requested a review from am29d March 19, 2025 12:47
@github-actions github-actions bot added the bug Something isn't working label Mar 19, 2025
@dreamorosi dreamorosi marked this pull request as ready for review March 19, 2025 12:58
Copy link
Contributor

@am29d am29d left a comment

Choose a reason for hiding this comment

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

One minor typo, otherwise good to merge

Co-authored-by: Alexander Schueren <[email protected]>
@dreamorosi dreamorosi requested a review from am29d March 19, 2025 13:51
@dreamorosi dreamorosi merged commit 51a3410 into main Mar 19, 2025
41 checks passed
@dreamorosi dreamorosi deleted the fix/parser_exports branch March 19, 2025 13:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working dependencies Changes that touch dependencies, e.g. Dependabot, etc. documentation Improvements or additions to documentation parser This item relates to the Parser Utility size/L PRs between 100-499 LOC tests PRs that add or change tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: DynamoDBStreamSchema can't be extended properly
2 participants