-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
[WIP] Improve package check git logging and workaround windows issue #5848
[WIP] Improve package check git logging and workaround windows issue #5848
Conversation
Also fixes some tests. However without a fix in git2-rs, this is currently expected to fail tests on windows (only), in informative ways.
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @matklad (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
At 2c22de1 I have improved (try 2) logging that I think shows the fundamental issue in CI on windows: https://ci.appveyor.com/project/rust-lang-libs/cargo/build/1.0.5379/job/1ptroibkr91klwvg#L1660
Where as all tests succeed on not(windows): https://travis-ci.org/rust-lang/cargo/builds/410962431 Compare the windows failure above to the RUST_LOG=debug output on my local linux:
In this latter, success path DEBUG output, the path (derived from trimming the package |
Being new to the project I hadn't noticed an important aspect of the appveyor setup until now. The two windows builds are not GNU vs MSVC, but rather a minimal-versions build vs latest-versions. I've been ignoring the fact that the minimal-versions build has been succeeding, while the latest-versions build has been the one failing! Minimal Versions (SUCCESS)
Latest Versions (FAILS)
Now (just with cargo 28.0) there are plenty of other dependencies different between minimal and latest, see: https://deps.rs/crate/cargo/0.28.0 The ignore crate might also be important here? And joy, there are no release notes and no release tags for that crate between versions 0.4.0 (minimal) and 0.4.3. Oh, the irony, given I got here via #5786. These differences could be incrementally CI tested, if I have the stamina. (edit: splitting remainder to comment below, for clarity) |
The minimal version job on CI just runs |
That is also quite surprising, but I can confirm it. Thanks for the time saving tip, @Eh2406. Unfortunately it doesn't exclude the possibility that this is a dependency regression, it just invalidates the above evidence. Sigh this task would be much more suited to someone with a windows development setup. Here they could just take this branch with a custom lock file to test recent but older versions. |
I am a windows based life form. If you give me cleare instructions I can help. |
Narrowly regarding the CI setup, I can read through the lines that there must be some failing due to complications with actually building and running tests for the minimal versions, but can Appveyor not be setup in a similar fashon to Travis with a minimal-version + test build config that is allowed to fail (e.g. MAY_FAIL), without failing the entire set of Travis/Appveyor builds? That would be helpful in this instance at least. Edit: further info https://www.appveyor.com/docs/build-configuration/#allow-failing-jobs Has this been considered? @dwijnand? |
With latest additional verbosity of 5fc271f, windows (git2 v0.7.4 libgit2-sys v0.7.7) fails with: https://ci.appveyor.com/project/rust-lang-libs/cargo/build/1.0.5383/job/71165ym65al26lpo#L1660
Being in the enviable position of testing this via Appveyor CI with ~20 minute build delay, I don't have the full debug output and I'm reluctant to hack that into CI via a commit. As poor substitute, RUST_LOG=debug output on my local linux:
Given the above windows output, I don't think the root cause it just the mix of forward and back slash paths. The calculated repo-relative-path @alexcrichton @ehuss @Eh2406 can you look at this latest windows output above and let me know if anything comes to mind, either for fixing in git2-rs or as a workaround here with current versions? Thanks! |
It might be beneficial to have a little Windows VirtualBox to iterate on. |
I will run tests locally and investigat, when my |
I was able to repro locally! I was able to make the test pass with the addition of So It looks like it is just the |
Great thanks @Eh2406! I think your workaround is better than the one I originally, haphazardly found in #5820. But if alexcrichton/git2-rs#341 is close to being merged/released then it may not be worth applying that? Also @Eh2406, since you saw my changes, would you be supportive of me pursuing a final PR for the logging+test improvements on this here? As in 65ded47, so its not quite so verbose. Any feedback? |
https://github.com/alexcrichton/git2-rs/issues/334 had a 2 day tern around time, from my PR until a new version was out. So, I'd guess we can whate for it to land. I generally like more logging! But, this is not a part of the code where I am expert enough to give advice. |
Closing in preference to #5858. |
This is a second attempt at diagnostic logging leading to an eventual clear workaround for #5823.
This is a Work In Progress. Without a root-cause fix (in git2-rs or elsewhere), this is currently expected to fail tests on windows (and windows-only), but in informative ways.