-
Notifications
You must be signed in to change notification settings - Fork 430
fix: Bring back VisitMap impl for std HashSet
#764
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
VisitMap impl for std HashSetVisitMap impl for std HashSet
bushrat011899
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a good fix, but I'm not sure why this is considered a semver break.
| } | ||
|
|
||
| #[cfg(feature = "std")] | ||
| impl<N, S> VisitMap<N> for std::collections::HashSet<N, S> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't really understand how this is considered a semver break, but I guess it is?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is most likely due to the cargo-semver-checks bug obi1kenobi/cargo-semver-checks#1200
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed now with #765.
For reference to the links pointing here, here's the error we had:
--- failure trait_newly_sealed: pub trait became sealed ---
Description:
A publicly-visible trait became sealed, so downstream crates are no longer able to implement it
ref: https://rust-lang.github.io/api-guidelines/future-proofing.html#sealed-traits-protect-against-downstream-implementations-c-sealed
impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.40.0/src/lints/trait_newly_sealed.ron
Failed in:
trait petgraph::data::Create in file /home/runner/work/petgraph/petgraph/PR_BRANCH/src/data.rs:76
trait petgraph::data::FromElements in file /home/runner/work/petgraph/petgraph/PR_BRANCH/src/data.rs:281
trait petgraph::data::Build in file /home/runner/work/petgraph/petgraph/PR_BRANCH/src/data.rs:[53](https://github.com/petgraph/petgraph/actions/runs/14302765504/job/40080013218?pr=764#step:9:54)
https://github.com/petgraph/petgraph/actions/runs/14302765504/job/40080013218#step:9:52
Disables a failing semver-checks that's causing [false positives](#764 (comment)). This seems to be caused by obi1kenobi/cargo-semver-checks#1200
## 🤖 New release * `petgraph`: 0.8.0 -> 0.8.1 (✓ API compatible changes) <details><summary><i><b>Changelog</b></i></summary><p> <blockquote> ## [0.8.1](https://github.com/petgraph/petgraph/compare/petgraph@v0.8.0...petgraph@v0.8.1) - 2025-04-07 ### Bug Fixes - Bring back `VisitMap` impl for std `HashSet` ([#764](#764)) ### New Features - Add `UnionFind` capacity management methods ([#736](#736)) - add `#[track_caller]` to functions that panic ([#748](#748)) </blockquote> </p></details> --- This PR was generated with [release-plz](https://github.com/release-plz/release-plz/). --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Agustín Borgna <agustinborgna@gmail.com>
This fixes #763 .