Skip to content

Apply ruff/Pylint Refactor rules (PLR)#12010

Merged
jacobtomlinson merged 6 commits intodask:mainfrom
DimitriPapadopoulos:PLR
Nov 4, 2025
Merged

Apply ruff/Pylint Refactor rules (PLR)#12010
jacobtomlinson merged 6 commits intodask:mainfrom
DimitriPapadopoulos:PLR

Conversation

@DimitriPapadopoulos
Copy link
Copy Markdown
Contributor

  • Closes #xxxx
  • Tests added / passed
  • Passes pre-commit run --all-files

@DimitriPapadopoulos DimitriPapadopoulos marked this pull request as draft July 9, 2025 06:59
@DimitriPapadopoulos DimitriPapadopoulos marked this pull request as ready for review July 9, 2025 07:01
@DimitriPapadopoulos DimitriPapadopoulos marked this pull request as draft July 9, 2025 07:15
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Jul 9, 2025

Unit Test Results

See test report for an extended history of previous test failures. This is useful for diagnosing flaky tests.

      9 files  ±0        9 suites  ±0   3h 11m 47s ⏱️ - 3m 37s
 18 139 tests ±0   16 924 ✅ ±0   1 215 💤 ±0  0 ❌ ±0 
162 479 runs  ±0  150 386 ✅ +1  12 093 💤  - 1  0 ❌ ±0 

Results for commit e55c2d6. ± Comparison against base commit 88fd00d.

♻️ This comment has been updated with latest results.

@DimitriPapadopoulos DimitriPapadopoulos marked this pull request as ready for review July 9, 2025 19:58
@github-actions github-actions bot added the needs attention It's been a while since this was pushed on. Needs attention from the owner or a maintainer. label Sep 29, 2025
Copy link
Copy Markdown
Member

@jacobtomlinson jacobtomlinson left a comment

Choose a reason for hiding this comment

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

Once #12002 is merged we should update this PR to enforce these rules via pre-commit.

@DimitriPapadopoulos
Copy link
Copy Markdown
Contributor Author

Rebased and updated as suggested. BTW, rule PLR0133 helped identify a bug in a test.

@github-actions github-actions bot removed the needs attention It's been a while since this was pushed on. Needs attention from the owner or a maintainer. label Nov 3, 2025
@jacobtomlinson
Copy link
Copy Markdown
Member

There are a surprising number of CI failures related to this PR that we aren't seeing on main. I've updated with the latest main to see if they are still happening.

@DimitriPapadopoulos
Copy link
Copy Markdown
Contributor Author

DimitriPapadopoulos commented Nov 4, 2025

And yet this PR mostly changes else if to elif. It suspect this is again related to some existing concurrency problem. Or there's a subtle difference when running tests in main and other branches. I'll keep looking.

Rebased to fix the conflict.

@DimitriPapadopoulos
Copy link
Copy Markdown
Contributor Author

My wrong, I failed to revert 3c30483 after opening #12015. Will fix that.
.

PLR0133 Two constants compared in a comparison, consider replacing `==`
PLR0402 Use `from ... import ...` in lieu of alias
PLR1722 Use `sys.exit()` instead of `exit`
PLR5501 Use `elif` instead of `else` then `if`, to reduce indentation
PLR1711 Useless `return` statement at end of function
@jacobtomlinson jacobtomlinson merged commit 74ad214 into dask:main Nov 4, 2025
24 of 25 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants