-
-
Notifications
You must be signed in to change notification settings - Fork 159
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 a function in Mitiq that returns the versions of supported frontends as extracted from dev_requirements.txt #1478
Comments
Isn't this just |
Sometimes it happens that Mitiq is not compatible with the latest versions of supported frontends. This function may help users to know what versions of frontends are more appropriate for the installed version of Mitiq. It doesn't mean that they are forced to install those versions, but at least they now that those versions have been tested. |
Thanks Andrea. I of course leave it to you but, FWIW, my semi-detached perspective is that this seems like over engineering. Unless there's many messages per day about this, I would do nothing. Even if there are many messages, I would still probably do nothing. It's user error if they're not using the supported version. But if there's a really strong urge to do something, I would go minimal and add a URL to the error message, maybe to |
I agree with Ryan in that I'm not sure this worth our time to add. I think the assumed happy path is something like
I don't feel as though having the function A secondary concern is that adding HTTP requests seems strange to learn about a local install of |
Based on the feedback, we can close this issue. Side comment: the message "See https://github.com/unitaryfund/mitiq/blob/master/dev_requirements.txt for supported versions." can be a good compromise. But, if we ever decide to do this, the correct link is something like |
Issue Description
This is a simplified version of the stale issue #1201.
The versions of frontends that are tested with Mitiq are those in
dev_requirements.txt
. Apart from Cirq which is inrequirements.txt
.It would be helpful to have a function that returns those versions. E.g.
Important note: this is very tricky task since requirement files are present in the master branch but are not present in the "stable" Mitiq packages that are released on mypy.
Proposed Solution
A solution could be to:
dev_requirement.txt
andrequirement.txt
file.dev_requirement.txt
andrequirement.txt
.For the moment, I would not call the new function within
mitiq.about()
since, if there are problems (e.g. internet not working), the call tomitiq.about()
would fail and this is not nice.Drawbacks
This function requires an internet connection. This is not optimal but I don't see a valid alternative.
Details and code
A potential stub of code for getting the requirement files from internet is the following. But there could be much better ways.
The text was updated successfully, but these errors were encountered: