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

MetaBackend #1282

Merged
merged 62 commits into from
May 22, 2024
Merged

MetaBackend #1282

merged 62 commits into from
May 22, 2024

Conversation

BrunoLiegiBastonLiegi
Copy link
Contributor

This PR implements a MetaBackend object that will call the different projects' (qibojit, qibolab, etc...) MetaBackend to load their backends. This will replace the current construct_backend function and will also give access to a list_available() function to list all the backends available in the system.

Closes #1096.

Checklist:

  • Reviewers confirm new code works as expected.
  • Tests are passing.
  • Coverage does not decrease.
  • Documentation is updated.

Co-authored-by: Alessandro Candido <candido.ale@gmail.com>
Co-authored-by: Alessandro Candido <candido.ale@gmail.com>
@stavros11 stavros11 mentioned this pull request Apr 26, 2024
4 tasks
@BrunoLiegiBastonLiegi
Copy link
Contributor Author

We have the same problem here as in #1239. Namely, since now in main qibo depends on qibotn/py3.12 and qibojit/py3.12, I cannot resolve the conflicts without breaking something. For qibojit there is a simple solution which is changing the qibo dependency to qibojit/main as the corresponding qibojit PR has already been merged, however for qibotn the py3.12 PR does not seem to be mergeable soon.

@alecandido
Copy link
Member

True, this py3.12 upgrade is being a bit of a nightmare (I hope qibo-core will land soon...)

however for qibotn the py3.12 PR does not seem to be mergeable soon.

Here I disagree a bit, since qiboteam/qibotn#48 should be as good as main, and py3.12 compatible.
I just need the two approvals, thus I'm adding you as well as a reviewer :P

pyproject.toml Outdated Show resolved Hide resolved
poetry.lock Outdated Show resolved Hide resolved
@alecandido alecandido mentioned this pull request May 19, 2024
@alecandido
Copy link
Member

@BrunoLiegiBastonLiegi the issue with Pylint 3.2 is not completely trivial, thus I opened #1328 for it.

At this point, it's not worth to stop this any longer. Feel free to merge whenever you wish :)

@BrunoLiegiBastonLiegi
Copy link
Contributor Author

I was waiting for qibotn and qibo-cloud-backends to be merged before merging this one, just to avoid breaking the set_backend for those two.

@alecandido
Copy link
Member

I was waiting for qibotn and qibo-cloud-backends to be merged before merging this one, just to avoid breaking the set_backend for those two.

If they are going to be merged this week, so much the better (we'll need one less upgrade for the pyproject.toml/poetry.lock).
However, it doesn't have to be broken for them, since it will keep working with a previous release (and, in practice, they are relying on Qibo internals, so fine to break in new versions - the MetaBackend is exactly for that, to depend less), and it will work again with the latest one as soon as the PRs will be merged.

@MatteoRobbiati MatteoRobbiati added this pull request to the merge queue May 22, 2024
Merged via the queue into master with commit 3f17601 May 22, 2024
27 checks passed
@stavros11 stavros11 deleted the list_backends branch May 22, 2024 10:11
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.

List available backends
5 participants