Ask Your Question
1

Sage 9.0 installation issues on macOS 10.15.2 Catalina

asked 2020-01-16 17:34:58 +0100

Tony-64 gravatar image

updated 2020-01-16 21:28:18 +0100

FrédéricC gravatar image

When I install sage-9.0-OSX_10.15.2-x86_64.app.dmg on macOS Catalina (10.15.2) and run if for the first time, the "starting" web page comes up almost immediately, followed by a pop-up error window saying that "Jupyter Server failed to start." From the log, it looks like the patching of the installation files does not finish properly. See a copy of the log entries below. Note that the last line is not complete.

Does anyone have an idea what the issue could be? I have a working installation of Sage 9.0 on another Mac running 10.15.2, albeit not completely free of issues, but cannot see the difference between the two. (As a side note, the log file of the working installation does not show the "patching" lines at all. Actually, the log is not showing any new information at all anymore. Has a new log been created on that system and is the app showing the previous version of the log?)

From the log on the installation that isn't working

This might take a few minutes but only has to be done once.

patching /Applications/SageMath-9.0.app/Contents/Resources/sage/build/make/Makefile-auto
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/config.status
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/2to3-3.7
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/ESingular
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/NRswitchg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/QuadraticSieve
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/R
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/Rscript
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/Singular
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/TSingular
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/addedgeg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/adjacency
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/adjacency_gmp
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/allfaces
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/allfaces_gmp
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/amtog
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/annotate
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/biplabg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/cas_help
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/catg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/cddexec
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/cddexec_gmp
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/cl
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/complg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/converseg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/copyg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/countg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/cu2
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/cubex
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/cubhamg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/curve_keygen
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/cygdb
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/cysignals-CSI
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/cython
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/cythonize
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/deledgeg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/delptg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/directg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/dreadnaut
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/dretodot
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/dretog
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/easy_install
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/easy_install-3.7
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/ecl
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/ecl-config
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/ecm
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/f2py
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/f2py3
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/f2py3.7
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/fai
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/fflas-ffpack-config
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/fourier
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/fourier_gmp
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/fplll
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/freetype-config
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/futurize
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gac
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gac-e
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gap-bin
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gcc-ar
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gcc-nm
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gcc-ranlib
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gcov
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gcov-dump
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gcov-tool
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gd2copypal
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gd2togif
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gd2topng
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gdcmpgif
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gdlib-config
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gdparttopng
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gdtopng
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/genbg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/genbgL
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/geng
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/genquarticg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/genrang
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/genspecialg
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gentourng
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gfan
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gfortran
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/giftogd2
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/givaro-config
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/givaro-makefile
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/glpsol
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gp-2.11
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gphelp
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gsl-config
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gsl-histogram
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/gsl-randist
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/hamheuristic
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/hevea2mml
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/icas
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/idle3.7
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/iptest
patching /Applications/SageMath-9.0.app/Contents/Resources/sage/local/bin/iptest3
patching /Applications/SageMath-9.0.app/Contents/Resources/sa
edit retag flag offensive close merge delete

Comments

That question would be better addressed on sage-support: the present site is more orented towards mathematical and programming questions about Sage's use...

It seems that you are not alone...

Emmanuel Charpentier gravatar imageEmmanuel Charpentier ( 2020-01-16 20:44:56 +0100 )edit

3 Answers

Sort by » oldest newest most voted
1

answered 2020-01-17 00:59:26 +0100

slelievre gravatar image

In macOS 10.15 Catalina, Apple pushes the security concerns and prevents apps from running unless they are "notarized", which means the developers need to register with Apple and get some certificate for the app.

Up to macOS 10.14 Mojave one could decide to run an app anyway, but in macOS 10.15 Catalina the option to do that is deactivated.

One can either restore that option by running the following command in a terminal (the initial $ on any line denotes the shell prompt, don't type that dollar sign):

$ sudo spctl --master-disable

Once that is done one recovers the option to bypass the quarantine by visiting "System Preferences" and going to the "Security" tab there, etc.

Or one can unquarantine a given application by running a command in the terminal instead of visiting the System Preferences. Say you already did the following:

  • download sage-9.0-OSX_10.15.2-x86_64.app.dmg

  • open the dmg and copy the app where you want it, for example in /Applications.

Then, to recursively unquarantine the app folder, do the following (change THING as needed if it's a different version of Sage or you changed its name or you put it in another location):

$ THING="/Applications/SageMath-9.0.app"
$ xattr -rd com.apple.quarantine $THING

I also recommend to create a symlink to the Sage executable somewhere in your path:

$ THING="/Applications/SageMath-9.0.app"
$ cd $THING/Contents/Resources/sage
$ sudo ln -s `pwd`/sage /usr/local/bin

Then you can start Sage in any terminal session, whatever directory you are working in.

To start the Sage REPL:

$ sage

To start the Jupyter notebook server:

$ sage -n jupyter

Note: in addition to lifting the "quarantine" on the app, some people have suggested one may need to give the app "full disk access" (by going to "System Preferences > Security > Privacy), see:

edit flag offensive delete link more

Comments

Yes, I thought it would be something to do with increased security hurdles.

Thanks for the explanation of the steps to take. Eventually, all I had to do was to execute the xattr command, and run sage from a terminal window once. This resulted in all patches being applied and sage starting normally. After quitting sage, I was able to use the app as usual, with one exception. I had to steer the default Jupyter path away from the Sage folder on my iCloud Drive. Using another cloud-based folder (such as OneDrive) does not caused Jupyter to fail, however. Apparently, it's time to move my stuff from iCloud to OneDrive...

Tony-64 gravatar imageTony-64 ( 2020-01-17 20:09:03 +0100 )edit
1

answered 2020-01-18 10:53:32 +0100

Sébastien gravatar image

Earlier this week, I was trying to fix that problem on the OSX computer of a colleague. It turnout that opening the jupyter notebook from the command line was working when using firefox instead of safari. For people not afraid of the terminal, the solution was to create a file .bash_profile in the home directory with the following content:

export PATH=/Applications/SageMath-9.0.app:$PATH
alias sagejupyter='sage -n jupyter --browser=firefox'

Then running sagejupyter in the terminal in any chosen directory does the trick.

edit flag offensive delete link more
0

answered 2020-05-30 22:34:13 +0100

kcrisman gravatar image

For the purposes of recording some additional instructions in a semi-permanent place (since the Wiki seems to be deemphasized as a location for such instructions), here are some instructions combining Samuel's answer, some on Google groups (https://groups.google.com/forum/#!top...), and a writeup kindly provided by sarah-marie belcastro. DO NOT UPVOTE.


To run Sage binaries on Mac OS 10.15 (Catalina) and above, extra steps may be necessary. Here are some possibilities; see the other answers on this post for much more detail and other, perhaps better, possibilities.

  • Most of this will require a small amount of Terminal access, and assumes you have installed Sage in /Applications/SageMath-9.0 (or whatever version you have), but have not run it yet.

  • First, to re-enable your Mac to allow applications unknown to Apple on a case-by-case basis, run this command. You will need to have superuser abilities (but don't log in as root, if you know what that is):

    sudo spctl --master-disable

  • Go to System Preferences->Security->Privacy to allow this application to run. You will want to Grant Full Disk Access in addition to allowing it to run.

  • Launch Sage from the command line in the executable's installed directory. In a Terminal window, run the following for Sage to rewrite all paths to match their location on your computer (and then open a Jupyter window):

    cd /Applications/SageMath-9.0.app

    ./sage -n

  • When you see the Jupyter tab in your default browser (probably Safari), click the Quit button. This will stop the Jupyter Server, but that's ok.

  • Launch Sage using Applications->SageMath-9.0.

edit flag offensive delete link more

Comments

If someone thinks we should just update https://doc.sagemath.org/html/en/inst... that is great. I am currently submitting a pull request to the website, at any rate, for some warning.

kcrisman gravatar imagekcrisman ( 2020-05-30 22:38:28 +0100 )edit

See also https://trac.sagemath.org/ticket/29710 - eventually this should all be coordinated, but for now piecemeal is fine.

kcrisman gravatar imagekcrisman ( 2020-05-30 22:50:26 +0100 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

2 followers

Stats

Asked: 2020-01-16 17:34:58 +0100

Seen: 5,058 times

Last updated: May 30 '20