Skip to content
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

Notebook sometimes fails to start up #9

Open
suchow opened this issue Dec 10, 2013 · 7 comments
Open

Notebook sometimes fails to start up #9

suchow opened this issue Dec 10, 2013 · 7 comments

Comments

@suchow
Copy link

suchow commented Dec 10, 2013

I'm on OS X 10.9 running version 1.10 of the notebook. Sometimes, when I try to open the app, the program gives the following error:

Unable to launch iPython notebook
Server failed to start up

Other times, the notebook loads just fine.

I checked the system logs and there are many entries that show up at the time the notebook was loading:

12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny mach-lookup com.apple.ocspd
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny mach-lookup com.apple.ocspd
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny mach-lookup com.apple.ocspd
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny mach-lookup com.apple.ocspd
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny mach-lookup com.apple.ocspd
12/9/13 7:39:27.000 PM kernel[0]: Sandbox: appleeventsd(53) deny mach-lookup com.apple.ocspd
12/9/13 7:39:27.760 PM sandboxd[238]: ([53]) appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.889 PM sandboxd[238]: ([53]) appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.895 PM sandboxd[238]: ([53]) appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.935 PM sandboxd[238]: ([53]) appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.941 PM sandboxd[238]: ([53]) appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.945 PM sandboxd[238]: ([53]) appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.950 PM sandboxd[238]: ([53]) appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:27.954 PM sandboxd[238]: ([53]) appleeventsd(53) deny file-read-metadata /Library
12/9/13 7:39:28.464 PM IPython Notebook[4527]: Removing cache file /Users/admin/Library/Containers/ch.entropy.ipython-notebook/Data/.matplotlib/fontList.cache
12/9/13 7:39:43.000 PM kernel[0]: Sandbox: python(4532) deny file-read-data /opt/X11/share/fonts/TTF
12/9/13 7:39:43.000 PM kernel[0]: Sandbox: python(4532) deny file-read-data /opt/X11/share/fonts
12/9/13 7:39:45.000 PM kernel[0]: Sandbox: python(4532) deny file-read-data /opt/X11/share/fonts/TTF
12/9/13 7:39:45.000 PM kernel[0]: Sandbox: python(4532) deny file-read-data /opt/X11/share/fonts

screen shot 2013-12-09 at 7 41 02 pm

@liyanage
Copy link
Owner

Thanks for the report. Do you see any occurrences of these log entries as well?

11/3/13 12:47:55.000 PM kernel[0]: exec of /Users/liyanage/Desktop/IPython Notebook.app/Contents/Resources/virtualenv/bin/python denied since it was quarantined by Safari.app and not approved by Gatekeeper, qtn-flags was 0x00000002
11/3/13 12:47:55.531 PM IPython Notebook[6471]: Couldn't posix_spawn: error 1

Also, how long does the spinner spin approximately before the sheet appears?

@suchow
Copy link
Author

suchow commented Dec 10, 2013

I see no occurrences of those log entries.

The spinner spins for about 15 s before the sheet appears. The arrival of the sheet comes at the same time that these messages are logged:

12/9/13 10:05:54.000 PM kernel[0]: Sandbox: python(4721) deny file-read-data /opt/X11/share/fonts/TTF
12/9/13 10:05:54.000 PM kernel[0]: Sandbox: python(4721) deny file-read-data /opt/X11/share/fonts

@suchow
Copy link
Author

suchow commented Dec 10, 2013

I restarted, opened iPython Notebook, and the error appeared in the same way as before, but there were three extra lines in the log:

12/9/13 10:33:16.839 PM com.apple.SecurityServer[26]: Killing auth hosts
12/9/13 10:33:16.839 PM com.apple.SecurityServer[26]: Session 100014 destroyed
12/9/13 10:33:16.841 PM com.apple.SecurityServer[26]: Session 100019 created

@liyanage
Copy link
Owner

Thanks for this additional information.

Could you run these commands and let me know what the output looks like on your system? This assumes that you have the app in /Applications, adjust accordingly if that's not the case:

xattr -p com.apple.quarantine /Applications/IPython\ Notebook.app
xattr -p com.apple.quarantine /Applications/IPython\ Notebook.app/Contents/Resources/virtualenv/bin/python
spctl --assess /Applications/IPython\ Notebook.app
spctl --assess /Applications/IPython\ Notebook.app/Contents/Resources/virtualenv/bin/python

and lastly, could you run this command and then try launching the app again:

xattr -dr com.apple.quarantine /Applications/IPython\ Notebook.app

@suchow
Copy link
Author

suchow commented Dec 10, 2013

➜  ~  xattr-2.7 -p com.apple.quarantine /Applications/IPython\ Notebook.app
xattr: /Applications/IPython Notebook.app: No such xattr: com.apple.quarantine
➜  ~  xattr-2.7 -p com.apple.quarantine /Applications/IPython\ Notebook.app/Contents/Resources/virtualenv/bin/python
xattr: /Applications/IPython Notebook.app/Contents/Resources/virtualenv/bin/python: No such xattr: com.apple.quarantine
➜  ~  spctl --assess /Applications/IPython\ Notebook.app
➜  ~  spctl --assess /Applications/IPython\ Notebook.app/Contents/Resources/virtualenv/bin/python
➜  ~  xattr-2.7 -dr com.apple.quarantine /Applications/IPython\ Notebook.app
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/.Python'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/include/python2.7'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/_abcoll.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/_weakrefset.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/abc.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/codecs.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/config'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/copy_reg.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/encodings'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/fnmatch.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/genericpath.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/lib-dynload'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/linecache.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/locale.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/ntpath.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/os.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/posixpath.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/re.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/sre.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/sre_compile.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/sre_constants.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/sre_parse.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/stat.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/types.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/UserDict.py'
xattr: [Errno 13] Permission denied: '/Applications/IPython Notebook.app/Contents/Resources/virtualenv/lib/python2.7/warnings.py'

@liyanage
Copy link
Owner

Thanks again. Given the output of the first commands it probably won't make a difference, but could you try re-running the last one with sudo?

sudo xattr -dr com.apple.quarantine /Applications/IPython\ Notebook.app

BTW, your snippet shows xattr-2.7 instead of just xattr. Is that how you ran it?

@suchow
Copy link
Author

suchow commented Dec 10, 2013

When I first ran xattr, I got the message:

python version 2.7.6 can't run /usr/bin/xattr.  Try the alternative(s):

/usr/bin/xattr-2.5 (uses python 2.5)
/usr/bin/xattr-2.6 (uses python 2.6)
/usr/bin/xattr-2.7 (uses python 2.7)

Run "man python" for more information about multiple version support in
Mac OS X.

which is why I switched to xattr-2.7.

When I now run the command you suggest (but with xattr-2.7), I get no output:

➜  ~  sudo xattr-2.7 -dr com.apple.quarantine /Applications/IPython\ Notebook.app
➜  ~

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants