-
Notifications
You must be signed in to change notification settings - Fork 175
fix(batch): fixed the build issue with Batch processor due to missing dependencies #4498
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
Conversation
@dreamorosi This is ready for review now |
…-lambda-typescript into fix/batch_deps
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR fixes a build issue with the Batch processor by adding missing dependencies for Standard Schema validation support and refactoring DynamoDB stream schema validation to use consistent schemas for both OldImage and NewImage fields.
- Added
@standard-schema/spec
as a runtime dependency to properly support Standard Schema validation - Refactored test suite to use parameterized tests instead of deeply nested describe blocks for better maintainability
- Updated DynamoDB extended schemas to enforce the same schema for both
OldImage
andNewImage
fields instead of making them optional
Reviewed Changes
Copilot reviewed 8 out of 9 changed files in this pull request and generated 3 comments.
Show a summary per file
File | Description |
---|---|
packages/batch/package.json | Added @standard-schema/spec dependency and reorganized dev dependencies |
packages/batch/src/types.ts | Renamed type and updated to use StandardSchemaV1 instead of ZodType imports |
packages/batch/src/parser.ts | Updated schema extension logic and made DynamoDB OldImage /NewImage validation consistent |
packages/batch/src/BatchProcessor.ts | Added documentation example for inner schema validation |
packages/batch/src/BasePartialBatchProcessor.ts | Updated type references to use new BatchProcessorConfig |
packages/batch/tests/unit/parsing.test.ts | Completely refactored tests to use parameterized approach and added new test cases |
packages/batch/tests/helpers/factories.ts | Updated DynamoDB record factory to include OldImage field |
docs/features/batch.md | Added documentation note about DynamoDB schema behavior |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Co-authored-by: Andrea Amorosi <dreamorosi@gmail.com>
|
Summary
This PR fixes the build issue with the Batch Processor due to missing dependencies with Standard Schema.
Changes
@standard-schema/spec
as a dependency of the Batch processor packageOldImage
andNewImage
and added a note in the docs about itIssue number: closes #4496
Screenshot
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.