# Kernel dies with matplotlib usetex and PDF

I'm looking to save my Sage figures with matplotlib's usetex option, so that I can match the fonts to my document's fonts. The following code works to do this if I switch the filename extension in the last line to png, but for some reason when I try to save a pdf instead, the kernel dies. I would be grateful for any suggestions.

`from matplotlib import rc`

`rc('text',usetex=True)`

`rc('font',serif='Palatino')`

`p = plot(sin(x),x,0,2*pi,axes_labels=['$x$','$\sin x$'])`

`save(p,filename="tmp.pdf")`

It works for me (Sage 6.10.rc1 complied on Debian jessie 64bit, run from the command line). Could you please give us some informations so that someone can try to reproduce your problem:

Thanks for the reply! It's good to know this problem is not universal. I'm using Sage 6.8, installed on OS X (10.10.5) using binaries (not sure which ones -- I went to the downloads page and did what seemed natural; not sure if that helps). I was using Jupyter notebook, but I just checked that the error also occurs in the Sage notebook. I get no error message in Jupyter (kernel just dies), but in the Sage notebook I get a generic 'Unhandled SIGABRT' message.

I've tried with the same version of Sage as yours (6.8) in a Jupyter notebook under Ubuntu 14.04: it works fine. So maybe there is a problem with your Sage install. Could you install a more recent version (i.e. Sage 6.9) and try again ?

OK, I upgraded to version 6.9 and everything works fine. Thanks!