• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Qiskit / qiskit-fermions / 34473493707
98%

Build:
DEFAULT BRANCH: main
Ran 10 Sep 2026 11:55AM UTC
Jobs 1
Files 113
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

10 Sep 2026 11:51AM UTC coverage: 97.938% (+0.04%) from 97.895%
34473493707

push

github

web-flow
Fill gaps in the C API (#340)

* docs(cext): document the operand order of qf_*_compose

The four `qf_*_compose` docstrings described their parameters only as `left`
and `right` and their result as "the resulting operator", which left a C caller
unable to tell whether they receive `A B` or `B A`. The distinction is real
rather than cosmetic: `composed` and `matmul` are separate methods in the core
crate, and `qf_*_compose` wraps only the former.

Qiskit's C API resolves the same ambiguity for `qk_obs_compose` in prose rather
than by shipping a second symbol, so follow that precedent and spell the
convention out, including the note that the other order is obtained by swapping
the arguments. That sentence is what makes the absence of a `qf_*_matmul`
defensible, and it is exact: core's `matmul` is literally `_compose` with its
arguments swapped.

Also document that the composition drops group indices, which the core
implementation does unconditionally but no C docstring mentioned.

The accompanying test pins the documented order so that it cannot drift
silently. It deliberately uses a non-commuting pair, since the `one`/`zero`
operands used by the existing `test_compose` satisfy both conventions and would
therefore assert nothing about the operand order.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

* feat(cext): expose the operator support in the C API

`get_support` was reachable from Python but had no C counterpart at all, even
though the underlying `OperatorTrait::get_support` is implemented for every
operator representation in the core crate.

The other getters hand out a borrowed pointer into the operator, which is not an
option here: the support is gathered into a set on demand rather than stored, so
there is no buffer to lend out. Use the caller-sized output buffer pattern
already established by `split_out_groups` and the group-analysis functions, which
means the support needs a companion `num_support` to size that buffer with.

The ind... (continued)

304 of 304 new or added lines in 9 files covered. (100.0%)

1 existing line in 1 file now uncovered.

12017 of 12270 relevant lines covered (97.94%)

537213.0 hits per line

Coverage Regressions

Lines Coverage ∆ File
1
99.89
-0.11% crates/core/src/mappers/library/jordan_wigner.rs
Jobs
ID Job ID Ran Files Coverage
1 34473493707.1 10 Sep 2026 11:55AM UTC 113
97.94
GitHub Action Run
Source Files on build 34473493707
  • Tree
  • List 113
  • Changed 10
  • Source Changed 9
  • Coverage Changed 7
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #34473493707
  • 409a54c7 on github
  • Prev Build on main (#34373221764)
  • Next Build on main (#34488183873)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc