-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Verify that only non-technical breaking changes are applied to libc #1154
Conversation
(rust_highfive has picked a reviewer for you, use r? to override) |
So I've made a commit that does an API breaking change, and the error messages are pretty good: https://travis-ci.org/rust-lang/libc/jobs/460316258#L384
I still need to fix a couple of issues with
I'm closing the PR until I fix at least the return value and the version bump. |
Wow this seems quite promising though! |
The main problem that I don't know how to solve is that this requires compiling |
FYI this is still just a proof-of-concept test, but I think I fixed all of the blocking bugs in rust-semverver and rustc to make this reliable enough for production usage. |
So the |
c62e757
to
0d52a96
Compare
So I've added support for @semarie we can only detect semver breaking API changes for targets that ship a standard component with rustup. AFAICT the openbsd targets don't do that yet. I think it is now possible to ship a |
I've rebased to something that we could merge @alexcrichton . This PR uses rust-semverver to compare the PR against the latest crates.io release of Merging this is blocked on the review and merge of my PR to rust-semverver upstream, updating this PR to use a rust-semverver release containing those changes, and clarifying the maintenance of rust-semverver. Right now there is only one maintainer, since the repo was migrated out of the nursery its CI has stopped working, and nightly changes does break this every now and then (just like clippy and rustfmt). So we need to clarify all of this. The tool is not perfect, but it is otherwise quite great. In any case, I've set the build jobs as allowed to fail. We can check to see if they fail, and if so, whether the failure is spurious, or an API breaking change was introduced. Also, we do want to make breaking changes every now and then, what we don't want is to make them by mistake, so it appears to me that allowing these to fail by default is what we would do anyways. |
Sounds like a good plan to me! |
semverver was released with the fixes! @bors: r+ |
📌 Commit d6443f7 has been approved by |
Verify that only non-technical breaking changes are applied to libc Closes #270 . cc @alexcrichton so this would be a solution to #270 that uses rust-semverver to check that the API of `libc` contains only non-technical breaking changes. This is a WIP and uses a fork of `rust-semverver` for now, but I've sent PRs upstream already. This is the only idea I have for solving #270 . `rust-semverver` is not perfect, but it can deal with functions, consts, and simple structs just fine, and that's pretty much everything that libc uses. cc @ibabushkin Some other notes: * we have to compile `rust-semverver` for each toolchain version, and it depends on `cargo` so we have to build ~160 dependencies. Using `cache: cargo` breaks everything.
☀️ Test successful - checks-cirrus, checks-travis, status-appveyor |
Closes #270 .
cc @alexcrichton so this would be a solution to #270 that uses rust-semverver to check that the API of
libc
contains only non-technical breaking changes.This is a WIP and uses a fork of
rust-semverver
for now, but I've sent PRs upstream already. This is the only idea I have for solving #270 .rust-semverver
is not perfect, but it can deal with functions, consts, and simple structs just fine, and that's pretty much everything that libc uses.cc @ibabushkin
Some other notes:
rust-semverver
for each toolchain version, and it depends oncargo
so we have to build ~160 dependencies. Usingcache: cargo
breaks everything.