Luke <mideniko1234-...@yahoo.co.uk> writes: > On 23/11/16 10:39, Eric Abrahamsen wrote: >> Luke <mideniko1234-...@yahoo.co.uk> writes:
[...] >>> I tried creating a minimal-org.el file with the following contents: >>> >>> ;; activate debugging >>> (setq debug-on-error t >>> debug-on-signal nil >>> debug-on-quit nil) >>> >>> ;; add latest org-mode to load path >>> (add-to-list 'load-path (expand-file-name "~/elisp/org-mode/lisp")) >>> (add-to-list 'load-path (expand-file-name >>> "~/elisp/org-mode/contrib/lisp" t)) >>> >>> And then running: >>> >>> $ emacs -Q -l minimal-org.el >>> >>> ...but I still get the same result (Emacs hangs when I run `M-x >>> (require 'org)`). >>> >>> Can anyone help tell me what's wrong, or suggest how I try and track >>> down the problem? >> >> You're setting debug-on-quit to nil, but it's likely that setting it to >> t is exactly what you need. Toggle it to t, eval (require 'org), then >> while it's hung hit C-g. You should get a backtrace showing you what >> Emacs was actually doing when you quit. >> >> Eric >> >> >> > > Thanks to Eric for the debugging tip. Below is the backtrace that was > produced. It looks like tramp is trying to make some connection to the > host-name "host.does.not.exist" (which will obviously fail). > > This makes sense, because when I disable networking then Emacs starts > immediately and doesn't hang. I'm not sure how to fix this though. I don't have a copy of Emacs 24 handy (and I recommend you upgrade to 25), but as a band-aid you should be able to kill the check by setting the `tramp-use-ssh-controlmaster-options' option to nil. That ought to prevent tramp from testing the connection at all (at least, I think it will). In 25 it looks like "host.does.not.exist" has been replaced with a bogus IP address, meaning that you won't time out on a DNS lookup, which is likely what's hanging for you. As for the real root of the problem -- why loading org results in tramp doing this check -- I unfortunately can't tell you! The real "fix", I think, would be upgrading to Emacs 25. Eric