Comments (13)
No. At the time I was busy getting a PR done and now I don't have a reproducing example any more.
from rust.
#111769 only checks for ctrl-c during const eval, so if no const eval runs for an extended period of time, the ctrl-c will be silently ignored. This is not the only problem with that PR. It also caused #124265, and shows the "compilation was interrupted" error after the prompt is already drawn by bash.
from rust.
Yeah, just take any
I-hang
I can reproduce this issue with #122443 for example:
- nightly-2024-03-26 (before #111769): Exits after a single ^C
- nightly-2024-03-27 (after #111769): Requires ^C^C to exit
bjorn3's analysis checks out.
from rust.
Do you have a reproducer? I have not run into this myself.
The implementation should also ensure that the compiler exits promptly if you hit ctrl+c again. Does it?
from rust.
if stuff keeps going on ctrl+c, sometimes suspending the process (ctrl+z) and then killing the terminal does the trick somehow 😅
from rust.
Do you have a reproducer? I have not run into this myself.
Unfortunately no, I encountered this during some rustc hacking where I ended up getting well over 1k error messages in the standard library build and that turned out to be hard to cancel.
The implementation should also ensure that the compiler exits promptly if you hit ctrl+c again. Does it?
I thought I had tried that, but I am not entirely sure.
from rust.
Is it possible the shell is part of the problem? If, by the time you hit ctrl-c, it's working through a large amount of output it still has buffered then it might be awhile before you see a response.
from rust.
It's possible, sure -- but usually it reacts to Ctrl-C immediately even when there's tons of output.
from rust.
Have you tried reverting #111769 to check if that fixes it?
from rust.
is there a good way to make rustc loop endlessly without ever touching const eval? maybe via the trait solver? 🤔
it would help for debugging this.
from rust.
cool! I wasn't sure how much of the compiler's code flowed through const-eval, is why I asked.
from rust.
Another case where this is observed: #125428
IMO we should revert #111769 or at least make the signal handler run exit
after a short timeout.
from rust.
I'll post a PR that adds a timeout later today, but by all means if you feel strongly just put up a PR. The initial handler here was just added through the normal PR process, there's no reason to be more cautious on reverting or modifying it.
from rust.
Related Issues (20)
- rustdoc leaks private types in Implementations on Foreign Types HOT 1
- bootstrap: `profile = "tools"` contains incompatible options. HOT 2
- ICE "Failed to extract DefId" HOT 1
- Request for `tune-cpu` code generation option to be promoted to stable HOT 2
- ICE: `ConstArgHasType(^0, usize)` has escaping bound vars, so it cannot be wrapped in a dummy binder. HOT 2
- ICE: `only 'variances_of' returns '&[ty::Variance]'`
- ICE. `try_from_lit: received const param which shouldn't be possible` HOT 3
- unreachable!("state is never set to invalid values") is reached HOT 53
- ICE in the face of malformed code HOT 2
- array::IntoIter::new deprecation warning suggestion may lead to compilation error on 2015 and 2018 editions HOT 2
- CStr::from_ptr() crashes the program with a segfault when loading a string from memory after passing it in a global_asm!() function. HOT 6
- `tool::prepare_tool_cargo` should run `builder.ensure` automatically, based on tool mode HOT 4
- ICE: `adding a def'n for node-id NodeId(18) and def kind AnonConst but a previous def'n exists` HOT 9
- Doctests cannot recognize paths that lead to a type in the crate root HOT 3
- `./x check std` should not try to check `no_std` targets HOT 2
- Tracking Issue for unsized const parameter types: `feature(unsized_const_params)`
- Some invalid cargo cache data leads to ICE
- Goofy suggestion when trying to use a raw ptr receiver and also the self keyword in the body HOT 1
- Tracking Issue for Contracts
- Vetting 3rd party crates for supply-chain-security issues
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rust.