-
Notifications
You must be signed in to change notification settings - Fork 294
NVQC API versioning updates and advance REST API to v1.1 #1941
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
Conversation
|
CUDA Quantum Docs Bot: A preview of the documentation can be found here. |
|
CUDA Quantum Docs Bot: A preview of the documentation can be found here. |
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.
Thanks @bmhowe23. LGTM!
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 👍
|
Note: if #1958 is merged prior to this PR, then remove the vqe_h2.cpp exception that was added to the integration tests because this PR fixes that issue. |
|
CUDA Quantum Docs Bot: A preview of the documentation can be found here. |
This PR updates the client and server API handling code to better handle advancing the capabilities of the server without having to update the client. The basic use case of this will be adding new features to the server while allowing users to keep using old client versions (if desired). As long as the server updates are done in a non-breaking way, we would simply advance the REST API version on the server from 1.0 to 1.1, 1.1 to 1.2, etc. If there is a breaking change on the server where old clients could not talk to the new server, we would advance the REST API version to 2.0.
For changes like the recent VQE and optimizer updates, the client can retrieve the server information in order to figure out whether the "new" way is available. If the "new" way is unavailable, then it will simply fall back on the slower (but still functional) old way.
Note: the
remote-mqputarget behaves as if the client and server are essentially at the same version. That is - the client assumes that the server has all the optional capabilities that the client knows about. It behaved like that before, and this PR does not change that.The 1st commit of this PR actually fixes a bug where the NVQC VQE updates from #1901 were not working correctly for the actual NVQC target. The 2nd and 3rd commits reduce some duplicated code in PyRemoteSimulatorQPU.cpp in order to make it less like that the oversight in #1901 happens again. I can pull all 3 of those commits into a separate PR if desired.