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

Actually add rustc-guide to toolstate, don't fail builds for the guide #62759

Merged
merged 12 commits into from
Jul 28, 2019

Conversation

mark-i-m
Copy link
Member

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jul 17, 2019
@@ -88,7 +89,6 @@ status_check() {
# these tools are not required for beta to successfully branch
check_dispatch $1 nightly miri src/tools/miri
check_dispatch $1 nightly embedded-book src/doc/embedded-book
check_dispatch $1 nightly rustc-guide src/doc/rustc-guide
Copy link
Member

@kennytm kennytm Jul 18, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Put this back. This line only verifies that if you have updated rustc-guide the test must pass, and the nightly argument already excluded it from being checked in the beta branch.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel it would be beneficial to remove it. If I include rustc-guide in an update, but it fails due to some transient error, I would prefer if that didn't fail the build. Generally, I think bad links in rustc-guide should not prevent it from being updated.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Disagreed.

If it is really a transient failure you could just @bors retry.

If the link is an actual bad link it could simply be updated or removed.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It takes time to investigate why something failed. It involves loading log files. It involves investigating if it is transient or legitimate. It requires time to remove from a PR, and reporting issues. These are all things I do not want to do. Particularly for rustc-guide, which is not really published from here (I love rustc-guide BTW, don't get me wrong). No other documentation checks external links, and I don't think it is a good idea to gate on it.

If it is enforced, I probably won't include rustc-guide in book updates. Someone else can submit updates for it. I apologize for sounding curt, but I just don't want to spend my time on it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we don't care about whether a link failed why do we add a linkchecker? Ignoring the alarm isn't good.

Besides, not gating on it is even worse for debugging since the maintainer of rustc-guide would now need to dig the log archive to get the error message. While with gating at least the Rust-Log-Analyzer could help you extract the relevant logs. If you don't want to investigate you could just mention the rustc-guide maintainer. Since other books are already gated on doc-tests you do need to investigate the log to find out which book is broken anyway.

Furthermore you seem to be exaggerating the probability of spurious external link failure.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AFAIK without this line, there's basically no toolstate tracking happening at all, or is there?

The status is saved in the local toolstate file by the call to x.py test at the top of the file (save-toolstates is set in config.toml). The publishing is done at the bottom (commit_toolstate_change).

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So @ehuss @mark-i-m how can we proceed here? Personally I agree with @kennytm and, as @mark-i-m said, "not gating update PRs on this might be less helpful because the status would just remain broken". If a PR updates this submodule and tests still don't pass, surely something is wrong with that PR?

If you have spuriously failing tests, the precedent with RLS is to disable/ignore those tests on your side so that at least the other tests can still do their job.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I said, I'm fine adding it back and seeing how it goes. I just don't want to spend much time dealing with failures going forward.

I personally don't think a failure indicates a problem with the PR. It just indicates the problem hasn't been fixed, yet. A PR that updates a broken rustc-guide when it remains broken doesn't make the problem worse, it's already broken. Making me take time to remove it from the PR doesn't magically make it fixed, it just takes my time, with no benefit for anyone.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They way I see it, allowing tools/doctests to fail at all is a concession to the fact that synchronized updates are hard. But really a failing tool is not an acceptable state. If you are updating a tool and your tests are failing, that should be rejected just like when you are updating rustc and tests are failing.

Making sure tests pass is not a waste of time, it is a basic part of software maintenance.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I said, I'm fine adding it back and seeing how it goes. I just don't want to spend much time dealing with failures going forward.

Thank you :) I will add it back. If it fails again, feel free to just drop rustc-guide and I can investigate.

If you have spuriously failing tests, the precedent with RLS is to disable/ignore those tests on your side so that at least the other tests can still do their job.

Yes, this is the approach I have been taking with rust-lang/rustc-dev-guide#388. Also, Michael-F-Bryan re-wrote the linkchecker to take better advantage of caching, and maybe it will have more flexible handling of timeouts and server errors later too, so hopefully spurious failures will be less common in the future too.

src/ci/docker/x86_64-gnu-tools/checkregression.py Outdated Show resolved Hide resolved
src/ci/docker/x86_64-gnu-tools/checkregression.py Outdated Show resolved Hide resolved
@RalfJung
Copy link
Member

I opened a PR for this PR at mark-i-m#1, with some comments for stuff I figured out while doing my research for #62266.

mark-i-m and others added 2 commits July 18, 2019 08:42
mark-i-m and others added 2 commits July 18, 2019 08:57
Co-Authored-By: Ralf Jung <post@ralfj.de>
Co-Authored-By: Ralf Jung <post@ralfj.de>
@mark-i-m
Copy link
Member Author

Ok, I'm now fairly confused about which lines to change in which files, but unfortunately, I don't have time to try to understand how these things work. I'm just going to wait for the discussion to settle and see what the consensus is...

Co-Authored-By: kennytm <kennytm@gmail.com>
@rust-highfive
Copy link
Collaborator

Your PR failed (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.
2019-07-18T17:21:07.2293493Z ##[command]git remote add origin https://github.com/rust-lang/rust
2019-07-18T17:21:07.2479688Z ##[command]git config gc.auto 0
2019-07-18T17:21:07.8169277Z ##[command]git config --get-all http.https://github.com/rust-lang/rust.extraheader
2019-07-18T17:21:07.8173642Z ##[command]git config --get-all http.proxy
2019-07-18T17:21:07.8178426Z ##[command]git -c http.extraheader="AUTHORIZATION: basic ***" fetch --force --tags --prune --progress --no-recurse-submodules --depth=2 origin +refs/heads/*:refs/remotes/origin/* +refs/pull/62759/merge:refs/remotes/pull/62759/merge
---
2019-07-18T17:21:41.3933183Z do so (now or later) by using -b with the checkout command again. Example:
2019-07-18T17:21:41.3933214Z 
2019-07-18T17:21:41.3933369Z   git checkout -b <new-branch-name>
2019-07-18T17:21:41.3933409Z 
2019-07-18T17:21:41.3933445Z HEAD is now at a00c43f87 Merge 1aa10797df9ef70bd08011811d6a822a7b58e1a3 into 4ed008a420d725d9543d14acd0f7078a77b8bd16
2019-07-18T17:21:41.4064503Z ##[section]Starting: Collect CPU-usage statistics in the background
2019-07-18T17:21:41.4067695Z ==============================================================================
2019-07-18T17:21:41.4067775Z Task         : Bash
2019-07-18T17:21:41.4067822Z Description  : Run a Bash script on macOS, Linux, or Windows
---
2019-07-18T17:24:15.6468080Z Attempting with retry: docker build --rm -t rust-ci -f /home/vsts/work/1/s/src/ci/docker/x86_64-gnu-llvm-6.0/Dockerfile /home/vsts/work/1/s/src/ci/docker
2019-07-18T17:24:15.8441903Z Sending build context to Docker daemon  521.7kB
2019-07-18T17:24:15.8442698Z 
2019-07-18T17:24:15.8661616Z Step 1/8 : FROM ubuntu:16.04
2019-07-18T17:24:16.6166730Z Get https://registry-1.docker.io/v2/library/ubuntu/manifests/16.04: received unexpected HTTP status: 500 Internal Server Error
2019-07-18T17:24:17.7327262Z Sending build context to Docker daemon  521.7kB
2019-07-18T17:24:17.7327373Z 
2019-07-18T17:24:17.7558841Z Step 1/8 : FROM ubuntu:16.04
2019-07-18T17:24:17.7558841Z Step 1/8 : FROM ubuntu:16.04
2019-07-18T17:24:18.4177116Z Get https://registry-1.docker.io/v2/library/ubuntu/manifests/16.04: received unexpected HTTP status: 500 Internal Server Error
2019-07-18T17:24:21.2229265Z Sending build context to Docker daemon  521.7kB
2019-07-18T17:24:21.2229964Z 
2019-07-18T17:24:21.2501426Z Step 1/8 : FROM ubuntu:16.04
2019-07-18T17:24:21.2501426Z Step 1/8 : FROM ubuntu:16.04
2019-07-18T17:24:21.8966071Z Get https://registry-1.docker.io/v2/library/ubuntu/manifests/16.04: received unexpected HTTP status: 500 Internal Server Error
2019-07-18T17:24:25.0164748Z Sending build context to Docker daemon  521.7kB
2019-07-18T17:24:25.0165396Z 
2019-07-18T17:24:25.0393904Z Step 1/8 : FROM ubuntu:16.04
2019-07-18T17:24:25.0393904Z Step 1/8 : FROM ubuntu:16.04
2019-07-18T17:24:25.6742477Z Get https://registry-1.docker.io/v2/library/ubuntu/manifests/16.04: received unexpected HTTP status: 500 Internal Server Error
2019-07-18T17:24:29.7493295Z Sending build context to Docker daemon  521.7kB
2019-07-18T17:24:29.7494211Z 
2019-07-18T17:24:29.7783268Z Step 1/8 : FROM ubuntu:16.04
2019-07-18T17:24:29.7783268Z Step 1/8 : FROM ubuntu:16.04
2019-07-18T17:24:30.4018457Z Get https://registry-1.docker.io/v2/library/ubuntu/manifests/16.04: received unexpected HTTP status: 500 Internal Server Error
2019-07-18T17:24:30.4031140Z The command has failed after 5 attempts.
2019-07-18T17:24:30.4142949Z ##[error]Bash exited with code '1'.
2019-07-18T17:24:30.4170956Z ##[section]Starting: Checkout
2019-07-18T17:24:30.4173037Z ==============================================================================
2019-07-18T17:24:30.4173148Z Task         : Get sources
2019-07-18T17:24:30.4173200Z Description  : Get sources from a repository. Supports Git, TfsVC, and SVN repositories.

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

@mark-i-m
Copy link
Member Author

It looks like the CI failure is spurious?

Step 1/8 : FROM ubuntu:16.04
Get https://registry-1.docker.io/v2/library/ubuntu/manifests/16.04: received unexpected HTTP status: 500 Internal Server Error
The command has failed after 5 attempts.

@mark-i-m
Copy link
Member Author

I honestly don't know what the state of this is. Is it waiting for me?

@kennytm
Copy link
Member

kennytm commented Jul 21, 2019

I'm waiting for #62759 (review) to be resolved.

@kennytm
Copy link
Member

kennytm commented Jul 24, 2019

@bors r+

@bors
Copy link
Contributor

bors commented Jul 24, 2019

📌 Commit 11a3b74 has been approved by kennytm

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jul 24, 2019
@bors
Copy link
Contributor

bors commented Jul 28, 2019

⌛ Testing commit 11a3b74 with merge f3ad8ef...

bors added a commit that referenced this pull request Jul 28, 2019
Actually add rustc-guide to toolstate, don't fail builds for the guide

cc @ehuss

r? @kennytm
Centril added a commit to Centril/rust that referenced this pull request Jul 28, 2019
…k, r=kennytm

Actually add rustc-guide to toolstate, don't fail builds for the guide

cc @ehuss

r? @kennytm
@Centril
Copy link
Contributor

Centril commented Jul 28, 2019

@bors retry rolled up.

bors added a commit that referenced this pull request Jul 28, 2019
Rollup of 4 pull requests

Successful merges:

 - #62550 (Implement RFC 2707 + Parser recovery for range patterns)
 - #62759 (Actually add rustc-guide to toolstate, don't fail builds for the guide)
 - #62809 (rustc: Update wasm32 support for LLVM 9)
 - #62974 (bump crossbeam-epoch dependency)

Failed merges:

r? @ghost
Centril added a commit to Centril/rust that referenced this pull request Jul 28, 2019
…k, r=kennytm

Actually add rustc-guide to toolstate, don't fail builds for the guide

cc @ehuss

r? @kennytm
bors added a commit that referenced this pull request Jul 28, 2019
Rollup of 8 pull requests

Successful merges:

 - #62550 (Implement RFC 2707 + Parser recovery for range patterns)
 - #62759 (Actually add rustc-guide to toolstate, don't fail builds for the guide)
 - #62806 (Fix few Clippy warnings)
 - #62974 (bump crossbeam-epoch dependency)
 - #63051 (Avoid ICE when referencing desugared local binding in borrow error)
 - #63061 (In which we constantly improve the Vec(Deque) array PartialEq impls)
 - #63067 (Add test for issue-50900)
 - #63071 (Allow rustbot to add `F-*` + `requires-nightly`.)

Failed merges:

r? @ghost
@bors bors merged commit 11a3b74 into rust-lang:master Jul 28, 2019
@ehuss
Copy link
Contributor

ehuss commented Jul 30, 2019

Note: Toolstate status currently isn't working due to an unrelated problem with toolstate publishing, so rustc-guide is currently in test-fail state. I looked at updating it, but it looks like it is still broken.

Error: there are broken links
	Caused By: "https://github.com/rust-lang/compiler-team/blob/master/content/docs/experts/map.toml" returned 404 Not Found
	Caused By: "https://github.com/rust-lang/rust/tree/master/src/test/run-pass/" returned 404 Not Found
	Caused By: "https://github.com/rust-lang/rust/blob/master/src/test/run-pass/weird-exprs.rs" returned 404 Not Found

@mark-i-m mark-i-m deleted the rustc-guide-toolstate-check branch December 11, 2019 21:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants