On 30 July 2014 11:37, Francois Bissey <francois.bis...@canterbury.ac.nz> wrote:
> matplotlib as predicted. The following is useful:
> http://matplotlib.org/users/customizing.html
>
> You can change your user matplotlibrc to default PDF as the backend.
> It could be setup before tests that will call matplotlib with matplotlib.rc()
> grep for matplotlibrc to see what you have by default with your sage install.

Well, I have never knowingly done anything with matplotlib at all!  So
shouldn't the tests work?  It's not as if I have some strangely
customised setup.

The sage install has created

$SAGE_ROOT/local/lib/python2.7/site-packages/matplotlib-1.3.1-py2.7-linux-x86_64.egg/matplotlib/mpl-data/matplotlibrc

which sets the backend to tkagg.  I tried copying that file to the
suggested place ~/.config/matplotlib/matplotlibrc  (the directory
existed but was empty) and changing tkagg to pdf but the test still
gives the error about failing to connect to localhost:12.0

John

>
> François
> On 30/07/2014, at 22:21, John Cremona <john.crem...@gmail.com> wrote:
>
>> On 30 July 2014 11:10, Francois Bissey <francois.bis...@canterbury.ac.nz> 
>> wrote:
>>> Not exactly. The problem here is that some component (probably matplotlib)
>>> detected that some gui tools are available (here tcl) and built the 
>>> corresponding
>>> interface. If matplotlib has a gui it will try to use it by default instead 
>>> of
>>> doing everything on file.
>>>
>>> I think we could set some default for it not to happen. If you were posting 
>>> the details
>>> of a failure we could confirm it is matplotlib acting up (even in the gsl 
>>> doctests).
>>
>> OK, here is some detail:
>>
>> File "src/sage/gsl/probability_distribution.pyx", line 118, in
>> sage.gsl.probability_di
>> stribution.ProbabilityDistribution.generate_histogram_data
>> Failed example:
>>    h, b = X.generate_histogram_data(bins = 10)
>> Exception raised:
>>    Traceback (most recent call last):
>>      File 
>> "/home/jec/sage/local/lib/python2.7/site-packages/sage/doctest/forker.py",
>> line 480, in _run
>>        self.execute(example, compiled, test.globs)
>>      File 
>> "/home/jec/sage/local/lib/python2.7/site-packages/sage/doctest/forker.py",
>> line 839, in execute
>>        exec compiled in globs
>>      File "<doctest
>> sage.gsl.probability_distribution.ProbabilityDistribution.generat
>> e_histogram_data[3]>", line 1, in <module>
>>        h, b = X.generate_histogram_data(bins = Integer(10))
>>      File "probability_distribution.pyx", line 127, in
>> sage.gsl.probability_distribut
>> ion.ProbabilityDistribution.generate_histogram_data
>> (build/cythonized/sage/gsl/probabi
>> lity_distribution.c:1468)
>>      File 
>> "/home/jec/sage/local/lib/python2.7/site-packages/matplotlib-1.3.1-py2.7-li
>> nux-x86_64.egg/matplotlib/pyplot.py", line 2816, in hist
>>        ax = gca()
>>      File 
>> "/home/jec/sage/local/lib/python2.7/site-packages/matplotlib-1.3.1-py2.7-li
>> nux-x86_64.egg/matplotlib/pyplot.py", line 803, in gca
>>        ax =  gcf().gca(**kwargs)
>>      File 
>> "/home/jec/sage/local/lib/python2.7/site-packages/matplotlib-1.3.1-py2.7-li
>> nux-x86_64.egg/matplotlib/pyplot.py", line 450, in gcf
>>        return figure()
>>      File 
>> "/home/jec/sage/local/lib/python2.7/site-packages/matplotlib-1.3.1-py2.7-li
>> nux-x86_64.egg/matplotlib/pyplot.py", line 423, in figure
>>        **kwargs)
>>      File 
>> "/home/jec/sage/local/lib/python2.7/site-packages/matplotlib-1.3.1-py2.7-li
>> nux-x86_64.egg/matplotlib/backends/backend_tkagg.py", line 79, in
>> new_figure_manager
>>        return new_figure_manager_given_figure(num, figure)
>>      File 
>> "/home/jec/sage/local/lib/python2.7/site-packages/matplotlib-1.3.1-py2.7-li
>> nux-x86_64.egg/matplotlib/backends/backend_tkagg.py", line 87, in
>> new_figure_manager_g
>> iven_figure
>>        window = Tk.Tk()
>>      File "/home/jec/sage/local/lib/python2.7/lib-tk/Tkinter.py",
>> line 1764, in __ini
>> t__
>>        self.tk = _tkinter.create(screenName, baseName, className,
>> interactive, wantob
>> jects, useTk, sync, use)
>>    TclError: couldn't connect to display "localhost:12.0"
>>
>> in case it helps.
>>
>> John
>>
>>>
>>> On my Gentoo box I have:
>>> sage -t --long src/sage/plot/plot.py
>>> **********************************************************************
>>> File "src/sage/plot/plot.py", line 92, in sage.plot.plot
>>> Failed example:
>>>    plot(x^2, (x,0,5))
>>> Expected nothing
>>> Got:
>>>    Fontconfig warning: "/etc/fonts/conf.d/59-google-droid-sans.conf", line 
>>> 61: Having multiple values in <test> isn't supported and may not work as 
>>> expected
>>>    Fontconfig warning: "/etc/fonts/conf.d/59-google-droid-sans.conf", line 
>>> 96: Having multiple values in <test> isn't supported and may not work as 
>>> expected
>>>    Fontconfig warning: "/etc/fonts/conf.d/59-google-droid-sans.conf", line 
>>> 61: Having multiple values in <test> isn't supported and may not work as 
>>> expected
>>>    Fontconfig warning: "/etc/fonts/conf.d/59-google-droid-sans.conf", line 
>>> 96: Having multiple values in <test> isn't supported and may not work as 
>>> expected
>>> **********************************************************************
>>>
>>> I don't usually report those, that's just unhelpful noise caused by some 
>>> settings of
>>> the distro. What's more I don't get that one in sage-on-gentoo probably 
>>> because I
>>> build matplotlib with different options.
>>>
>>> François
>>> On 30/07/2014, at 21:36, John Cremona <john.crem...@gmail.com> wrote:
>>>
>>>> I have these failures with make ptestlong (ubuntu 12.04):
>>>>
>>>> sage -t --long src/sage/plot/plot.py  # 20 doctests failed
>>>> sage -t --long src/sage/gsl/probability_distribution.pyx  # 4 doctests 
>>>> failed
>>>> sage -t --long src/sage/sandpiles/sandpile.py  # Timed out
>>>>
>>>> The plot and gsl ones are all caused by
>>>>
>>>> TclError: couldn't connect to display "localhost:12.0"
>>>>
>>>> -- do we have to have doctests which rely on such permissions?
>>>>
>>>> On 30 July 2014 09:15, Daniel Krenn <kr...@aon.at> wrote:
>>>>> Am 2014-07-28 um 19:40 schrieb Volker Braun:
>>>>>> See the "develop" git branch or download the all-in-one tarball
>>>>>
>>>>> make distclean
>>>>> make
>>>>>
>>>>> worked fine on my Debian.
>>>>>
>>>>> make ptestlong
>>>>>
>>>>> gives
>>>>>
>>>>> sage -t --long src/sage/graphs/generic_graph.py  # 4 doctests failed
>>>>> sage -t --long src/sage/graphs/graph.py  # 6 doctests failed
>>>>> sage -t --long src/sage/graphs/graph_list.py  # 4 doctests failed
>>>>> sage -t --long src/sage/schemes/elliptic_curves/monsky_washnitzer.py  #
>>>>> 16 doctests failed
>>>>> sage -t --long src/sage/databases/sql_db.py  # 14 doctests failed
>>>>> sage -t --long src/sage/graphs/isgci.py  # 44 doctests failed
>>>>> sage -t --long src/sage/graphs/graph_database.py  # 28 doctests failed
>>>>>
>>>>> There,
>>>>>
>>>>> sage -t --long src/sage/schemes/elliptic_curves/monsky_washnitzer.py  #
>>>>> 16 doctests failed
>>>>>
>>>>> seems to be new (compared to the other postings with failing tests)
>>>>>
>>>>> Daniel
>>>>>
>>>>>
>>>>> --
>>>>> You received this message because you are subscribed to the Google Groups 
>>>>> "sage-release" group.
>>>>> To unsubscribe from this group and stop receiving emails from it, send an 
>>>>> email to sage-release+unsubscr...@googlegroups.com.
>>>>> To post to this group, send email to sage-release@googlegroups.com.
>>>>> Visit this group at http://groups.google.com/group/sage-release.
>>>>> For more options, visit https://groups.google.com/d/optout.
>>>>
>>>> --
>>>> You received this message because you are subscribed to the Google Groups 
>>>> "sage-release" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send an 
>>>> email to sage-release+unsubscr...@googlegroups.com.
>>>> To post to this group, send email to sage-release@googlegroups.com.
>>>> Visit this group at http://groups.google.com/group/sage-release.
>>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>>
>>> This email may be confidential and subject to legal privilege, it may
>>> not reflect the views of the University of Canterbury, and it is not
>>> guaranteed to be virus free. If you are not an intended recipient,
>>> please notify the sender immediately and erase all copies of the message
>>> and any attachments.
>>>
>>> Please refer to http://www.canterbury.ac.nz/emaildisclaimer for more
>>> information.
>>>
>>> --
>>> You received this message because you are subscribed to the Google Groups 
>>> "sage-release" group.
>>> To unsubscribe from this group and stop receiving emails from it, send an 
>>> email to sage-release+unsubscr...@googlegroups.com.
>>> To post to this group, send email to sage-release@googlegroups.com.
>>> Visit this group at http://groups.google.com/group/sage-release.
>>> For more options, visit https://groups.google.com/d/optout.
>>
>> --
>> You received this message because you are subscribed to the Google Groups 
>> "sage-release" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to sage-release+unsubscr...@googlegroups.com.
>> To post to this group, send email to sage-release@googlegroups.com.
>> Visit this group at http://groups.google.com/group/sage-release.
>> For more options, visit https://groups.google.com/d/optout.
>
>
> This email may be confidential and subject to legal privilege, it may
> not reflect the views of the University of Canterbury, and it is not
> guaranteed to be virus free. If you are not an intended recipient,
> please notify the sender immediately and erase all copies of the message
> and any attachments.
>
> Please refer to http://www.canterbury.ac.nz/emaildisclaimer for more
> information.
>
> --
> You received this message because you are subscribed to the Google Groups 
> "sage-release" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to sage-release+unsubscr...@googlegroups.com.
> To post to this group, send email to sage-release@googlegroups.com.
> Visit this group at http://groups.google.com/group/sage-release.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"sage-release" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-release+unsubscr...@googlegroups.com.
To post to this group, send email to sage-release@googlegroups.com.
Visit this group at http://groups.google.com/group/sage-release.
For more options, visit https://groups.google.com/d/optout.

Reply via email to