* Emacs hangs sometimes for no reason @ 2017-01-14 18:33 Sebastian Christ 2017-01-14 18:42 ` Nicolas Goaziou 2020-02-11 12:32 ` Karl Voit 0 siblings, 2 replies; 19+ messages in thread From: Sebastian Christ @ 2017-01-14 18:33 UTC (permalink / raw) To: emacs-orgmode Hi list, in the last couple weeks (perhaps months?) Emacs hangs for no specific reason for me. The single constant is, that when it hangs, it hangs while I'm in org-mode. This occurs on multiple circumstance as - changing the outline structure by demoting and promoting headline - when refiling - re-schedule in agenda - yanking - perhaps more The strange thing is that it happens unpredictably, e.g. I re-schedule 11 items without problems and the 12th one lets Emacs crash. Sometimes it works for days without problems and then I promote a headline and Emacs crashes. Very sad :( When I kill Emacs with $ pkill -SIGUSR2 Emacs this leaves me in the Emacs debugger in a flyspell function or (today) in a avl-tree function. My actual question is, had someone had similar issues? Or is it just me with my configuration? Perhaps someone can guide me on how I can find the root cause for this? I pretty much lost here. Thanks in advance for any hints. Best, Sebastian -- Sebastian (Rudolfo) Christ http://rudolfochrist.github.io GPG Fingerprint: 306D 8FD3 DFB6 4E44 5061 CE71 6407 D6F8 2AC5 55DD ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-14 18:33 Emacs hangs sometimes for no reason Sebastian Christ @ 2017-01-14 18:42 ` Nicolas Goaziou 2017-01-14 19:38 ` Samuel Wales 2017-01-15 8:49 ` Sebastian Christ 2020-02-11 12:32 ` Karl Voit 1 sibling, 2 replies; 19+ messages in thread From: Nicolas Goaziou @ 2017-01-14 18:42 UTC (permalink / raw) To: Sebastian Christ; +Cc: emacs-orgmode Hello, Sebastian Christ <rudolfo.christ@gmail.com> writes: > in the last couple weeks (perhaps months?) Emacs hangs for no specific > reason for me. The single constant is, that when it hangs, it hangs > while I'm in org-mode. This occurs on multiple circumstance as > > - changing the outline structure by demoting and promoting headline > - when refiling > - re-schedule in agenda > - yanking > - perhaps more > > The strange thing is that it happens unpredictably, e.g. I re-schedule > 11 items without problems and the 12th one lets Emacs crash. Sometimes > it works for days without problems and then I promote a headline and > Emacs crashes. Very sad :( > > When I kill Emacs with > > $ pkill -SIGUSR2 Emacs > > this leaves me in the Emacs debugger in a flyspell function or (today) > in a avl-tree function. > > My actual question is, had someone had similar issues? Or is it just me > with my configuration? > > Perhaps someone can guide me on how I can find the root cause for this? > I pretty much lost here. This could be related to Org cache. I know the cache can become corrupted upon modifying outline structure of a document. Unfortunately, I couldn't come with a small enough recipe to reproduce the exact problem. You could try to set `org-element-use-cache' to nil and see if the hangs disappear. Regards, -- Nicolas Goaziou ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-14 18:42 ` Nicolas Goaziou @ 2017-01-14 19:38 ` Samuel Wales 2017-01-15 8:52 ` Sebastian Christ 2017-01-15 8:49 ` Sebastian Christ 1 sibling, 1 reply; 19+ messages in thread From: Samuel Wales @ 2017-01-14 19:38 UTC (permalink / raw) To: Nicolas Goaziou; +Cc: Sebastian Christ, emacs-orgmode fwiw, i have had the element cache turned off since org 8 because of intermittent bugs. i tried it on in org 9 maint recently and it caused similar problems. so you might be experiencing same. funnily enough, it doesn't seem to make any difference to agenda creation speed, which is my bottleneck. >> My actual question is, had someone had similar issues? Or is it just me >> with my configuration? ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-14 19:38 ` Samuel Wales @ 2017-01-15 8:52 ` Sebastian Christ 0 siblings, 0 replies; 19+ messages in thread From: Sebastian Christ @ 2017-01-15 8:52 UTC (permalink / raw) To: emacs-orgmode >>>>> "SW" == Samuel Wales <samologist@gmail.com> writes: SW> fwiw, i have had the element cache turned off since org 8 SW> because of intermittent bugs. i tried it on in org 9 maint SW> recently and it caused similar problems. so you might be SW> experiencing same. SW> funnily enough, it doesn't seem to make any difference to agenda SW> creation speed, which is my bottleneck. Nicolas Goaziou suggested the same thing. I'll try this an report back. Thanks. /src -- Sebastian (Rudolfo) Christ http://rudolfochrist.github.io GPG Fingerprint: 306D 8FD3 DFB6 4E44 5061 CE71 6407 D6F8 2AC5 55DD ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-14 18:42 ` Nicolas Goaziou 2017-01-14 19:38 ` Samuel Wales @ 2017-01-15 8:49 ` Sebastian Christ 1 sibling, 0 replies; 19+ messages in thread From: Sebastian Christ @ 2017-01-15 8:49 UTC (permalink / raw) To: Nicolas Goaziou; +Cc: emacs-orgmode >>>>> "NG" == Nicolas Goaziou <mail@nicolasgoaziou.fr> writes: NG> You could try to set `org-element-use-cache' to nil and see if NG> the hangs disappear. I'll try this. Thank you very much. /src -- Sebastian (Rudolfo) Christ http://rudolfochrist.github.io GPG Fingerprint: 306D 8FD3 DFB6 4E44 5061 CE71 6407 D6F8 2AC5 55DD ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-14 18:33 Emacs hangs sometimes for no reason Sebastian Christ 2017-01-14 18:42 ` Nicolas Goaziou @ 2020-02-11 12:32 ` Karl Voit 2020-02-11 22:23 ` briangpowell . 1 sibling, 1 reply; 19+ messages in thread From: Karl Voit @ 2020-02-11 12:32 UTC (permalink / raw) To: emacs-orgmode * Sebastian Christ <rudolfo.christ@gmail.com> wrote: > Hi list, > > in the last couple weeks (perhaps months?) Emacs hangs for no specific > reason for me. The single constant is, that when it hangs, it hangs > while I'm in org-mode. This occurs on multiple circumstance as > > - changing the outline structure by demoting and promoting headline > - when refiling > - re-schedule in agenda > - yanking > - perhaps more Same here with 3 different Emacs versions. > The strange thing is that it happens unpredictably, e.g. I re-schedule > 11 items without problems and the 12th one lets Emacs crash. Sometimes > it works for days without problems and then I promote a headline and > Emacs crashes. Very sad :( I did not have a crash here, though. > My actual question is, had someone had similar issues? Or is it just me > with my configuration? > > Perhaps someone can guide me on how I can find the root cause for this? > I pretty much lost here. > > Thanks in advance for any hints. In a discussion on Org/Emacs scalability issues, I got a hint[1] to use gcmh.el which indicates garbage collecting activity. My freeze-moments are almost entirely related to garbage collecting. You might want to try that. I've got no solution or workaround so far. [1] https://www.reddit.com/r/orgmode/comments/e9p84n/scaling_org_better_to_use_more_medsize_files_or/fcm5bsc/ -- get mail|git|SVN|photos|postings|SMS|phonecalls|RSS|CSV|XML into Org-mode: > get Memacs from https://github.com/novoid/Memacs < Personal Information Management > http://Karl-Voit.at/tags/pim/ Emacs-related > http://Karl-Voit.at/tags/emacs/ ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2020-02-11 12:32 ` Karl Voit @ 2020-02-11 22:23 ` briangpowell . 2020-02-12 9:09 ` Karl Voit 0 siblings, 1 reply; 19+ messages in thread From: briangpowell . @ 2020-02-11 22:23 UTC (permalink / raw) To: Karl Voit; +Cc: emacs-orgmode [-- Attachment #1: Type: text/plain, Size: 2202 bytes --] Emacs periodically saves all files that you are visiting; this is called auto-saving . Auto-saving prevents you from losing more than a limited amount of work if the system crashes. By default, auto-saves happen every 300 keystrokes, or after around 30 seconds of idle time. Suggest you try making your auto-save-interval variable much larger and see if that helps Also suggest making smaller .org files when practical On Tue, Feb 11, 2020 at 7:33 AM Karl Voit <devnull@karl-voit.at> wrote: > * Sebastian Christ <rudolfo.christ@gmail.com> wrote: > > Hi list, > > > > in the last couple weeks (perhaps months?) Emacs hangs for no specific > > reason for me. The single constant is, that when it hangs, it hangs > > while I'm in org-mode. This occurs on multiple circumstance as > > > > - changing the outline structure by demoting and promoting headline > > - when refiling > > - re-schedule in agenda > > - yanking > > - perhaps more > > Same here with 3 different Emacs versions. > > > The strange thing is that it happens unpredictably, e.g. I re-schedule > > 11 items without problems and the 12th one lets Emacs crash. Sometimes > > it works for days without problems and then I promote a headline and > > Emacs crashes. Very sad :( > > I did not have a crash here, though. > > > My actual question is, had someone had similar issues? Or is it just me > > with my configuration? > > > > Perhaps someone can guide me on how I can find the root cause for this? > > I pretty much lost here. > > > > Thanks in advance for any hints. > > In a discussion on Org/Emacs scalability issues, I got a hint[1] to use > gcmh.el which indicates garbage collecting activity. My > freeze-moments are almost entirely related to garbage collecting. > > You might want to try that. > > I've got no solution or workaround so far. > > [1] > https://www.reddit.com/r/orgmode/comments/e9p84n/scaling_org_better_to_use_more_medsize_files_or/fcm5bsc/ > > -- > get mail|git|SVN|photos|postings|SMS|phonecalls|RSS|CSV|XML into Org-mode: > > get Memacs from https://github.com/novoid/Memacs < > Personal Information Management > http://Karl-Voit.at/tags/pim/ > Emacs-related > http://Karl-Voit.at/tags/emacs/ > > > [-- Attachment #2: Type: text/html, Size: 3231 bytes --] ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2020-02-11 22:23 ` briangpowell . @ 2020-02-12 9:09 ` Karl Voit 0 siblings, 0 replies; 19+ messages in thread From: Karl Voit @ 2020-02-12 9:09 UTC (permalink / raw) To: emacs-orgmode * briangpowell . <briangpowellms@gmail.com> wrote: > > Emacs periodically saves all files that you are visiting; this is called > auto-saving . Auto-saving prevents you from losing more than a limited > amount of work if the system crashes. By default, auto-saves happen every > 300 keystrokes, or after around 30 seconds of idle time. > > Suggest you try making your auto-save-interval variable much larger and see > if that helps I had to disable auto-save because I'm using org-crypt which would leak sensitive information to my disk (+ git repository). I'm using real-auto-save instead. > Also suggest making smaller .org files when practical Way too late for that ;-) So far, I've found no one with bigger Org files. I plan to blog about small versus big Org files in the upcoming weeks. However, your suggestions are valid points for the general situation. -- get mail|git|SVN|photos|postings|SMS|phonecalls|RSS|CSV|XML into Org-mode: > get Memacs from https://github.com/novoid/Memacs < Personal Information Management > http://Karl-Voit.at/tags/pim/ Emacs-related > http://Karl-Voit.at/tags/emacs/ ^ permalink raw reply [flat|nested] 19+ messages in thread
[parent not found: <375517626d9045a99b6c008b5aaf62dd@HE1PR01MB1898.eurprd01.prod.exchangelabs.com>]
* Re: Emacs hangs sometimes for no reason [not found] <375517626d9045a99b6c008b5aaf62dd@HE1PR01MB1898.eurprd01.prod.exchangelabs.com> @ 2017-01-15 10:56 ` Eric S Fraga 2017-01-15 13:55 ` Stig Brautaset ` (2 more replies) 0 siblings, 3 replies; 19+ messages in thread From: Eric S Fraga @ 2017-01-15 10:56 UTC (permalink / raw) To: emacs-orgmode [-- Attachment #1: Type: text/plain, Size: 597 bytes --] On Saturday, 14 Jan 2017 at 18:33, Sebastian Christ wrote: > in the last couple weeks (perhaps months?) Emacs hangs for no specific > reason for me. The single constant is, that when it hangs, it hangs > while I'm in org-mode. This occurs on multiple circumstance as Just to say that I experience the same. However, I track emacs as well as org so I never know if the problem is emacs or org. In my case, all hangs are when in org mode but that could be because I'm in org mode 90% of the time... :-) -- : Eric S Fraga (0xFFFCF67D), Emacs 26.0.50.1, Org release_9.0.3-201-ga51c6f [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 194 bytes --] ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-15 10:56 ` Eric S Fraga @ 2017-01-15 13:55 ` Stig Brautaset 2017-01-15 14:05 ` Stig Brautaset 2017-01-15 16:34 ` Eric Abrahamsen [not found] ` <e14c1ab631e7438887615a8e568a31f5@DB5PR01MB1895.eurprd01.prod.exchangelabs.com> 2 siblings, 1 reply; 19+ messages in thread From: Stig Brautaset @ 2017-01-15 13:55 UTC (permalink / raw) To: emacs-orgmode Eric S Fraga <e.fraga@ucl.ac.uk> writes: > On Saturday, 14 Jan 2017 at 18:33, Sebastian Christ wrote: >> in the last couple weeks (perhaps months?) Emacs hangs for no specific >> reason for me. The single constant is, that when it hangs, it hangs >> while I'm in org-mode. This occurs on multiple circumstance as > > Just to say that I experience the same. However, I track emacs as well > as org so I never know if the problem is emacs or org. In my case, all > hangs are when in org mode but that could be because I'm in org mode > 90% of the time... :-) Just to say that I too experience the same. I'm convinced it started happening since I upgraded to Org 9 (but I also started using Org's Agenda more around the same time, I think). My versions: - GNU Emacs 25.1.1 (x86_64-apple-darwin13.4.0, NS appkit-1265.21 Version 10.9.5 (Build 13F1911)) of 2016-09-21 - Org mode version 9.0.3 (9.0.3-elpaplus @ - /Users/stig/.emacs.d/elpa/org-plus-contrib-20161224/) I can go a few days without encountering it, but then it will suddenly hit. I have a feeling that it's triggered by refiling, or closing TODOs towards the end of the file. My agenda file is big, but not monstrous. (I think.) C-= reports: "Region has 2025 lines, 9592 words, and 67513 characters." There are 333 headings, most of them TODO/NEXT/PROJECT, and I use lots of tags. I also use a few categories on top-level headings. I've set the following to try to speed up agenda, but it hasn't made any discernible difference as far as I can tell: : (setq org-agenda-use-tag-inheritance '(todo)) I've tried to turn on debug on quit, and sent a few stack traces here in the past but to no avail. I cannot reproduce it with =emacs -q=, but that uses Org 8 anyway, so I would not expect it to. Nor do I have a sure-fire way to reproduce the issue, and I am not keen on being without my regular config for days while hoping to reproduce the hang. I do think it's related to Emacs having run for a while, because once the hang manifests I can just quit Emacs and restart what I was doing and no hang will manifest (for a while). When last I managed to capture a stack trace during one of these the stack trace started with: : Debugger entered--Lisp error: (quit) : avl-tree--do-delete(org-element--cache-compare [[[[[[nil nil : (property-drawer (:begin 18463 :end 18529 :contents-begin 18479 : :contents-end 18519 :post-blank 1 :post-affiliated 18463 :parent nil)) : 0] [nil nil (plain-list (:type unordered :begin 18547 :end 18749 : :contents-begin 18574 :contents-end 18748 :structure ... :post-blank 1 : :post-affiliated 18574 :name "candidate-names" :parent nil)) 0] : (paragraph (:begin 18529 :end 18547 :contents-begin 18529 : :contents-end 18546 :post-blank 1 :post-affiliated 18529 :parent nil)) : 0] [[nil nil (keyword (:key "RESULTS" :value "" :begin 18905 :end : 18920 :post-blank 1 :post-affiliated 18905 :parent nil)) 0] [nil nil : (paragraph (:begin 19570 :end 19586 :contents-begin 19570 : :contents-end 19585 :post-blank 1 :post-affiliated 19570 :parent nil)) : 0] (table (:begin 18920 :end 19570 :type org :tblfm nil : :contents-begin 18920 :contents-end 19568 :value nil :post-blank 2 : :post-affiliated 18920 :parent nil)) 0] (src-block (:language "sh" : :switches nil :parameters ":var names=candidate-names :results table" : :begin 18749 :end 18905 :number-lines nil :preserve-indent nil : :retain-labels t :use-labels t :label-fmt nil :value " echo $names | : xargs -n1 | perl -MList::Util -e : 'print List::Util::shuffle <>'\n" :post-blank 1 :post-affiliated : 18749 :parent nil)) 0 Further, I do notice this stack trace is full of `:drawer-name "LOGBOOK"' entries too, like this: : (:begin 9624 :end 9714 :drawer-name "LOGBOOK" :contents-begin 9638 : :contents-end 9704 :post-blank 0 :post-affiliated 9624 :parent nil)) : 0] [[[[nil nil ... 0] [nil nil ... 0] ... 0] [[nil nil ... 0] [nil nil : ... 0] ... 0] (drawer ...) 0] [[[nil nil ... 0] [nil nil ... 0] ... 0] : [[[nil nil ... 0] nil ... -1] [[nil nil ... 0] [nil nil ... 0] ... 0] : ... 0] (item ...) 1] (drawer (:begin 15202 :end 15582 :drawer-name : "LOGBOOK" :contents-begin 15216 :contents-end 15572 :post-blank 0 : :post-affiliated 15202 :parent nil)) 1] (drawer (:begin 11498 :end : 11629 :drawer-name "LOGBOOK" :contents-begin 11512 :contents-end 11619 : :post-blank 0 :post-affiliated 11498 :parent nil)) 1] (property-drawer : (:begin 7832 :end 7900 :contents-begin 7849 :contents-end 7890 : :post-blank 0 :post-affiliated 7832 :parent nil)) 1] [[[[[[nil nil ... : 0] [nil nil ... 0] ... 0] [[nil nil ... 0] [nil nil ... 0] ... 0] : (src-block ...) 0] [[[nil nil ... 0] [nil nil ... 0] ... 0] [[nil nil : ... 0] [nil nil ... 0] ... 0] (drawer ...) 0] (paragraph (:begin 19586 : :end 19669 :contents-begin 19586 :contents-end 19668 :post-blank 1 : :post-affiliated 19586 :parent nil)) 0] [[[[nil nil ... 0] [nil nil : ... 0] ... 0] [[nil nil ... 0] [nil nil ... 0] ... 0] (drawer ...) 0] : [[[nil nil ... 0] [nil nil ... 0] ... 0] [[nil nil ... 0] [[nil nil : ... 0] nil ... -1] ... 1] (planning ...) 1] (drawer (:begin 25456 :end : 25514 :drawer-name "LOGBOOK" :contents-begin 25469 :contents-end 25504 : :post-blank 1 :post-affiliated 25456 :parent nil)) 1] (planning : (:closed nil :deadline nil :scheduled (timestamp ...) :begin 23148 : :end 23180 :post-blank 0 :post-affiliated 23148 :parent nil)) 1] The end of the stack trace was: : 0] nil 28373 nil nil) : org-element--cache-sync(#<buffer Agenda.org> 28373) : org-element-at-point() : org-eldoc-get-src-lang() : org-eldoc-documentation-function() : eldoc-print-current-symbol-info() : #[0 "\b\204. I must admit, I haven't tried to simply "wait it out" and see if it eventually finishes what it's doing and returning control to me. Perhaps I'll try that next, but usually when these hangs occur it's when I'm in the middle of doing something that I'd rather want to finish :-( If anybody has tips for how I can produce a better bug report, I'd be very happy to hear them. Stig ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-15 13:55 ` Stig Brautaset @ 2017-01-15 14:05 ` Stig Brautaset 0 siblings, 0 replies; 19+ messages in thread From: Stig Brautaset @ 2017-01-15 14:05 UTC (permalink / raw) To: emacs-orgmode Stig Brautaset <stig@brautaset.org> writes: > Eric S Fraga <e.fraga@ucl.ac.uk> writes: > >> On Saturday, 14 Jan 2017 at 18:33, Sebastian Christ wrote: >>> in the last couple weeks (perhaps months?) Emacs hangs for no specific >>> reason for me. The single constant is, that when it hangs, it hangs >>> while I'm in org-mode. This occurs on multiple circumstance as >> >> Just to say that I experience the same. However, I track emacs as well >> as org so I never know if the problem is emacs or org. In my case, all >> hangs are when in org mode but that could be because I'm in org mode >> 90% of the time... :-) > > Just to say that I too experience the same. I'm convinced it started > happening since I upgraded to Org 9 (but I also started using Org's > Agenda more around the same time, I think). My versions: I just saw Nicolas suggesting disabling org cache, and will try that. (My stack traces from hangs did include references to the cache.) Will report back if the hangs disappear, though it might take a while before I'm confident they really are... Stig ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-15 10:56 ` Eric S Fraga 2017-01-15 13:55 ` Stig Brautaset @ 2017-01-15 16:34 ` Eric Abrahamsen 2017-01-16 7:46 ` Michael Welle [not found] ` <e14c1ab631e7438887615a8e568a31f5@DB5PR01MB1895.eurprd01.prod.exchangelabs.com> 2 siblings, 1 reply; 19+ messages in thread From: Eric Abrahamsen @ 2017-01-15 16:34 UTC (permalink / raw) To: emacs-orgmode Eric S Fraga <e.fraga@ucl.ac.uk> writes: > On Saturday, 14 Jan 2017 at 18:33, Sebastian Christ wrote: >> in the last couple weeks (perhaps months?) Emacs hangs for no specific >> reason for me. The single constant is, that when it hangs, it hangs >> while I'm in org-mode. This occurs on multiple circumstance as > > Just to say that I experience the same. However, I track emacs as well > as org so I never know if the problem is emacs or org. In my case, all > hangs are when in org mode but that could be because I'm in org mode > 90% of the time... :-) I used to get this a lot, and always due to some interaction between the cache and flyspell. It hasn't happened to me for several months, though (Emacs from git, org-plus-contrib from the package manager). Who knows why... Eric ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-15 16:34 ` Eric Abrahamsen @ 2017-01-16 7:46 ` Michael Welle 2017-01-16 16:32 ` Eric Abrahamsen 0 siblings, 1 reply; 19+ messages in thread From: Michael Welle @ 2017-01-16 7:46 UTC (permalink / raw) To: emacs-orgmode Hello, Eric Abrahamsen <eric@ericabrahamsen.net> writes: [...] > I used to get this a lot, and always due to some interaction between the > cache and flyspell. It hasn't happened to me for several months, though > (Emacs from git, org-plus-contrib from the package manager). Who knows > why... I have no problem (in this department ;)) with Org (Org and Emacs 25, both, are from git), but sometimes Emacs hangs when I write an email with wanderlust. It seems to hang for a minute or maybe longer, most times I key in a couple of C-g and then go on. I got triggered by flyspell, that is active in wl as well. Hmm. Regards hmw ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-16 7:46 ` Michael Welle @ 2017-01-16 16:32 ` Eric Abrahamsen 0 siblings, 0 replies; 19+ messages in thread From: Eric Abrahamsen @ 2017-01-16 16:32 UTC (permalink / raw) To: emacs-orgmode Michael Welle <mwe012008@gmx.net> writes: > Hello, > > Eric Abrahamsen <eric@ericabrahamsen.net> writes: > [...] >> I used to get this a lot, and always due to some interaction between the >> cache and flyspell. It hasn't happened to me for several months, though >> (Emacs from git, org-plus-contrib from the package manager). Who knows >> why... > I have no problem (in this department ;)) with Org (Org and Emacs 25, > both, are from git), but sometimes Emacs hangs when I write an email > with wanderlust. It seems to hang for a minute or maybe longer, most > times I key in a couple of C-g and then go on. I got triggered by > flyspell, that is active in wl as well. Hmm. Flyspell apparently has a few mechanisms for avoiding this sort of thing, see the option flyspell-delayed-commands and flyspell-delay. Org already does some manipulation of delayed commands (maybe that's why I don't see these hangs anymore...?), perhaps you could try that in wl as well. Eric ^ permalink raw reply [flat|nested] 19+ messages in thread
[parent not found: <e14c1ab631e7438887615a8e568a31f5@DB5PR01MB1895.eurprd01.prod.exchangelabs.com>]
* Re: Emacs hangs sometimes for no reason [not found] ` <e14c1ab631e7438887615a8e568a31f5@DB5PR01MB1895.eurprd01.prod.exchangelabs.com> @ 2017-01-15 18:37 ` Eric S Fraga 2017-01-18 14:12 ` Samuel Loury [not found] ` <ad4e6c881fc34dbe871e0790f56d5a4e@HE1PR01MB1898.eurprd01.prod.exchangelabs.com> 0 siblings, 2 replies; 19+ messages in thread From: Eric S Fraga @ 2017-01-15 18:37 UTC (permalink / raw) To: emacs-orgmode [-- Attachment #1: Type: text/plain, Size: 1171 bytes --] On Sunday, 15 Jan 2017 at 13:55, Stig Brautaset wrote: [...] > Just to say that I too experience the same. I'm convinced it started > happening since I upgraded to Org 9 (but I also started using Org's > Agenda more around the same time, I think). My versions: [...] > I can go a few days without encountering it, but then it will suddenly > hit. I have a feeling that it's triggered by refiling, or closing > TODOs towards the end of the file. My agenda file is big, but not For me, it does not happen with the agenda but when editing documents (in org). I can find no predictability to the hangs, however. Some days it happens more than once but I can also go many days without it happening. Emacs does not get completely hung in that it attempts to respond to C-g (visual-bell indication happens). The cache may be involved. I do tend to have quite long and complicated documents (full journal papers or a whole semester's set of slides for one of my courses) with lots of babel src blocks, tables, inline tasks, ... Anyway, not a deal breaker! -- : Eric S Fraga (0xFFFCF67D), Emacs 26.0.50.1, Org release_9.0.3-201-ga51c6f [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 194 bytes --] ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-15 18:37 ` Eric S Fraga @ 2017-01-18 14:12 ` Samuel Loury 2017-01-19 8:37 ` Sebastian Christ [not found] ` <ad4e6c881fc34dbe871e0790f56d5a4e@HE1PR01MB1898.eurprd01.prod.exchangelabs.com> 1 sibling, 1 reply; 19+ messages in thread From: Samuel Loury @ 2017-01-18 14:12 UTC (permalink / raw) To: Eric S Fraga, emacs-orgmode [-- Attachment #1: Type: text/plain, Size: 859 bytes --] For what it's worth, when this happens, I generally pkill -SIGUSR2 emacs. emacs reacts to the USR2 signal by stopping everything and start a lisp debugging session. From there, I reset all the org caches with this command: --8<---------------cut here---------------start------------->8--- (defun konix/org-element-cache-reset-all () (interactive) (mapc (lambda (file) (save-window-excursion (save-excursion (find-file file) (org-element-cache-reset) ) ) ) (org-agenda-files) ) ) --8<---------------cut here---------------end--------------->8--- Finally, I quit the debugging session and reset the debug on quit with (toggle-debug-on-quit) and everything comes back to normal. My two cents, -- Konubinix GPG Key : 7439106A Fingerprint: 5993 BE7A DA65 E2D9 06CE 5C36 75D2 3CED 7439 106A [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 487 bytes --] ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-18 14:12 ` Samuel Loury @ 2017-01-19 8:37 ` Sebastian Christ 2017-01-20 7:34 ` Samuel Loury 0 siblings, 1 reply; 19+ messages in thread From: Sebastian Christ @ 2017-01-19 8:37 UTC (permalink / raw) To: emacs-orgmode >>>>> "SL" == Samuel Loury <konubinix@gmail.com> writes: SL> For what it's worth, when this happens, I generally pkill SL> -SIGUSR2 emacs. emacs reacts to the USR2 signal by stopping SL> everything and start a lisp debugging session. From there, I SL> reset all the org caches with this command: SL> (defun konix/org-element-cache-reset-all () SL> (interactive) SL> (mapc SL> (lambda (file) SL> (save-window-excursion SL> (save-excursion SL> (find-file file) SL> (org-element-cache-reset)))) SL> (org-agenda-files))) Thanks for this snippet. I know it's a little bit early but setting `org-element-use-cache' seems to do the trick for me. SL> Finally, I quit the debugging session and reset the debug on SL> quit with (toggle-debug-on-quit) and everything comes back to SL> normal. So, aren't you restarting Emacs after pkill -SIGUSR2 emacs? Regards, Sebastian -- Sebastian (Rudolfo) Christ http://rudolfochrist.github.io GPG Fingerprint: 306D 8FD3 DFB6 4E44 5061 CE71 6407 D6F8 2AC5 55DD ^ permalink raw reply [flat|nested] 19+ messages in thread
* Re: Emacs hangs sometimes for no reason 2017-01-19 8:37 ` Sebastian Christ @ 2017-01-20 7:34 ` Samuel Loury 0 siblings, 0 replies; 19+ messages in thread From: Samuel Loury @ 2017-01-20 7:34 UTC (permalink / raw) To: Sebastian Christ, emacs-orgmode [-- Attachment #1: Type: text/plain, Size: 568 bytes --] Sebastian Christ <rudolfo.christ@gmail.com> writes: [...] > So, aren't you restarting Emacs after pkill -SIGUSR2 emacs? pkill -SIGUSR2 emacs does not stop emacs. Emacs will start a debugging session that you can stop to go back to a "normal" emacs. I found out that it generally makes emacs responsive enough so that I can launch the org reset cache function. I found the USR2 signal trick in irreal¹. ¹ here: http://irreal.org/blog/?p=5218 -- Konubinix GPG Key : 7439106A Fingerprint: 5993 BE7A DA65 E2D9 06CE 5C36 75D2 3CED 7439 106A [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 487 bytes --] ^ permalink raw reply [flat|nested] 19+ messages in thread
[parent not found: <ad4e6c881fc34dbe871e0790f56d5a4e@HE1PR01MB1898.eurprd01.prod.exchangelabs.com>]
* Re: Emacs hangs sometimes for no reason [not found] ` <ad4e6c881fc34dbe871e0790f56d5a4e@HE1PR01MB1898.eurprd01.prod.exchangelabs.com> @ 2017-01-18 16:09 ` Eric S Fraga 0 siblings, 0 replies; 19+ messages in thread From: Eric S Fraga @ 2017-01-18 16:09 UTC (permalink / raw) To: emacs-orgmode [-- Attachment #1: Type: text/plain, Size: 285 bytes --] On Wednesday, 18 Jan 2017 at 14:12, Samuel Loury wrote: > For what it's worth, when this happens, I generally pkill -SIGUSR2 Thanks, this is useful. I usually try INT, USR1, KILL but never USR2. -- : Eric S Fraga (0xFFFCF67D), Emacs 26.0.50.1, Org release_9.0.3-241-gc3d67b [-- Attachment #2: signature.asc --] [-- Type: application/pgp-signature, Size: 194 bytes --] ^ permalink raw reply [flat|nested] 19+ messages in thread
end of thread, other threads:[~2020-02-12 9:10 UTC | newest] Thread overview: 19+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2017-01-14 18:33 Emacs hangs sometimes for no reason Sebastian Christ 2017-01-14 18:42 ` Nicolas Goaziou 2017-01-14 19:38 ` Samuel Wales 2017-01-15 8:52 ` Sebastian Christ 2017-01-15 8:49 ` Sebastian Christ 2020-02-11 12:32 ` Karl Voit 2020-02-11 22:23 ` briangpowell . 2020-02-12 9:09 ` Karl Voit [not found] <375517626d9045a99b6c008b5aaf62dd@HE1PR01MB1898.eurprd01.prod.exchangelabs.com> 2017-01-15 10:56 ` Eric S Fraga 2017-01-15 13:55 ` Stig Brautaset 2017-01-15 14:05 ` Stig Brautaset 2017-01-15 16:34 ` Eric Abrahamsen 2017-01-16 7:46 ` Michael Welle 2017-01-16 16:32 ` Eric Abrahamsen [not found] ` <e14c1ab631e7438887615a8e568a31f5@DB5PR01MB1895.eurprd01.prod.exchangelabs.com> 2017-01-15 18:37 ` Eric S Fraga 2017-01-18 14:12 ` Samuel Loury 2017-01-19 8:37 ` Sebastian Christ 2017-01-20 7:34 ` Samuel Loury [not found] ` <ad4e6c881fc34dbe871e0790f56d5a4e@HE1PR01MB1898.eurprd01.prod.exchangelabs.com> 2017-01-18 16:09 ` Eric S Fraga
Code repositories for project(s) associated with this public inbox https://git.savannah.gnu.org/cgit/emacs/org-mode.git This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).