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

Add ruff check to CI and clean up Python #1661

Merged
merged 16 commits into from
Nov 8, 2024
Merged

Add ruff check to CI and clean up Python #1661

merged 16 commits into from
Nov 8, 2024

Conversation

cqc-alec
Copy link
Collaborator

@cqc-alec cqc-alec commented Nov 7, 2024

Closes #1639 .

I've configured ruff to ignore a few rules but we might want to address these as well in future (in particular we should probably use __all__ in init files instead of importing with wildcards).

@cqc-alec cqc-alec changed the title Ae/ruff Add ruff check to CI and clean up Python Nov 7, 2024
@cqc-alec cqc-alec requested a review from cqc-melf November 7, 2024 10:51
@cqc-alec cqc-alec marked this pull request as ready for review November 7, 2024 10:51
pytket/tests/classical_test.py Outdated Show resolved Hide resolved
pytket/tests/classical_test.py Outdated Show resolved Hide resolved
pytket/ruff.toml Outdated Show resolved Hide resolved
pytket/pytket/backends/backend_exceptions.py Show resolved Hide resolved
pytket/pytket/utils/operators.py Show resolved Hide resolved
"A",
"AIR",
# "ANN",
# "ARG", # TODO
Copy link
Contributor

Choose a reason for hiding this comment

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

is there an issues that we could link?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I can make an issue to come back and address some of these.

pytket/ruff.toml Show resolved Hide resolved
pytket/tests/classical_test.py Show resolved Hide resolved
pytket/tests/compilation_test.py Show resolved Hide resolved
pytket/tests/qubitpaulioperator_test.py Show resolved Hide resolved
pytket/tests/quipper_test.py Show resolved Hide resolved
pytket/tests/tket_sim_test.py Show resolved Hide resolved
pytket/tests/tket_sim_test.py Show resolved Hide resolved
@cqc-alec cqc-alec requested a review from cqc-melf November 8, 2024 15:07
Copy link
Contributor

@cqc-melf cqc-melf left a comment

Choose a reason for hiding this comment

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

One last point

@cqc-melf cqc-melf self-requested a review November 8, 2024 15:56
@cqc-alec cqc-alec merged commit c52838b into main Nov 8, 2024
30 checks passed
@cqc-alec cqc-alec deleted the ae/ruff branch November 8, 2024 16:44
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.

Run ruff check on CI
2 participants