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

Silence rust clippy lint enabled after the 1.84 release #1359

Merged
merged 2 commits into from
Jan 14, 2025

Conversation

IvanIsCoding
Copy link
Collaborator

In short the new clippy lint suggests us to replace map_or with is_none_or.

But is_none_or is only available for Rust 1.82 or newer (https://doc.rust-lang.org/std/option/enum.Option.html#method.is_none_or). So we can revisit this but at the time it is best to ignore

@IvanIsCoding IvanIsCoding requested a review from mtreinish January 9, 2025 22:30
@IvanIsCoding
Copy link
Collaborator Author

IvanIsCoding commented Jan 10, 2025

There are still some failures I need to investigate

edit: well I guess PyO3 0.22 does leak some of their features in a public macro

@@ -71,6 +71,12 @@ version = "^0.11"
default-features = false
features = ["multi_thread"]

[features]
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This is ugly but it is the only way to make PyO3 0.22 work with Clippy. I will not bother opening a bug as the latest version already has a fix

Copy link
Member

Choose a reason for hiding this comment

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

Yeah I think this is fine as a temporary fix I had to do the same thing on qiskit recently too: Qiskit/qiskit#13645

@coveralls
Copy link

Pull Request Test Coverage Report for Build 12702725601

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 95.825%

Totals Coverage Status
Change from base Build 12653809774: 0.0%
Covered Lines: 18360
Relevant Lines: 19160

💛 - Coveralls

@mtreinish mtreinish added this pull request to the merge queue Jan 14, 2025
Merged via the queue into Qiskit:main with commit 9969f0e Jan 14, 2025
31 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.

3 participants