Skip to content

Conversation

cyyever
Copy link
Contributor

@cyyever cyyever commented Jul 29, 2025

Fix invalid f-strings detected by ruff.

@loadams
Copy link
Collaborator

loadams commented Jul 29, 2025

@cyyever - could you please run the formatter? Also is it worth adding ruff to the formatter?

Signed-off-by: cyy <[email protected]>
@cyyever
Copy link
Contributor Author

cyyever commented Jul 30, 2025

@loadams I have formatted the files. I think it is worth adding ruff. However, to reduce the impact of refactoring we can apply the changes gradually.

@cyyever cyyever changed the title Fix some ruff warnings Fix invalid f-strings Jul 31, 2025
@loadams loadams requested a review from sfc-gh-mwyatt July 31, 2025 15:58
@loadams
Copy link
Collaborator

loadams commented Jul 31, 2025

cc: @sfc-gh-mwyatt

@cyyever
Copy link
Contributor Author

cyyever commented Aug 10, 2025

The test failures are unrelated.

@sfc-gh-mwyatt
Copy link
Collaborator

FYI @loadams we probably don't want to add ruff to the formatting unless we have very good reason to. It could result in very big changes to the code base. Right now we are using yapf and flake8 to do the job that ruff would do. The reason this error is not caught by flake8 is because we have an exception for F541:

ignore = E,F403,F405,F541,F841,W
. I would remove this before switching to a different linter/formatter.

@sfc-gh-truwase sfc-gh-truwase enabled auto-merge (squash) August 15, 2025 16:22
@sfc-gh-truwase sfc-gh-truwase merged commit 1c03d1b into deepspeedai:master Aug 16, 2025
15 of 17 checks passed
@cyyever cyyever deleted the ruff_fix branch August 18, 2025 02:29
LYMDLUT pushed a commit to LYMDLUT/DeepSpeed that referenced this pull request Aug 20, 2025
Fix invalid f-strings detected by ruff.

---------

Signed-off-by: cyy <[email protected]>
Co-authored-by: Logan Adams <[email protected]>
Co-authored-by: Olatunji Ruwase <[email protected]>
Co-authored-by: Michael Wyatt <[email protected]>
Signed-off-by: lym <[email protected]>
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.

4 participants