Skip to content

Ruff for Linting and Formatting#104

Merged
vbharadwaj-bk merged 14 commits intomainfrom
ruff
May 28, 2025
Merged

Ruff for Linting and Formatting#104
vbharadwaj-bk merged 14 commits intomainfrom
ruff

Conversation

@asglover
Copy link
Copy Markdown
Collaborator

Added Ruff and pre-commit for python formatting and linting

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

perhaps the control flow could be simplified, line 16 and line 102 are very similar

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This is fine for now, I'd rather get this merged and then clean this part up later.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

changed from pass to skip for unsupported combinations

Copy link
Copy Markdown
Member

@vbharadwaj-bk vbharadwaj-bk left a comment

Choose a reason for hiding this comment

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

Looks good, and some of these smaller things can be cleaned up later; can you add a workflow file under .github/workflows, like so?

https://github.com/ACEsuit/mace/blob/main/.github/workflows/pre-commit.yaml

You don't need to select any version of pip or install flake8, black, etc., only pip install ruff is necessary. The last line of the file above runs the pre-commit check.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This is fine for now, I'd rather get this merged and then clean this part up later.

@vbharadwaj-bk
Copy link
Copy Markdown
Member

Also, you seem to have a conflict with main, so make sure to pull and merge.

Copy link
Copy Markdown
Member

@vbharadwaj-bk vbharadwaj-bk left a comment

Choose a reason for hiding this comment

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

LGTM!

@asglover asglover added the ci-ready Triggers CI checks for a pull request label May 28, 2025
@vbharadwaj-bk vbharadwaj-bk merged commit d1f20a1 into main May 28, 2025
2 checks passed
@vbharadwaj-bk vbharadwaj-bk deleted the ruff branch May 28, 2025 23:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci-ready Triggers CI checks for a pull request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants