Skip to content

feat(idempotency): return existing record in IdempotencyValidationError #2059

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

kevin-secrist
Copy link
Contributor

Description of your changes

Exposes the IdempotencyRecord which failed payload validation as a property on the thrown IdempotencyValidationError.

Related issues, RFCs

Issue number: closes #2048

Checklist

  • My changes meet the tenets criteria
  • I have performed a self-review of my own code
  • I have commented my code where necessary, particularly in areas that should be flagged with a TODO, or hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my change is effective and works
  • The PR title follows the conventional commit semantics

Breaking change checklist

Is it a breaking change?: NO

  • I have documented the migration process
  • I have added, implemented necessary warnings (if it can live side by side)

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.

@kevin-secrist kevin-secrist requested a review from a team February 12, 2024 23:03
@boring-cyborg boring-cyborg bot added idempotency This item relates to the Idempotency Utility tests PRs that add or change tests labels Feb 12, 2024
@pull-request-size pull-request-size bot added the size/M PR between 30-99 LOC label Feb 12, 2024
Copy link

boring-cyborg bot commented Feb 12, 2024

Thanks a lot for your first contribution! Please check out our contributing guidelines and don't hesitate to ask whatever you need.
In the meantime, check out the #typescript channel on our Powertools for AWS Lambda Discord: Invite link

@github-actions github-actions bot added the feature PRs that introduce new features or minor changes label Feb 12, 2024
Copy link
Contributor

@dreamorosi dreamorosi left a comment

Choose a reason for hiding this comment

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

Thank you for opening this PR, looks good to me!

@dreamorosi dreamorosi added the do-not-merge This item should not be merged label Feb 14, 2024
@dreamorosi
Copy link
Contributor

Hi @kevin-secrist, I'm looking at some issues on the integration tests around the Idempotency package.

I don't think they're related to the changes in this PR but just to be safe I'd like to take a bit more time to identify the issue before merging this PR.

@dreamorosi dreamorosi removed the do-not-merge This item should not be merged label Feb 15, 2024
@dreamorosi dreamorosi requested review from am29d and removed request for am29d February 15, 2024 10:42
@dreamorosi dreamorosi added the do-not-merge This item should not be merged label Feb 15, 2024
@dreamorosi
Copy link
Contributor

I was able to isolate the issue on the integration tests and confirm it's not related to the changes in this PR.

I'm opening another PR to fix them, and once that's merged we'll run the tests once again and merge this.

Copy link

Quality Gate Passed Quality Gate passed

Issues
0 New issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@dreamorosi
Copy link
Contributor

Integration tests are passing, thank you for the patience: https://github.com/aws-powertools/powertools-lambda-typescript/actions/runs/7930491156

@dreamorosi dreamorosi merged commit d1d2acf into aws-powertools:main Feb 16, 2024
Copy link

boring-cyborg bot commented Feb 16, 2024

Awesome work, congrats on your first merged pull request and thank you for helping improve everyone's experience!

@kevin-secrist kevin-secrist deleted the feat/expose-validation-error-record branch February 16, 2024 13:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
do-not-merge This item should not be merged feature PRs that introduce new features or minor changes idempotency This item relates to the Idempotency Utility size/M PR between 30-99 LOC tests PRs that add or change tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Feature request: Expose existing IdempotencyRecord in IdempotencyValidationError
2 participants