-
Notifications
You must be signed in to change notification settings - Fork 309
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
Called 'Option::unwrap()' on a 'None' in minibuffer. #1498
Comments
Fun. |
Thanks for the investigation, I'll take a look. |
This reminds me of a need that (r)emacs has. There should be a simple, obvious way to say "start emacs with this config". Something like |
This bug seems to actually be in |
hmmm, ok. That is not entirely what I expected from the messages in your screen shot. But the error message is there. We all wait for the next installment...... |
Yeah, this is turning out to be quite bizarre. I'm a bit confused by the minbuffer output when adding |
Essentially, I really need a way to get the full error output instead of what seems like terminal output interspersed with actual minibuffer messages. |
I usually load the editor in a debugger once I know where the issue is. A useful hack is to duplicate the Rust function and rename it. Then you can control when and how it is called. The file Also, try |
I'm still getting terminal output when I explicitly request it, the issue is that the panic messages are getting caught and squashed by other minibuffer output. |
Took a quick look at this, using the most recent commit as of today. I can't seem to replicate this bug. I can only trigger this error if I explicitly invoke the relevant lisp code I also get the following errors when I load the given
So maybe the issue is with one of the above libraries (but I doubt it). For the record, I invoked remacs like so: ./remacs -Q --eval '(progn (setq user-emacs-directory "/home/james/remacs-build/1498/" user-init-file "/home/james/remacs-build/1498/init.el") (load user-init-file))' |
Thanks for checking it out. Those errors are in fact benign. How did you determine the root cause as being In any case, I'm seeing an error, albeit less of one. Now the visible part of the error I see is just |
Since I didn't include repro steps in the original issue this is what I'm doing.
|
Oh, interesting, as soon as I try to split the scratch buffer I see the error with
(sic, typos and missing spaces are part of the above error message) Same error happens if I try to delete a window or move to a window. The only lazy static I see in lazy_static! {
static ref RNG: Mutex<StdRng> = Mutex::new(StdRng::from_entropy());
} But that's only used for the In any case, I agree that perhaps the more fundamental bug is that these error messages are being dropped silently. These errors do not show up in |
There seems to be a common thread here of bizarre error messages that seem to be pointing to the wrong part of the source, and the stream for that error being eaten by the minibuffer. Not totally sure how to make Remacs really panic and give me the whole stacktrace, so I may have to venture into GDB-land, where I was loath to poke my head before. In any case thanks for all the help corroborating. |
Possibilities:
|
re: Rust traces:
Add liberal asserts or panic! to the code. |
On linux, learn to use https://rr-project.org/. It is super helpful. On OSX I find lldb to give better answers. |
For the record, fixing some font bugs makes this error message change (see #1512). Now I'm getting In any case, I think I know why these error messages aren't showing up anywhere. They are coming along with special events which are explicitly never echoed: https://www.gnu.org/software/emacs/manual/html_node/elisp/Special-Events.html#Special-Events -- I did not know about these, this is new to me. So the following diff makes these messages show up. (Not a fix, this is just so I can finally see these errors in @@ -367,7 +367,7 @@ pub fn read_event(
seconds: LispObject,
) -> LispObject {
if !prompt.is_nil() {
- message_with_string!("%s", prompt, false);
+ message_with_string!("%s", prompt, true);
}
unsafe { read_filtered_event(false, false, false, !inherit_input_method.is_nil(), seconds) } Also, on a tangential note, I can't seem to get Emacs' |
I've run into this before. In order to preserve the correct replay behavior, rr must prevent the state of the program from diverging from the recording. Thus, any gdb command which writes to memory (or might do so), needs to be coerced into writing to freshly-allocated memory which can then be thrown away after the command is done. That's the "diversion area" that the error mentions. In this case, the alias that pretty-prints things is setting the I'm sure I had fixed this in my .gdbinit file, and I thought I had committed the fix. Either way, here's my conversation with roc on the subject:
|
My init.el
Packages that may have something to do with the error are
golden-ratio
,ido-everywhere
,ido-completing-read+
, orswitch-window
.The text was updated successfully, but these errors were encountered: