Skip to content
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

Turn on isort for ruff #1128

Merged
merged 4 commits into from
May 22, 2024
Merged

Turn on isort for ruff #1128

merged 4 commits into from
May 22, 2024

Conversation

Lee-W
Copy link
Member

@Lee-W Lee-W commented May 20, 2024

Description

  • style: sort import
  • [build(script): add "ruff check --fix" to format script to enable import sorting](build: add I into ruff lint and add "ruff check --fix" to format script to enable import sorting)

According to ruff doc, we'll need these additional setups for sorting imports, and we've missed it for some time
https://docs.astral.sh/ruff/formatter/#sorting-imports
image

Checklist

  • Add test cases to all the changes you introduce
  • Run ./scripts/format and ./scripts/test locally to ensure this change passes linter check and test
  • Test the changes on the local machine manually
  • Update the documentation for the changes

Expected behavior

the import should be sorted by ruff

Steps to Test This Pull Request

./script/format

Additional context

Copy link

codecov bot commented May 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.58%. Comparing base (120d514) to head (93c97b7).
Report is 339 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1128      +/-   ##
==========================================
+ Coverage   97.33%   97.58%   +0.24%     
==========================================
  Files          42       55      +13     
  Lines        2104     2486     +382     
==========================================
+ Hits         2048     2426     +378     
- Misses         56       60       +4     
Flag Coverage Δ
unittests 97.58% <100.00%> (+0.24%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

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

scripts/format Outdated Show resolved Hide resolved
@Lee-W Lee-W merged commit 86d6aea into master May 22, 2024
18 checks passed
@Lee-W Lee-W deleted the turn-on-isort-for-ruff branch May 22, 2024 03:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants