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

Qiskit / qiskit / 13595577475
88%

Build:
DEFAULT BRANCH: main
Ran 28 Feb 2025 08:22PM UTC
Jobs 1
Files 867
Run time 2min
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

28 Feb 2025 07:25PM UTC coverage: 86.972% (+0.008%) from 86.964%
13595577475

push

github

web-flow
C API for ``SparseObservable`` (#13694)

* Split ``PySparseObservable`` or ``SparseObservable``

* reno and docs

* rm Arc<RwLock> for SparseTerm

* add Into(Py) for SparseObservable

* rm Rust-side PySparseObservable.clone

* smaller fixes

- avoid using &Vec
- add unsafe to mutable indices/boundaries
- rm upgrade reno

* move back into 1 file

* use Arc::ptr_eq over .is()

* C API for SparseObservable

Co-authored-by: Max Rossmannek <oss@zurich.ibm.com>

* Add struct/enum prefix

* Bring trait impls closer to structs

* review comments

- use Arc<> instead of Py<> in ArrayView
- py_sparse.. -> sparse_

* fix test imports

* attempt 1 to add CI integration

* thine tools shall obey thou holy pylint

* fix cbindgen dep

* add clang format to CI lint

* fix tox

* reno draft

some of this might need to be updated once we add the Docs

* updates from discussion w/ Jake

- use pointers instead of refs
- add safety sections in the docs
- add a SparseObservable.new from raw data
- enable alignment check (possible w/ new MSRV)
- pass bitterm (u8) by value

* round 1 of review comments

- mainly SAFETY sections
- improve formatting tools
- location and import of header

* left over small comments

* Rework print function to return string

This commit reworks the print obs and obsterm functions which just
called printf internally and instead replaces them with new `_str()`
and `free_*_str()` functions to both return a string and free a string
representation of a sparse observable and term. This enables debugging
but without forcing you to stdout. Managing the stdout buffers between
2 or 3 languages isn't really feasible, so having a string generator
function lets the C user do whatever they need with the string repr.

* Tidy up README code

* Fix incorrect documentation

* Fix missing includes

As an implementation detail, `qiskit.h` includes `stdint.h` and
`stdbool.h`, but we use their items explicitly, so best to be explicit.

Fixup includes

* Correct C co... (continued)

4 of 4 new or added lines in 1 file covered. (100.0%)

5 existing lines in 3 files now uncovered.

76036 of 87426 relevant lines covered (86.97%)

333787.88 hits per line

Uncovered Existing Lines

Lines Coverage ∆ File
1
94.39
0.0% crates/accelerate/src/unitary_synthesis.rs
1
94.23
-0.23% crates/qasm2/src/expr.rs
3
92.98
0.5% crates/qasm2/src/lex.rs
Jobs
ID Job ID Ran Files Coverage
1 13595577475.1 28 Feb 2025 08:22PM UTC 867
86.97
GitHub Action Run
Source Files on build 13595577475
  • Tree
  • List 867
  • Changed 5
  • Source Changed 1
  • Coverage Changed 5
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #13595577475
  • 3ac34bcc on github
  • Prev Build on gh-readonly-queue/main/pr-13918-fcb5d29c6ee75e2b3a0d9e9866f026488f0ab5dc (#13589901777)
  • Next Build on main (#13597667305)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc