Skip to content

refactor(event_handler): extract OpenAPI schema generation from Route class#8098

Merged
leandrodamascena merged 2 commits intodevelopfrom
refactor/8097-extract-openapi-schema-generator
Apr 6, 2026
Merged

refactor(event_handler): extract OpenAPI schema generation from Route class#8098
leandrodamascena merged 2 commits intodevelopfrom
refactor/8097-extract-openapi-schema-generator

Conversation

@leandrodamascena
Copy link
Copy Markdown
Contributor

Issue number: closes #8097

Summary

  • Extract OpenAPI schema generation from Route into openapi/schema_generator.py with standalone functions
  • Move _DEFAULT_CONTENT_TYPE and _DEFAULT_OPENAPI_RESPONSE_DESCRIPTION to openapi/constants.py
  • Route._get_openapi_path now delegates to generate_openapi_path()
  • No public API changes — all moved methods were internal (_ prefixed)

Changes

Please provide a summary of what's being changed

User experience

Please share what the user experience looks like before and after this change


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.

@powertools-for-aws-oss-automation powertools-for-aws-oss-automation bot added the size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. label Apr 4, 2026
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 4, 2026

Codecov Report

❌ Patch coverage is 97.28261% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 96.73%. Comparing base (8e816fb) to head (a0ef1f7).
⚠️ Report is 1 commits behind head on develop.

Files with missing lines Patch % Lines
...wertools/event_handler/openapi/schema_generator.py 97.17% 1 Missing and 4 partials ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #8098      +/-   ##
===========================================
- Coverage    96.73%   96.73%   -0.01%     
===========================================
  Files          283      284       +1     
  Lines        14017    14036      +19     
  Branches      1141     1140       -1     
===========================================
+ Hits         13560    13578      +18     
- Misses         331      332       +1     
  Partials       126      126              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@leandrodamascena leandrodamascena requested a review from hjgraca April 4, 2026 18:00
@leandrodamascena leandrodamascena requested a review from a team as a code owner April 6, 2026 15:18
@leandrodamascena leandrodamascena requested a review from sdangol April 6, 2026 15:18
@powertools-for-aws-oss-automation powertools-for-aws-oss-automation bot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. and removed size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Apr 6, 2026
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud bot commented Apr 6, 2026

@leandrodamascena leandrodamascena merged commit ae16510 into develop Apr 6, 2026
18 checks passed
@leandrodamascena leandrodamascena deleted the refactor/8097-extract-openapi-schema-generator branch April 6, 2026 15:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

event_handlers size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Tech debt: Extract OpenAPI schema generation from Route

2 participants