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

Qiskit / rustworkx / 9685802979
94%

Build:
DEFAULT BRANCH: main
Ran 26 Jun 2024 07:57PM UTC
Jobs 1
Files 105
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

26 Jun 2024 07:45PM UTC coverage: 95.388% (-0.06%) from 95.445%
9685802979

push

github

web-flow
Add `layers` function to `rustworkx-core` (#1194)

* Initial: Add `layers` function to `rustworkx-core`
- Modify the `layers` python interface to use the `rustworkx-core` equivalent.

* Docs: Add proper docstring to `layers`

* Fix: Wrong import in docstring

* Fix: Return an `Iterator` instance from `layers` in `rustworkx-core`.

* Test: Add tests to `layers`
- Move `layers` to `dag_algo.rs`.
- Add check for cycles, if a cycle is found throw an error.
- Refactor `LayersIndexError` to `LayersError`.
- Move `LayersError` to `err.rs`.
- Other small tweaks and fixes.

* Format: Fix lint.

* Docs: Fix docs test.

* Docs: Add release note

* Docs: Fix release note

* Fix: Return NodeId instead of usize

* Docs: Add suggestions for release note.

* Fix: Return true Iterator for `layers`
- Use panic exceptions for specific cases.
- Other tweaks and fixes.

* Fix: Node check only in the first layer

* Fix: Remove result handling for layers
- Use `panic!` when a programming error is made.
- Verify cycles by checkng repeating layers, call `panic!` if one is found.
- Adapt python side function to use check for nodes to avoid panic.
- Adapt tests.

* Remove: `LayersError` as it will no longer be needed.
- Small fix in docstring.

* Fix: Revert result handling in `layers`
- Add result handling in the python version of the function.
- Use indices to keep track of cycles.
- Revert deletion of `LayersError`.
- Update tests.
- Other tweaks and fixes.

* Docs: Fix release note and docstring
- Fix docstring test and regular test.
- Add extra check for missing nodes.

* Fix: Explicit warning for invalid first index
- Remove calls to `to_owned()`.

---------

Co-authored-by: Matthew Treinish <mtreinish@kortar.org>

108 of 121 new or added lines in 3 files covered. (89.26%)

17972 of 18841 relevant lines covered (95.39%)

1138955.23 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
2
99.41
-0.59% src/dag_algo/mod.rs
3
42.11
-7.89% rustworkx-core/src/err.rs
8
96.49
-1.78% rustworkx-core/src/dag_algo.rs
Jobs
ID Job ID Ran Files Coverage
1 9685802979.1 26 Jun 2024 07:57PM UTC 105
95.39
GitHub Action Run
Source Files on build 9685802979
  • Tree
  • List 105
  • Changed 25
  • Source Changed 3
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #9685802979
  • 5829af6b on github
  • Prev Build on main (#9672352036)
  • Next Build on main (#9704784541)
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