-
Notifications
You must be signed in to change notification settings - Fork 141
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 Python 3.12 support #580
Conversation
Pull Request Test Coverage Report for Build 8044670802Details
💛 - Coveralls |
Works as intended - on One idea would be, e.g., to guard the cplex imports with a warning if users are on |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See comment above - works, but user experience might be better served with adding warnings.
If cplex does not exists, we already display a warning message with qiskit-optimization/qiskit_optimization/algorithms/cplex_optimizer.py Lines 28 to 29 in 36ad1a1
|
Arguably qiskit-optimization does not support 3.12 yet. Qiskit 0.45.1 added 3.12 support. I added support to qiskit algorithms qiskit-community/qiskit-algorithms#108 such that when this is released the apps, like Optimization here, could be updated to inlcude 3.12 as well. It might make more sense to do this in a PR which adds 3.12 support and CI jobs etc. once algorithms is released. And then do an update (bug fix) release. |
Yes, it makes sense to include this PR's change as part of a separate PR to add support for Python 3.12. |
@woodsp-ibm I added Python 3.12 support and CI (only Ubuntu + 3.12 due to lack of cplex). Could you take a look at it? |
As we are adding 3.12 to the list of supported versions in setup can we add a reno like I did in ML for the 3.12 support, see qiskit-community/qiskit-machine-learning#774 (its the same basic text as what I did in Nature and Algorithms for the same thing!) |
Thanks. I added reno. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
* add constraint for cplex * Add Python 3.12 support * reno (cherry picked from commit a52d23d)
* add constraint for cplex * Add Python 3.12 support * reno (cherry picked from commit a52d23d) Co-authored-by: Takashi Imamichi <[email protected]>
Summary
Closes #590
Add Python 3.12 support.
But since CPLEX does not support Python 3.12 (see pypi), we need to add constraint to 'cplex' extra dependency.
Windows and mac are still tested with Python 3.11 because cplex are not available for 3.12.
Fixes #577
Details and comments
Latest cplex 22.1.1.1
