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

Qiskit / qiskit / 24097438704
88%

Build:
DEFAULT BRANCH: main
Ran 07 Apr 2026 06:51PM UTC
Jobs 1
Files 932
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

07 Apr 2026 05:53PM UTC coverage: 87.526% (+0.03%) from 87.495%
24097438704

push

github

web-flow
Rewrite QPY `ParameterExpression` handling in pure Polish form (#15934)

* Rewrite QPY `ParameterExpression` handling in pure Polish form

This patch is a fairly invasive change, but one that fixes the known
edge cases of replay generation from `ParameterExpression` itself.  This
fixes several `pickle`, `copy`/`deepcopy` and QPY bugs around
`ParameterExpression`.

The Python-space QPY loader is modified in a small way to allow it to
handle QPY-format permitted "replay" elements that act between two bare
values; this was always allowed by the QPY spec, but couldn't be
generated by Python-space QPY/`ParameterExpression`.  Doing so actually
significantly simplifies the loading logic, since it no longer needs to
reflect certain arithmetic operations.  The new Rust-space
`ParameterExpression` uses binary operations with two numeric operands
(e.g. `Add(2, 0)`) to safely propagate bare values through the QPY
replay.  This was not previously necessary in Python space because there
was no public interface to create a bare-numeric `ParameterExpression`
without replayable expressions having been tracked.  Similarly,
cancelled-out symbols are propagated in the replay with `Sub(x, x)`
operations, which already must work across all compliant QPY loaders,
and both Rust- and Python-space `ParameterExpression.

History
-------

The QPY replay was _intended_ to be a pure Polish-notation
representation of the operations to take to rebuild the expression.
This mostly worked fine at the time, but the patch was written under a
lot of stress and without full CI tooling, due to it being in response
to a security bug.  This led to some less-than-ideal parts of the format
specification, such as the start/end recursion opcodes in the QPY format
not actually being necessary; they are actually zero-operand no-ops to
the stack, but this wasn't noticed during the patch due to time
pressure.

Further, as `ParameterExpression` moved to Rust, the tracked internal
"replay" list disappe... (continued)

167 of 262 new or added lines in 4 files covered. (63.74%)

37 existing lines in 6 files now uncovered.

104435 of 119319 relevant lines covered (87.53%)

1021805.78 hits per line

Uncovered Changes

Lines Coverage ∆ File
80
72.54
-2.11% crates/qpy/src/params.rs
15
90.53
3.55% crates/circuit/src/parameter/parameter_expression.rs

Coverage Regressions

Lines Coverage ∆ File
19
90.53
3.55% crates/circuit/src/parameter/parameter_expression.rs
6
60.31
-3.09% crates/qpy/src/bytes.rs
6
72.54
-2.11% crates/qpy/src/params.rs
4
91.52
-0.26% crates/qasm2/src/lex.rs
1
74.33
0.11% crates/circuit/src/parameter/symbol_expr.rs
1
94.71
-0.18% crates/transpiler/src/passes/unitary_synthesis/decomposers.rs
Jobs
ID Job ID Ran Files Coverage
1 24097438704.1 07 Apr 2026 06:51PM UTC 932
87.53
GitHub Action Run
Source Files on build 24097438704
  • Tree
  • List 932
  • Changed 9
  • Source Changed 5
  • Coverage Changed 8
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #24097438704
  • 8064d27e on github
  • Prev Build on gh-readonly-queue/main/pr-15951-12bb3efc7624381609eb5ec15c299563681ebd6f (#24044327820)
  • Next Build on main (#24135110945)
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

© 2026 Coveralls, Inc