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

Bump MSRV to 1.70 #11493

Merged
merged 1 commit into from
Jan 5, 2024
Merged

Bump MSRV to 1.70 #11493

merged 1 commit into from
Jan 5, 2024

Conversation

mtreinish
Copy link
Member

@mtreinish mtreinish commented Jan 4, 2024

Summary

This commit bumps the minimum supported rust version (MSRV) from 1.64 to 1.70. We're evaluating using new rust libraries in the Qiskit accelerate crate that have MSRVs of 1.70 (the upstream libraries have a higher MSRV primarily because of internal use of generic associated types in those libraries). This commit raises the MSRV proactively to align with the 1.0.0 release so we don't have to raise it during a minor version release (like 1.1.0 or 1.2.0) if we chose to start using the libraries later.

Details and comments

@mtreinish mtreinish requested a review from a team as a code owner January 4, 2024 21:22
@qiskit-bot
Copy link
Collaborator

One or more of the the following people are requested to review this:

@mtreinish mtreinish added Changelog: API Change Include in the "Changed" section of the changelog Rust This PR or issue is related to Rust code in the repository labels Jan 4, 2024
@mtreinish mtreinish added this to the 1.0.0 milestone Jan 4, 2024
@coveralls
Copy link

coveralls commented Jan 4, 2024

Pull Request Test Coverage Report for Build 7425519547

Warning: This coverage report may be inaccurate.

We've detected an issue with your CI configuration that might affect the accuracy of this pull request's coverage report.
To ensure accuracy in future PRs, please see these guidelines.
A quick fix for this PR: rebase it; your next report should be accurate.

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.02%) to 87.554%

Totals Coverage Status
Change from base Build 7423561045: -0.02%
Covered Lines: 59450
Relevant Lines: 67901

💛 - Coveralls

@mtreinish mtreinish added the on hold Can not fix yet label Jan 4, 2024
@mtreinish
Copy link
Member Author

I put this on hold because we might need to bump to 1.70.0 instead of 1.67.1 for one dependency.

This commit bumps the minimum supported rust version (MSRV) from 1.64 to
1.70. We're evaluating using new rust libraries in the Qiskit
accelerate crate that have MSRVs of 1.70 (the upstream libraries
have a higher MSRV primarily because of internal use of generic
associated types in those libraries). This commit raises the MSRV
proactively to align with the 1.0.0 release so we don't have to raise it
during a minor version release (like 1.1.0 or 1.2.0) if we chose to
start using the libraries later.
@mtreinish mtreinish changed the title Bump MSRV to 1.67.1 Bump MSRV to 1.70 Jan 5, 2024
@mtreinish mtreinish removed the on hold Can not fix yet label Jan 5, 2024
jakelishman
jakelishman previously approved these changes Jan 5, 2024
Copy link
Member

@jakelishman jakelishman left a comment

Choose a reason for hiding this comment

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

I'd prefer to leave us on a lower MSRV than this, given 1.70 is only six months old, but it does look like that'll be more of a problem for the compiler frameworks we're anticipating using in the OQ3 parser, so I'm ok with it.

How strictly are you thinking we should abide by "no MSRV increases during the 1.x series?". I guess the question depends a lot on whether we think 1.2 -> 1.3 in Rust semantic versioning allows an MSRV bump. I've seen arguments from Rust people that it should be allowed, though I'm not entirely convinced. It feels like our main driver for a bump would be major new features in a dependency getting gated behind a higher version, but there doesn't seem to be anything in Rusts 1.71 onwards that would necessitate that for us - likely the biggest change will be the return-position impl Trait, but that's primarily for async and the proposed generator stuff, which we aren't using and are unlikely to be.

@mtreinish
Copy link
Member Author

mtreinish commented Jan 5, 2024

The language I put in the stability policy docs was:

The supported Python versions, minimum supported Rust version (for building Qiskit from source), and any Python package dependencies (including the minimum supported versions of dependencies) used by Qiskit are not part of the backwards compatibility guarantees and may change during any release. Only minor or major version releases will raise minimum requirements for using or building Qiskit (including adding new dependencies), but patch fixes might include support for new versions of Python or other dependencies. Usually the minimum version of a dependency is only increased when older dependency versions go out of support or when it is not possible to maintain compatibility with the latest release of the dependency and the older version.

My thinking was we can bump the MSRV in 1.1, 1.2, etc if there is a good reason to. But in general if we can avoid it then I think that'd be for the best and we should just keep using 1.70 for all of the 1.x series. If we encounter some reason to raise it within the next year we can discuss it at the time.

@jakelishman
Copy link
Member

Yeah, that's fine by me - we'll aim to keep 1.70 throughout, but not commit to it.

@jakelishman jakelishman added this pull request to the merge queue Jan 5, 2024
mtreinish added a commit to mtreinish/qiskit-core that referenced this pull request Jan 5, 2024
The recent ahash release 0.8.7 started using the library feature
'stdsimd' which was not stabilized until Rust 1.72 for aarch64 and
will cause an issue when building for aarch64 on (see
tkaitchuck/aHash#195 for more details) with our MSRV which was 1.64 and
was just raised to 1.70 in Qiskit#11493. This isn't caught in CI because we
don't have any aarch64 environments to test with. As 1.72 is fairly
recent < 6 months old as of this commit. This just opts to pin the ahash
version used to one that is compatible with our MSRV on all supported
platforms.
mtreinish added a commit to mtreinish/qiskit-core that referenced this pull request Jan 5, 2024
The recent ahash release 0.8.7 started using the library feature
'stdsimd' which was not stabilized until Rust 1.72 for aarch64 and
will cause an issue when building for aarch64 on (see
tkaitchuck/aHash#195 for more details) with our MSRV which was 1.64 and
was just raised to 1.70 in Qiskit#11493. This isn't caught in CI because we
don't have any aarch64 environments to test with. As 1.72 is fairly
recent < 6 months old as of this commit. This just opts to pin the ahash
version used to one that is compatible with our MSRV on all supported
platforms.
@mtreinish mtreinish mentioned this pull request Jan 5, 2024
Merged via the queue into Qiskit:main with commit 4b7156a Jan 5, 2024
12 of 15 checks passed
@mtreinish mtreinish deleted the bump-msrv branch January 5, 2024 19:10
github-merge-queue bot pushed a commit that referenced this pull request Jan 5, 2024
The recent ahash release 0.8.7 started using the library feature
'stdsimd' which was not stabilized until Rust 1.72 for aarch64 and
will cause an issue when building for aarch64 on (see
tkaitchuck/aHash#195 for more details) with our MSRV which was 1.64 and
was just raised to 1.70 in #11493. This isn't caught in CI because we
don't have any aarch64 environments to test with. As 1.72 is fairly
recent < 6 months old as of this commit. This just opts to pin the ahash
version used to one that is compatible with our MSRV on all supported
platforms.
ShellyGarion pushed a commit to ShellyGarion/qiskit-terra that referenced this pull request Jan 18, 2024
This commit bumps the minimum supported rust version (MSRV) from 1.64 to
1.70. We're evaluating using new rust libraries in the Qiskit
accelerate crate that have MSRVs of 1.70 (the upstream libraries
have a higher MSRV primarily because of internal use of generic
associated types in those libraries). This commit raises the MSRV
proactively to align with the 1.0.0 release so we don't have to raise it
during a minor version release (like 1.1.0 or 1.2.0) if we chose to
start using the libraries later.
ShellyGarion pushed a commit to ShellyGarion/qiskit-terra that referenced this pull request Jan 18, 2024
The recent ahash release 0.8.7 started using the library feature
'stdsimd' which was not stabilized until Rust 1.72 for aarch64 and
will cause an issue when building for aarch64 on (see
tkaitchuck/aHash#195 for more details) with our MSRV which was 1.64 and
was just raised to 1.70 in Qiskit#11493. This isn't caught in CI because we
don't have any aarch64 environments to test with. As 1.72 is fairly
recent < 6 months old as of this commit. This just opts to pin the ahash
version used to one that is compatible with our MSRV on all supported
platforms.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Changelog: API Change Include in the "Changed" section of the changelog Rust This PR or issue is related to Rust code in the repository
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants