[matplotlib-devel] No output when using webagg backend
Apologies for those of you seeing this for a second time. I've
received no response on matplotlib-users, so I'm turning to the
experts.
In one message, I wrote:
I'm trying to use the webagg backend for the first time, and seem to
be bumping into a common problem - nothing appears. The first time I
tried, I got a complaint that tornado was missing, so I installed it.
After that, I get to try plotting. Here's my example:
>>> import matplotlib
>>> matplotlib.use('webagg')
>>> import matplotlib.pyplot as plt
>>> plt.plot(range(10))
[]
>>> plt.show()
Created new window in existing browser session.
Press Ctrl+C to stop server
^CServer stopped
When I execute plt.show(), a new tab opens in my browser (Chrome, on
Linux) with this URL: http://127.0.0.1:8988. That page has a single
link (text: "Figure 1"). If I click that link, I get this URL:
http://127.0.0.1:8988/1, but nothing appears. The page source contains
a bunch of JavaScript references. For instance:
I see those JavaScript files at appropriate places in the
.../backends/web_backend directory. What am I missing?
then followed that up with a bit more information:
I tried this at home on my Mac. Tornado was already installed, so I
updated it to 3.2.1, and ran a Matplotlib app I have which allows me
to set the backend on the command line. I get the exact same behavior
as at work on my Linux desktop. I get a page at 127.0.0:8988 with a
"Figure 1" link. Clicking that takes me to 127.0.0.1:8988/1, which is
a blank page.
Chrome is my default web browser on both Linux and the Mac. I manually
visited the page from both Firefox and Safari, clicked the link,
and... nothing. The same behavior as on Chrome.
Then I had the bright idea to look at the JavaScript console. It shows
this error message:
Uncaught SyntaxError: Unexpected token &
Clicking that error took me to this line:
var fig = new figure('1', websocket_url_prefix);
Are those entities supposed to be '1'? What bit of code generates
that JavaScript?
Can someone provide a bit of direction? I can't find the code that
generates the above snippet of JavaScript, but Chrome, at least,
doesn't like it.
Thx,
Skip
--
Is your legacy SCM system holding you back? Join Perforce May 7 to find out:
• 3 signs your SCM is hindering your productivity
• Requirements for releasing software faster
• Expert tips and advice for migrating your SCM now
http://p.sf.net/sfu/perforce
___
Matplotlib-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
[matplotlib-devel] Minimum python version 2.6 vs 2.7
Hello Working on the MEP22 I would like to use an OrderedDict but it is only natively available from python 2.7 Are there any plans to remove 2.6 for matplotlib 1.5? If not. I will just use a list with dicts inside, not as elegant but works. Thanks Federico -- Is your legacy SCM system holding you back? Join Perforce May 7 to find out: • 3 signs your SCM is hindering your productivity • Requirements for releasing software faster • Expert tips and advice for migrating your SCM now http://p.sf.net/sfu/perforce___ Matplotlib-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
Re: [matplotlib-devel] Minimum python version 2.6 vs 2.7
Yes I know. But I don't want to pollute more than strictly necessary. There is already too much unused code around. Federico On 7 May 2014 11:12, "Nathaniel Smith" wrote: > It is also technically possible to use a drop-in fallback > implementation on older pythons, e.g.: > https://github.com/pydata/patsy/blob/master/patsy/compat.py#L120 > https://github.com/pydata/patsy/blob/master/patsy/compat_ordereddict.py > > -n > > On Wed, May 7, 2014 at 4:03 PM, Federico Ariza > wrote: > > Hello > > > > Working on the MEP22 I would like to use an OrderedDict but it is only > > natively available from python 2.7 > > > > Are there any plans to remove 2.6 for matplotlib 1.5? > > > > If not. I will just use a list with dicts inside, not as elegant but > works. > > > > Thanks > > Federico > > > > > > > -- > > Is your legacy SCM system holding you back? Join Perforce May 7 to find > out: > > • 3 signs your SCM is hindering your productivity > > • Requirements for releasing software faster > > • Expert tips and advice for migrating your SCM now > > http://p.sf.net/sfu/perforce > > ___ > > Matplotlib-devel mailing list > > [email protected] > > https://lists.sourceforge.net/lists/listinfo/matplotlib-devel > > > > > > -- > Nathaniel J. Smith > Postdoctoral researcher - Informatics - University of Edinburgh > http://vorpus.org > -- Is your legacy SCM system holding you back? Join Perforce May 7 to find out: • 3 signs your SCM is hindering your productivity • Requirements for releasing software faster • Expert tips and advice for migrating your SCM now http://p.sf.net/sfu/perforce___ Matplotlib-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
Re: [matplotlib-devel] Minimum python version 2.6 vs 2.7
It is also technically possible to use a drop-in fallback implementation on older pythons, e.g.: https://github.com/pydata/patsy/blob/master/patsy/compat.py#L120 https://github.com/pydata/patsy/blob/master/patsy/compat_ordereddict.py -n On Wed, May 7, 2014 at 4:03 PM, Federico Ariza wrote: > Hello > > Working on the MEP22 I would like to use an OrderedDict but it is only > natively available from python 2.7 > > Are there any plans to remove 2.6 for matplotlib 1.5? > > If not. I will just use a list with dicts inside, not as elegant but works. > > Thanks > Federico > > > -- > Is your legacy SCM system holding you back? Join Perforce May 7 to find out: > • 3 signs your SCM is hindering your productivity > • Requirements for releasing software faster > • Expert tips and advice for migrating your SCM now > http://p.sf.net/sfu/perforce > ___ > Matplotlib-devel mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/matplotlib-devel > -- Nathaniel J. Smith Postdoctoral researcher - Informatics - University of Edinburgh http://vorpus.org -- Is your legacy SCM system holding you back? Join Perforce May 7 to find out: • 3 signs your SCM is hindering your productivity • Requirements for releasing software faster • Expert tips and advice for migrating your SCM now http://p.sf.net/sfu/perforce ___ Matplotlib-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/matplotlib-devel
