Skip to content

[WIP] feat(15726): consolidate_blocks borrows from Python instead of cloning#15739

Open
nomicflux wants to merge 1 commit intoQiskit:mainfrom
nomicflux:feature/15726-consolidate-blocks-borrows
Open

[WIP] feat(15726): consolidate_blocks borrows from Python instead of cloning#15739
nomicflux wants to merge 1 commit intoQiskit:mainfrom
nomicflux:feature/15726-consolidate-blocks-borrows

Conversation

@nomicflux
Copy link

@nomicflux nomicflux commented Mar 2, 2026

Summary

Provides DecomposerRef to pass along PyRefs instead of cloning the underlying object. This provides a unified reference between Python refs & Rust refs, along with a streamlined apply function to encapsulate internals.

Details and comments

  • AI tool used: OpenAI GPT-5.3-Codex for code analysis and technical advice. All code added was directly from me.
  • Arguments to internal_consolidate_blocks packaged up into ConsolidateBlocksOptions to clean up the interface and make clearer that they are potential set in Python but also Nones from Rust.
  • No new tests, as the behaviour should be identical to outside observers

Resolves #15726

@qiskit-bot qiskit-bot added the Community PR PRs from contributors that are not 'members' of the Qiskit repo label Mar 2, 2026
@CLAassistant
Copy link

CLAassistant commented Mar 2, 2026

CLA assistant check
All committers have signed the CLA.

@nomicflux nomicflux marked this pull request as ready for review March 14, 2026 03:49
@nomicflux nomicflux requested a review from a team as a code owner March 14, 2026 03:49
@qiskit-bot
Copy link
Collaborator

Thank you for opening a new pull request.

Before your PR can be merged it will first need to pass continuous integration tests and be reviewed. Sometimes the review process can be slow, so please be patient.

While you're waiting, please feel free to review other open PRs. While only a subset of people are authorized to approve pull requests for merging, everyone is encouraged to review open pull requests. Doing reviews helps reduce the burden on the core team and helps make the project's code better for everyone.

One or more of the following people are relevant to this code:

  • @Qiskit/terra-core

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Community PR PRs from contributors that are not 'members' of the Qiskit repo

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

Refactor Rust/Python interface of ConsolidateBlocks

3 participants