Skip to content
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

Crates.io version released with breaking change and does not match GitHub master version #1587

Closed
jrakow opened this issue Jul 1, 2019 · 8 comments
Assignees

Comments

@jrakow
Copy link

jrakow commented Jul 1, 2019

On https://crates.io/crates/bindgen, the newest version is 0.49.3, while GitHub master (dbe5bab) shows 0.49.2. HEAD (ad0bf8e) points to a distinct commit with a version bump.

I noticed, because #1575 is a breaking change and is included in 0.49.3. Because this version is semver-compatibel, it is automatically upgraded to.

@emilio
Copy link
Contributor

emilio commented Jul 1, 2019

Hmm, so you're right, I somehow messed up that release, will jank. Looking at my reflog, I was at a local master branch, not up-to-date with upstream since I had merged a fix before, and my release script just failed to push to upstream.

Regarding #1575 being breaking, that's a bit discutible, I'm not sure if we're supposed to guarantee stability with rust-target=nightly, but I guess given we don't document it either way, it technically is, and since the release is broken anyhow, I may as well jank it and publish a breaking version.

Really sorry for the hassle, this is all my fault.

@emilio emilio self-assigned this Jul 1, 2019
@emilio
Copy link
Contributor

emilio commented Jul 1, 2019

I'll put up the right tag for 0.49.3 either way in the upstream repo (it is https://github.com/emilio/rust-bindgen/releases/tag/v0.49.3).

@emilio
Copy link
Contributor

emilio commented Jul 1, 2019

(And of course I'll fix my crappy release script to error out when any of the commands fail instead of happily continuing to cargo publish, d'oh)

@emilio
Copy link
Contributor

emilio commented Jul 1, 2019

Sorry, I should fix up all my scripts to use set -o errexit -.-

emilio added a commit that referenced this issue Jul 1, 2019
NOTE: For $REASONS (see #1587),
this is not the actual commit that is tagged on the release.
@emilio emilio closed this as completed in d789817 Jul 1, 2019
@emilio
Copy link
Contributor

emilio commented Jul 1, 2019

Ok, everything should be in order now. The tag was already right (https://github.com/rust-lang/rust-bindgen/releases/tag/v0.49.3), it just failed to push to master because of the fix that had been merged in between.

I've yanked that version, and published v0.50.0 with that fix. I've fixed up my scripts so that this doesn't happen again, and for now I'll treat rust-target=nightly changes as breaking.

That being said, I think v0.49.3 shouldn't be semver-incompatible, even with rust-target=nightly, so maybe I shouldn't have yanked it. How is #1575 breaking? You need to explicitly opt-into it, don't you?

Or you meant #1581? I guess that actually could be semver-incompatible, technically... I didn't think at the time removing a default-feature-dependency that isn't used at all could break anything, but I guess it technically could if we specify any clap feature that you could opt-out. Is that the scenario you meant?

@jrakow
Copy link
Author

jrakow commented Jul 1, 2019

Thanks for the fix.

#1575 is definitively breaking. Look at this change: https://github.com/rust-lang/rust-bindgen/pull/1575/files#diff-567e947a8cc5ad306d3eff99dfb66cc9L2173
This changes a variant of the public enum EnumVariation. I noticed, because I was using it with https://docs.rs/bindgen/0.49.2/bindgen/struct.Builder.html#method.default_enum_style. See also the two docs.rs versions:
https://docs.rs/bindgen/0.49.2/bindgen/enum.EnumVariation.html#variant.Rust
https://docs.rs/bindgen/0.49.3/bindgen/enum.EnumVariation.html#variant.Rust

Not sure, why you are talking about nightly. I am on stable and this was breaking on stable.

Anyway, thanks again.

@emilio
Copy link
Contributor

emilio commented Jul 1, 2019

D'oh, I didn't realize that particular enum was part of the public API when reviewing that. Really sorry for the breakage.

@emilio
Copy link
Contributor

emilio commented Jul 1, 2019

(I was thinking about the feature itself, generating #[non_exhaustive], which is done only with rust-target=nightly, and only if you opt into it).

Thanks for clarifying it.

LoganBarnett pushed a commit to LoganBarnett/rust-bindgen that referenced this issue Dec 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants