Skip to content

refactor(general): add support for ruff format #6512

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 3 commits into from
Apr 17, 2025

Conversation

leandrodamascena
Copy link
Contributor

Issue number: #6511

Summary

This PR introduces ruff format as our standard code formatter, replacing our previous formatting solution. Ruff's formatter ensures consistent PEP-compliant code style across our codebase while offering better performance and integration with our existing Ruff linting workflow.

Changes

  • Added ruff formatter configuration in pyproject.toml
  • Updated pre-commit hooks to use ruff format instead of previous formatter
  • Modified CI workflow to verify formatting with ruff format --check
  • Applied formatting to all Python files in the repository

User experience

no changes

Checklist

If your change doesn't seem to apply, please leave them unchecked.

Is this a breaking change?

RFC issue number:

Checklist:

  • Migration process documented
  • Implement warnings (if it can live side by side)

Acknowledgment

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.

@leandrodamascena leandrodamascena requested a review from a team as a code owner April 17, 2025 16:18
@boring-cyborg boring-cyborg bot added event_handlers github-actions Pull requests that update Github_actions code internal Maintenance changes logger labels Apr 17, 2025
@pull-request-size pull-request-size bot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Apr 17, 2025
@github-actions github-actions bot added enhancement and removed internal Maintenance changes labels Apr 17, 2025
Copy link

codecov bot commented Apr 17, 2025

Codecov Report

Attention: Patch coverage is 0% with 1 line in your changes missing coverage. Please review.

Project coverage is 96.16%. Comparing base (e9cb5e5) to head (5e668a5).
Report is 1 commits behind head on develop.

Files with missing lines Patch % Lines
aws_lambda_powertools/logging/logger.py 0.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@           Coverage Diff            @@
##           develop    #6512   +/-   ##
========================================
  Coverage    96.16%   96.16%           
========================================
  Files          243      243           
  Lines        11838    11838           
  Branches       885      885           
========================================
  Hits         11384    11384           
  Misses         356      356           
  Partials        98       98           

☔ 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.

anafalcao
anafalcao previously approved these changes Apr 17, 2025
@boring-cyborg boring-cyborg bot added the internal Maintenance changes label Apr 17, 2025
@github-actions github-actions bot removed the internal Maintenance changes label Apr 17, 2025
@leandrodamascena leandrodamascena merged commit a48f9bf into develop Apr 17, 2025
14 of 15 checks passed
@leandrodamascena leandrodamascena deleted the ci/enable-ruff-format branch April 17, 2025 20:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement event_handlers github-actions Pull requests that update Github_actions code logger size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Tech debt: Add support for ruff format to standardize code formatting according to PEP style guidelines
2 participants