bug#38031: 26.3; Trying to invoke the macOS File Open window causes Emacs to crash on macOS Catalina

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

bug#38031: 26.3; Trying to invoke the macOS File Open window causes Emacs to crash on macOS Catalina

Michael Dixon

On macOS Catalina, if I attempt to open a file using
  * File > Open
  * The toolbar button
  * "Open a File" on the splash screen

Emacs crashes. I am using the Homebrew formula with GUI. I have tried
with other Mac Emacs distributions, such as GNU Emacs for Mac OS X and
the Homebrew emacs-plus formula with the same result.

Here's the part of the macOS crash report that I think is useful:

Application Specific Information:
*** Terminating app due to uncaught exception 'NSObjectNotAvailableException',
reason: 'EmacsSavePanel is not a supported subclass for sandboxing'
abort() called
terminating with uncaught exception of type NSException

From my own troubleshooting, this appears to be due to a change in the
way macOS Catalina allows access to the Disk. Suggestions to fix it
include using macOS's System > Security & Privacy > Privacy > Full Disk
Access to grant full disk access to the Emacs application, the Emacs
binary within the Emacs.app and /usr/bin/ruby. None of these fix the problem for me.

I wonder if there is another executable that also needs full disk access
to make these elements work.


In GNU Emacs 26.3 (build 1, x86_64-apple-darwin18.2.0, NS appkit-1671.20 Version 10.14.3 (Build 18D109))
of 2019-09-02 built on builder10-14.porkrind.org
Windowing system distributor 'Apple', version 10.3.1894
Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
Starting new Ispell process /usr/local/bin/aspell with default dictionary...
evil-line-move: Beginning of buffer
Configured using:
'configure --with-ns '--enable-locallisppath=/Library/Application
Support/Emacs/${version}/site-lisp:/Library/Application
Support/Emacs/site-lisp' --with-modules'

Configured features:
NOTIFY ACL GNUTLS LIBXML2 ZLIB TOOLKIT_SCROLL_BARS NS MODULES THREADS

Important settings:
  value of $LANG: en_CA.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Org

Minor modes in effect:
  wc-mode: t
  global-undo-tree-mode: t
  undo-tree-mode: t
  flyspell-mode: t
  shell-dirtrack-mode: t
  evil-mode: t
  evil-local-mode: t
  tooltip-mode: t
  global-eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  visual-line-mode: t
  transient-mark-mode: t
  abbrev-mode: t

Load-path shadows:
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-stan hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-stan
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-exp hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-exp
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-J hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-J
/Users/michael/.emacs.d/elpa/org-9.2.6/org-eshell hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-eshell
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-emacs-lisp hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-emacs-lisp
/Users/michael/.emacs.d/elpa/org-9.2.6/org-gnus hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-gnus
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-css hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-css
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-lob hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-lob
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-forth hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-forth
/Users/michael/.emacs.d/elpa/org-9.2.6/org-macs hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-macs
/Users/michael/.emacs.d/elpa/org-9.2.6/ob hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob
/Users/michael/.emacs.d/elpa/org-9.2.6/org-version hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-version
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-scheme hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-scheme
/Users/michael/.emacs.d/elpa/org-9.2.6/ox hides /Applications/Emacs.app/Contents/Resources/lisp/org/ox
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-abc hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-abc
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-C hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-C
/Users/michael/.emacs.d/elpa/org-9.2.6/org-capture hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-capture
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-ref hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-ref
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-clojure hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-clojure
/Users/michael/.emacs.d/elpa/org-9.2.6/org-mouse hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-mouse
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-ledger hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-ledger
/Users/michael/.emacs.d/elpa/org-9.2.6/org-ctags hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-ctags
/Users/michael/.emacs.d/elpa/org-9.2.6/org-entities hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-entities
/Users/michael/.emacs.d/elpa/org-9.2.6/org-archive hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-archive
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-screen hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-screen
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-haskell hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-haskell
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-asymptote hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-asymptote
/Users/michael/.emacs.d/elpa/org-9.2.6/org-mhe hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-mhe
/Users/michael/.emacs.d/elpa/org-9.2.6/org-table hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-table
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-keys hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-keys
/Users/michael/.emacs.d/elpa/org-9.2.6/ox-org hides /Applications/Emacs.app/Contents/Resources/lisp/org/ox-org
/Users/michael/.emacs.d/elpa/org-9.2.6/org-plot hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-plot
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-awk hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-awk
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-groovy hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-groovy
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-octave hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-octave
/Users/michael/.emacs.d/elpa/org-9.2.6/org-faces hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-faces
/Users/michael/.emacs.d/elpa/org-9.2.6/org-colview hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-colview
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-R hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-R
/Users/michael/.emacs.d/elpa/org-9.2.6/org-timer hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-timer
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-ebnf hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-ebnf
/Users/michael/.emacs.d/elpa/org-9.2.6/org-mobile hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-mobile
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-fortran hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-fortran
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-shell hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-shell
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-perl hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-perl
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-sqlite hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-sqlite
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-sed hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-sed
/Users/michael/.emacs.d/elpa/org-9.2.6/org-list hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-list
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-ruby hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-ruby
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-eval hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-eval
/Users/michael/.emacs.d/elpa/org-9.2.6/org-habit hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-habit
/Users/michael/.emacs.d/elpa/org-9.2.6/org-clock hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-clock
/Users/michael/.emacs.d/elpa/org-9.2.6/ox-html hides /Applications/Emacs.app/Contents/Resources/lisp/org/ox-html
/Users/michael/.emacs.d/elpa/org-9.2.6/org-src hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-src
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-lisp hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-lisp
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-ditaa hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-ditaa
/Users/michael/.emacs.d/elpa/org-9.2.6/org-pcomplete hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-pcomplete
/Users/michael/.emacs.d/elpa/org-9.2.6/org-lint hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-lint
/Users/michael/.emacs.d/elpa/org-9.2.6/org-rmail hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-rmail
/Users/michael/.emacs.d/elpa/org-9.2.6/ox-latex hides /Applications/Emacs.app/Contents/Resources/lisp/org/ox-latex
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-sass hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-sass
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-io hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-io
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-tangle hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-tangle
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-calc hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-calc
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-java hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-java
/Users/michael/.emacs.d/elpa/org-9.2.6/ox-icalendar hides /Applications/Emacs.app/Contents/Resources/lisp/org/ox-icalendar
/Users/michael/.emacs.d/elpa/org-9.2.6/org-eww hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-eww
/Users/michael/.emacs.d/elpa/org-9.2.6/ox-md hides /Applications/Emacs.app/Contents/Resources/lisp/org/ox-md
/Users/michael/.emacs.d/elpa/org-9.2.6/ox-beamer hides /Applications/Emacs.app/Contents/Resources/lisp/org/ox-beamer
/Users/michael/.emacs.d/elpa/org-9.2.6/org-element hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-element
/Users/michael/.emacs.d/elpa/org-9.2.6/org-protocol hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-protocol
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-mscgen hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-mscgen
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-gnuplot hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-gnuplot
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-latex hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-latex
/Users/michael/.emacs.d/elpa/org-9.2.6/org-id hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-id
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-vala hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-vala
/Users/michael/.emacs.d/elpa/org-9.2.6/ox-man hides /Applications/Emacs.app/Contents/Resources/lisp/org/ox-man
/Users/michael/.emacs.d/elpa/org-9.2.6/org-feed hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-feed
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-lua hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-lua
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-table hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-table
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-ocaml hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-ocaml
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-coq hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-coq
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-picolisp hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-picolisp
/Users/michael/.emacs.d/elpa/org-9.2.6/org-indent hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-indent
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-lilypond hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-lilypond
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-matlab hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-matlab
/Users/michael/.emacs.d/elpa/org-9.2.6/org-datetree hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-datetree
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-python hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-python
/Users/michael/.emacs.d/elpa/org-9.2.6/org-bbdb hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-bbdb
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-makefile hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-makefile
/Users/michael/.emacs.d/elpa/org-9.2.6/org-duration hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-duration
/Users/michael/.emacs.d/elpa/org-9.2.6/org-agenda hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-agenda
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-dot hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-dot
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-js hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-js
/Users/michael/.emacs.d/elpa/org-9.2.6/ox-publish hides /Applications/Emacs.app/Contents/Resources/lisp/org/ox-publish
/Users/michael/.emacs.d/elpa/org-9.2.6/org-inlinetask hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-inlinetask
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-org hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-org
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-core hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-core
/Users/michael/.emacs.d/elpa/org-9.2.6/org-compat hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-compat
/Users/michael/.emacs.d/elpa/org-9.2.6/org-docview hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-docview
/Users/michael/.emacs.d/elpa/org-9.2.6/ox-odt hides /Applications/Emacs.app/Contents/Resources/lisp/org/ox-odt
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-plantuml hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-plantuml
/Users/michael/.emacs.d/elpa/org-9.2.6/ox-ascii hides /Applications/Emacs.app/Contents/Resources/lisp/org/ox-ascii
/Users/michael/.emacs.d/elpa/org-9.2.6/org-loaddefs hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-loaddefs
/Users/michael/.emacs.d/elpa/org-9.2.6/org-w3m hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-w3m
/Users/michael/.emacs.d/elpa/org-9.2.6/org-bibtex hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-bibtex
/Users/michael/.emacs.d/elpa/org-9.2.6/org-info hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-info
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-hledger hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-hledger
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-maxima hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-maxima
/Users/michael/.emacs.d/elpa/org-9.2.6/org hides /Applications/Emacs.app/Contents/Resources/lisp/org/org
/Users/michael/.emacs.d/elpa/org-9.2.6/org-macro hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-macro
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-sql hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-sql
/Users/michael/.emacs.d/elpa/org-9.2.6/org-attach hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-attach
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-processing hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-processing
/Users/michael/.emacs.d/elpa/org-9.2.6/ox-texinfo hides /Applications/Emacs.app/Contents/Resources/lisp/org/ox-texinfo
/Users/michael/.emacs.d/elpa/org-9.2.6/org-irc hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-irc
/Users/michael/.emacs.d/elpa/org-9.2.6/org-crypt hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-crypt
/Users/michael/.emacs.d/elpa/org-9.2.6/org-footnote hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-footnote
/Users/michael/.emacs.d/elpa/org-9.2.6/org-install hides /Applications/Emacs.app/Contents/Resources/lisp/org/org-install
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-comint hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-comint
/Users/michael/.emacs.d/elpa/org-9.2.6/ob-shen hides /Applications/Emacs.app/Contents/Resources/lisp/org/ob-shen

Features:
(shadow sort mail-extr emacsbug sendmail wc-mode org-eww org-rmail
org-mhe org-irc org-info org-gnus nnir gnus-sum gnus-group gnus-undo
gnus-start gnus-cloud nnimap nnmail mail-source tls gnutls utf7 netrc
nnoo parse-time gnus-spec gnus-int gnus-range message rmc puny rfc822
mml mml-sec epa derived epg mm-decode mm-bodies mm-encode mail-parse
rfc2231 mailabbrev gmm-utils mailheader gnus-win gnus nnheader gnus-util
rmail rmail-loaddefs rfc2047 rfc2045 ietf-drums mail-utils mm-util
mail-prsvr wid-edit org-docview doc-view jka-compr image-mode dired
dired-loaddefs org-bibtex bibtex org-bbdb org-w3m elec-pair evil
evil-keybindings evil-integration undo-tree diff evil-maps evil-commands
reveal flyspell ispell evil-jumps evil-command-window evil-types
evil-search evil-ex shell evil-macros evil-repeat evil-states evil-core
evil-common windmove thingatpt rect evil-digraphs evil-vars edmacro
kmacro org-element avl-tree generator org ob ob-tangle ob-ref ob-lob
ob-table ob-exp org-macro org-footnote org-src ob-comint ob-keys
org-pcomplete pcomplete comint ansi-color ring org-list org-faces
org-entities noutline outline easy-mmode org-version ob-emacs-lisp
ob-core ob-eval org-compat advice org-macs org-loaddefs format-spec
find-func cal-menu calendar cal-loaddefs exec-path-from-shell
challenger-deep-theme finder-inf info package easymenu epg-config
url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs
eieio-loaddefs password-cache url-vars seq byte-opt gv bytecomp
byte-compile cconv cl-loaddefs cl-lib time-date tooltip eldoc electric
uniquify ediff-hook vc-hooks lisp-float-type mwheel term/ns-win ns-win
ucs-normalize mule-util term/common-win tool-bar dnd fontset image
regexp-opt fringe tabulated-list replace newcomment text-mode elisp-mode
lisp-mode prog-mode register page menu-bar rfn-eshadow isearch timer
select scroll-bar mouse jit-lock font-lock syntax facemenu font-core
term/tty-colors frame cl-generic cham georgian utf-8-lang misc-lang
vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932
hebrew greek romanian slovak czech european ethiopic indian cyrillic
chinese composite charscript charprop case-table epa-hook jka-cmpr-hook
help simple abbrev obarray minibuffer cl-preloaded nadvice loaddefs
button faces cus-face macroexp files text-properties overlay sha1 md5
base64 format env code-pages mule custom widget hashtable-print-readable
backquote threads kqueue cocoa ns multi-tty make-network-process emacs)

Memory information:
((conses 16 478620 21942)
(symbols 48 39708 2)
(miscs 40 150 472)
(strings 32 118138 4777)
(string-bytes 1 3324775)
(vectors 16 58860)
(vector-slots 8 1015603 22938)
(floats 8 210 324)
(intervals 56 435 0)
(buffers 992 14))



Reply | Threaded
Open this post in threaded view
|

bug#38031: 26.3; Trying to invoke the macOS File Open window causes Emacs to crash on macOS Catalina

Alan Third
On Sat, Nov 02, 2019 at 06:19:27AM -0400, Michael Dixon wrote:

>
> On macOS Catalina, if I attempt to open a file using
>   * File > Open
>   * The toolbar button
>   * "Open a File" on the splash screen
>
> Emacs crashes. I am using the Homebrew formula with GUI. I have tried
> with other Mac Emacs distributions, such as GNU Emacs for Mac OS X and
> the Homebrew emacs-plus formula with the same result.
>
> Here's the part of the macOS crash report that I think is useful:
>
> Application Specific Information:
> *** Terminating app due to uncaught exception 'NSObjectNotAvailableException',
> reason: 'EmacsSavePanel is not a supported subclass for sandboxing'
> abort() called
> terminating with uncaught exception of type NSException

That sounds suspiciously like the fact we’ve subclassed the save panel
class means it’s no longer considered ‘safe’ by Cocoa.

I suspect there’s no immediate work‐around other than trying to work
out what about EmacsSavePanel is problematic.

Can you try applying the patch below? I don’t think it’ll fix
anything, but it should at least rule out that it’s something in these
functions that’s causing this.

modified   src/nsfns.m
@@ -3067,25 +3067,25 @@ The position is returned as a cons cell (X . Y) of the
 }
 
 @implementation EmacsSavePanel
-- (BOOL)performKeyEquivalent:(NSEvent *)theEvent
-{
-  BOOL ret = handlePanelKeys (self, theEvent);
-  if (! ret)
-    ret = [super performKeyEquivalent:theEvent];
-  return ret;
-}
+// - (BOOL)performKeyEquivalent:(NSEvent *)theEvent
+// {
+//   BOOL ret = handlePanelKeys (self, theEvent);
+//   if (! ret)
+//     ret = [super performKeyEquivalent:theEvent];
+//   return ret;
+// }
 @end
 
 
 @implementation EmacsOpenPanel
-- (BOOL)performKeyEquivalent:(NSEvent *)theEvent
-{
-  // NSOpenPanel inherits NSSavePanel, so passing self is OK.
-  BOOL ret = handlePanelKeys (self, theEvent);
-  if (! ret)
-    ret = [super performKeyEquivalent:theEvent];
-  return ret;
-}
+// - (BOOL)performKeyEquivalent:(NSEvent *)theEvent
+// {
+//   // NSOpenPanel inherits NSSavePanel, so passing self is OK.
+//   BOOL ret = handlePanelKeys (self, theEvent);
+//   if (! ret)
+//     ret = [super performKeyEquivalent:theEvent];
+//   return ret;
+// }
 @end

--
Alan Third



Reply | Threaded
Open this post in threaded view
|

bug#38031: 26.3; Trying to invoke the macOS File Open window causes Emacs to crash on macOS Catalina

Michael Dixon
Thanks Alan. I might be a little over my head here, as I’m not sure how to apply a patch. I presume I would have to build from source...

On Nov 3, 2019, at 3:39 PM, Alan Third <[hidden email]> wrote:

On Sat, Nov 02, 2019 at 06:19:27AM -0400, Michael Dixon wrote:

On macOS Catalina, if I attempt to open a file using
 * File > Open
 * The toolbar button
 * "Open a File" on the splash screen

Emacs crashes. I am using the Homebrew formula with GUI. I have tried
with other Mac Emacs distributions, such as GNU Emacs for Mac OS X and
the Homebrew emacs-plus formula with the same result.

Here's the part of the macOS crash report that I think is useful:

Application Specific Information:
*** Terminating app due to uncaught exception 'NSObjectNotAvailableException',
reason: 'EmacsSavePanel is not a supported subclass for sandboxing'
abort() called
terminating with uncaught exception of type NSException

That sounds suspiciously like the fact we’ve subclassed the save panel
class means it’s no longer considered ‘safe’ by Cocoa.

I suspect there’s no immediate work‐around other than trying to work
out what about EmacsSavePanel is problematic.

Can you try applying the patch below? I don’t think it’ll fix
anything, but it should at least rule out that it’s something in these
functions that’s causing this.

modified   src/nsfns.m
@@ -3067,25 +3067,25 @@ The position is returned as a cons cell (X . Y) of the
}

@implementation EmacsSavePanel
-- (BOOL)performKeyEquivalent:(NSEvent *)theEvent
-{
-  BOOL ret = handlePanelKeys (self, theEvent);
-  if (! ret)
-    ret = [super performKeyEquivalent:theEvent];
-  return ret;
-}
+// - (BOOL)performKeyEquivalent:(NSEvent *)theEvent
+// {
+//   BOOL ret = handlePanelKeys (self, theEvent);
+//   if (! ret)
+//     ret = [super performKeyEquivalent:theEvent];
+//   return ret;
+// }
@end


@implementation EmacsOpenPanel
-- (BOOL)performKeyEquivalent:(NSEvent *)theEvent
-{
-  // NSOpenPanel inherits NSSavePanel, so passing self is OK.
-  BOOL ret = handlePanelKeys (self, theEvent);
-  if (! ret)
-    ret = [super performKeyEquivalent:theEvent];
-  return ret;
-}
+// - (BOOL)performKeyEquivalent:(NSEvent *)theEvent
+// {
+//   // NSOpenPanel inherits NSSavePanel, so passing self is OK.
+//   BOOL ret = handlePanelKeys (self, theEvent);
+//   if (! ret)
+//     ret = [super performKeyEquivalent:theEvent];
+//   return ret;
+// }
@end

-- 
Alan Third

Reply | Threaded
Open this post in threaded view
|

bug#38031: 26.3; Trying to invoke the macOS File Open window causes Emacs to crash on macOS Catalina

Alan Third
On Sun, Nov 03, 2019 at 04:02:39PM -0500, Michael Dixon wrote:
> Thanks Alan. I might be a little over my head here, as I’m not sure
> how to apply a patch. I presume I would have to build from source...

Yes, you would. It’s not very hard if you’ve got git installed. I can
talk you through it. Alternatively we can try to find someone else
running Catalina, there should be a few Emacs devs/users who’ve
upgraded around here somewhere.
--
Alan Third



Reply | Threaded
Open this post in threaded view
|

bug#38031: 26.3; Trying to invoke the macOS File Open window causes Emacs to crash on macOS Catalina

Stefan Kangas
Alan Third <[hidden email]> writes:

> On Sun, Nov 03, 2019 at 04:02:39PM -0500, Michael Dixon wrote:
>> Thanks Alan. I might be a little over my head here, as I’m not sure
>> how to apply a patch. I presume I would have to build from source...
>
> Yes, you would. It’s not very hard if you’ve got git installed. I can
> talk you through it. Alternatively we can try to find someone else
> running Catalina, there should be a few Emacs devs/users who’ve
> upgraded around here somewhere.

I'm still on 10.13 so I unfortunately can't help with this.  But since
this is a crash in very basic functionality, perhaps we should
actively reach out to try to see if anyone can help with this in time
to fix it before the pretest of Emacs 27.1.

Best regards,
Stefan Kangas



Reply | Threaded
Open this post in threaded view
|

bug#38031: 26.3; Trying to invoke the macOS File Open window causes Emacs to crash on macOS Catalina

Nate Bass
I tried and before I got to testing the patch I ran into an issue building Emacs on macOS 10.15 (aka Catalina).

When I run make I get the following error:

xml.c:26:10: fatal error: 'libxml/tree.h' file not found
#include <libxml/tree.h>
         ^~~~~~~~~~~~~~~
1 error generated.
make[1]: *** [xml.o] Error 1
make: *** [src] Error 2
/Applications/Xcode.app/Contents/Developer/usr/bin/make -C lib all
make[1]: Nothing to be done for `all'.
/Applications/Xcode.app/Contents/Developer/usr/bin/make -C lib-src all
make[1]: Nothing to be done for `all'.
/Applications/Xcode.app/Contents/Developer/usr/bin/make -C src VCSWITNESS='$(srcdir)/../.git/logs/HEAD' all
  CC       xml.o
xml.c:26:10: fatal error: 'libxml/tree.h' file not found
#include <libxml/tree.h>
         ^~~~~~~~~~~~~~~
1 error generated.
make[1]: *** [xml.o] Error 1
make: *** [src] Error 2

Mac OS X 10.14 has stopped placing the include libraries in their usual location, /usr/include, keeping them only inside the XCode directory.

The work around was to run a pkg installer included in the XCode directory.[1] I can no longer find that file or anything similar in macOS 10.15.

Any tips are appreciated. I will try to build and test the patch again this weekend. There was something in the article I referenced about linking the path where the libraries are to /usr/include but it wasn't recommended because it overrides the default behaviour expected by Mac OS and requires you to disable SIP (System Integrity Protection). I am open to trying anything.

[1] https://silvae86.github.io/sysadmin/mac/osx/mojave/beta/libxml2/2018/07/05/fixing-missing-headers-for-homebrew-in-mac-osx-mojave/

Other links about this issue:
https://lists.gnu.org/archive/html/emacs-devel/2015-11/msg01918.html
https://emacs.stackexchange.com/questions/34238/installing-emacs-from-source-make-fatal-error-libxml-tree-h-file-not-found

On Thu, Nov 7, 2019, 4:40 PM Stefan Kangas <[hidden email]> wrote:

>
> Alan Third <[hidden email]> writes:
>
> > On Sun, Nov 03, 2019 at 04:02:39PM -0500, Michael Dixon wrote:
> >> Thanks Alan. I might be a little over my head here, as I’m not sure
> >> how to apply a patch. I presume I would have to build from source...
> >
> > Yes, you would. It’s not very hard if you’ve got git installed. I can
> > talk you through it. Alternatively we can try to find someone else
> > running Catalina, there should be a few Emacs devs/users who’ve
> > upgraded around here somewhere.
>
> I'm still on 10.13 so I unfortunately can't help with this.  But since
> this is a crash in very basic functionality, perhaps we should
> actively reach out to try to see if anyone can help with this in time
> to fix it before the pretest of Emacs 27.1.
>
> Best regards,
> Stefan Kangas
>
>
Reply | Threaded
Open this post in threaded view
|

bug#38031: 26.3; Trying to invoke the macOS File Open window causes Emacs to crash on macOS Catalina

Andrii Kolomoiets
In reply to this post by Michael Dixon
Hi Alan,

> On Sun, Nov 03, 2019 at 04:02:39PM -0500, Michael Dixon wrote:
> > Thanks Alan. I might be a little over my head here, as I’m not sure
> > how to apply a patch. I presume I would have to build from source...
>
> Yes, you would. It’s not very hard if you’ve got git installed. I can
> talk you through it. Alternatively we can try to find someone else
> running Catalina, there should be a few Emacs devs/users who’ve
> upgraded around here somewhere.

Emacs 27 on Catalina doesn't crash for me even without this patch.
"File->Open File..." and tool bar icon are working fine. Maybe it is
fixed somewhere in Emacs 27?

The only patch that I build Emacs with is from bug#36672 but I think
there are no changes related to this issue.


Reply | Threaded
Open this post in threaded view
|

bug#38031: 26.3; Trying to invoke the macOS File Open window causes Emacs to crash on macOS Catalina

Alan Third
In reply to this post by Nate Bass
On Thu, Nov 07, 2019 at 09:06:43PM -0800, Nathaniel Bass wrote:
> I tried and before I got to testing the patch I ran into an issue building
> Emacs on macOS 10.15 (aka Catalina).
>
> When I run make I get the following error:
>
> xml.c:26:10: fatal error: 'libxml/tree.h' file not found
> #include <libxml/tree.h>
>          ^~~~~~~~~~~~~~~
> 1 error generated.

Hi Nathaniel, thanks for helping out!

The libxml issue is a known problem with homebrew installs. Let me
know if you’re not using homebrew.

To work around it I suggest making sure libxml2 is installed through
homebrew and running this before configure:

    export PKG_CONFIG_PATH="`brew --prefix libxml2`/lib/pkgconfig:$PKG_CONFIG_PATH"

--
Alan Third



Reply | Threaded
Open this post in threaded view
|

bug#38031: 26.3; Trying to invoke the macOS File Open window causes Emacs to crash on macOS Catalina

Michael Dixon
Thanks so much everyone.

I was able to build from source. I had the same libxml/tree.h error as Nathaniel.

The crash error I got was the same, but before I waste any more of your time, I wanted to share that I set up a Catalina virtual machine and installed via brew cask and did NOT get the crash, even without providing full disk access to ruby, Emacs.app, etc.

This leads me to believe it my problem isn’t specific to Emacs, but rather something else unique to my environment, though I can’t think of what that might be.

> On Nov 8, 2019, at 2:47 PM, Alan Third <[hidden email]> wrote:
>
> On Thu, Nov 07, 2019 at 09:06:43PM -0800, Nathaniel Bass wrote:
>> I tried and before I got to testing the patch I ran into an issue building
>> Emacs on macOS 10.15 (aka Catalina).
>>
>> When I run make I get the following error:
>>
>> xml.c:26:10: fatal error: 'libxml/tree.h' file not found
>> #include <libxml/tree.h>
>>         ^~~~~~~~~~~~~~~
>> 1 error generated.
>
> Hi Nathaniel, thanks for helping out!
>
> The libxml issue is a known problem with homebrew installs. Let me
> know if you’re not using homebrew.
>
> To work around it I suggest making sure libxml2 is installed through
> homebrew and running this before configure:
>
>    export PKG_CONFIG_PATH="`brew --prefix libxml2`/lib/pkgconfig:$PKG_CONFIG_PATH"
>
> --
> Alan Third




Reply | Threaded
Open this post in threaded view
|

bug#38031: 26.3; Trying to invoke the macOS File Open window causes Emacs to crash on macOS Catalina

Alan Third
On Fri, Nov 08, 2019 at 04:33:23PM -0500, Michael Dixon wrote:

> Thanks so much everyone.
>
> I was able to build from source. I had the same libxml/tree.h error
> as Nathaniel.
>
> The crash error I got was the same, but before I waste any more of
> your time, I wanted to share that I set up a Catalina virtual
> machine and installed via brew cask and did NOT get the crash, even
> without providing full disk access to ruby, Emacs.app, etc.
>
> This leads me to believe it my problem isn’t specific to Emacs, but
> rather something else unique to my environment, though I can’t think
> of what that might be.

Where did you get the original copy that did crash? Was that also a
brew cask install?

Are they both Emacs 26?

--
Alan Third



Reply | Threaded
Open this post in threaded view
|

bug#38031: 26.3; Trying to invoke the macOS File Open window causes Emacs to crash on macOS Catalina

Michael Dixon
I tried a whole variety of distributions. I tried the brew cask (26.3), the emacs-plus formula used for spacemacs (26.3), the prebuilt Emacs for Mac OSX (26.3),  homebrew-emacs-head (another brew formula, both 26.3 and 27.0.50), and now the one I just built (I tried both with and without your patch, both 27.0.5.0, since that’s what I get with master).

> On Nov 8, 2019, at 6:08 PM, Alan Third <[hidden email]> wrote:
>
> On Fri, Nov 08, 2019 at 04:33:23PM -0500, Michael Dixon wrote:
>> Thanks so much everyone.
>>
>> I was able to build from source. I had the same libxml/tree.h error
>> as Nathaniel.
>>
>> The crash error I got was the same, but before I waste any more of
>> your time, I wanted to share that I set up a Catalina virtual
>> machine and installed via brew cask and did NOT get the crash, even
>> without providing full disk access to ruby, Emacs.app, etc.
>>
>> This leads me to believe it my problem isn’t specific to Emacs, but
>> rather something else unique to my environment, though I can’t think
>> of what that might be.
>
> Where did you get the original copy that did crash? Was that also a
> brew cask install?
>
> Are they both Emacs 26?
>
> --
> Alan Third