Skip to content

Conversation

Aaron1011
Copy link
Contributor

This removes the implicit dependency on the environment variables set
when running ./x.py test

This removes the implicit dependency on the environment variables set
when running `./x.py test`
@rust-highfive
Copy link
Contributor

r? @nikomatsakis

(rust_highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Oct 2, 2019
@Aaron1011
Copy link
Contributor Author

We might want to consider setting RUST_BACKTRACE=1 on CI to catch this kind of issue. This isn't the first time that running ./x.py test with RUST_BACKTRACE=1 has been broken by this kind of implicit dependency.

Alternatively, we could sanitize the environment variables used when running test - if something isn't set by a compile-test flag, then the test probably shouldn't be using it (excluding RUSTFLAGS, probably)

@Mark-Simulacrum
Copy link
Member

I believe RUST_BACKTRACE=1 can have nonzero (and fairly significant) overhead on runtimes, or at least, we've had reports of such in the past, so I would be hesitant to set it on CI by default. I feel like fixing this when it comes up is not too hard (and it'd be good to document this in compiletest). I'd probably be fine with tests implicitly sanitizing RUST_BACKTRACE though so long as we have the two overrides: the test can manually say "always run me with, or without, a backtrace" and an override that globally sets RUST_BACKTRACE to something bypassing sanitization, though not the test-specific override probably.

@nikomatsakis
Copy link
Contributor

@bors r+

(what @Mark-Simulacrum said)

@bors
Copy link
Collaborator

bors commented Oct 3, 2019

📌 Commit a336536 has been approved by nikomatsakis

@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 Oct 3, 2019
tmandry added a commit to tmandry/rust that referenced this pull request Oct 3, 2019
…ikomatsakis

Set RUST_BACKTRACE=0 in tests that include a backtrace in stderr

This removes the implicit dependency on the environment variables set
when running `./x.py test`
tmandry added a commit to tmandry/rust that referenced this pull request Oct 3, 2019
…ikomatsakis

Set RUST_BACKTRACE=0 in tests that include a backtrace in stderr

This removes the implicit dependency on the environment variables set
when running `./x.py test`
bors added a commit that referenced this pull request Oct 3, 2019
Rollup of 11 pull requests

Successful merges:

 - #61879 (Stabilize todo macro)
 - #64675 (Deprecate `#![plugin]` & `#[plugin_registrar]`)
 - #64690 (proc_macro API: Expose `macro_rules` hygiene)
 - #64706 (add regression test for #60218)
 - #64741 (Prevent rustdoc feature doctests)
 - #64842 (Disallow Self in type param defaults of ADTs)
 - #65004 (Replace mentions of IRC with Discord)
 - #65018 (Set RUST_BACKTRACE=0 in tests that include a backtrace in stderr)
 - #65055 (Add long error explanation for E0556)
 - #65056 (Make visit projection iterative)
 - #65057 (typo: fix typo in E0392)

Failed merges:

r? @ghost
@bors bors merged commit a336536 into rust-lang:master Oct 4, 2019
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.

5 participants