[matplotlib-devel] python-2.3 support

2007-09-21 Thread Darren Dale
It looks like some syntax introduced in python-2.4 is starting to find its
way into matplotlib:

  File
"/usr/lib/python2.3/site-packages/matplotlib-0.90.1_r3867-py2.3-linux-i686.egg/matplotlib/texmanager.py",
line 113
+ tuple('font.'+n for n in ('family', ) + font_families)
^
SyntaxError: invalid syntax
  File
"/usr/lib/python2.3/site-packages/matplotlib-0.90.1_r3867-py2.3-linux-i686.egg/matplotlib/dviread.py",
line 355
for ch in special),
  ^
SyntaxError: invalid syntax
  File
"/usr/lib/python2.3/site-packages/matplotlib-0.90.1_r3867-py2.3-linux-i686.egg/matplotlib/config/mpltraits.py",
line 49
return "one of %s"% ', '.join('%s'%i for i in be)
   ^
SyntaxError: invalid syntax
  File
"/usr/lib/python2.3/site-packages/matplotlib-0.90.1_r3867-py2.3-linux-i686.egg/matplotlib/backends/backend_pdf.py",
line 544
not_None = (ch for ch in range(256)
 ^
SyntaxError: invalid syntax


Does anyone have an opinion on how much longer we will support python-2.3?
Maybe a good guide would be to support the most up-to-date RHEL release,
as well as the prior release. (At my lab, we haven't updated our RHEL
computers to version 5 yet, the first to include python-2.4.)

Darren


-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Matplotlib-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] python-2.3 support

2007-09-21 Thread John Hunter
On 9/21/07, Darren  Dale <[EMAIL PROTECTED]> wrote:

> Does anyone have an opinion on how much longer we will support python-2.3?
> Maybe a good guide would be to support the most up-to-date RHEL release,
> as well as the prior release. (At my lab, we haven't updated our RHEL
> computers to version 5 yet, the first to include python-2.4.)

I think we should continue to support it for a while yet, mainly
because it is easy to do so.  We don't really need generator
comprehensions -- in the examples you highlighted I think they were
used for syntactic convenience, though admittedly in some cases syntax
conveniences are compelling.

I only recently upgraded from 2.3 on my home machine, when I was
trying to get svn traits working.  I am not sure that RHEL should be
our standard though -- shouldn't people be punished for using that
distro anyway ?

A good way to know it's time to deprecate support is when you
accidentally break something and noone notices for a month or two
because noone is actually using it.

JDH

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Matplotlib-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] python-2.3 support

2007-09-21 Thread Michael Droettboom
> Does anyone have an opinion on how much longer we will support python-2.3?
> Maybe a good guide would be to support the most up-to-date RHEL release,
> as well as the prior release. (At my lab, we haven't updated our RHEL
> computers to version 5 yet, the first to include python-2.4.)

Is the current Mac OS-X version also something to consider?  It's 
currently at 2.3 in 10.4 Tiger.

Cheers,
Mike

-- 
Michael Droettboom
Operations and Engineering Division
Space Telescope Science Institute
Operated by AURA for NASA

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Matplotlib-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


[matplotlib-devel] cbook.reversed does not yield the same result as the python builtin

2007-09-21 Thread Darren Dale
After removing my build/ and site-packages-matplotlib*, I installed the
most up-to-date svn numpy and matplotlib on a RHEL4 machine. I'm getting
the following errors:

  File
"/usr/lib/python2.3/site-packages/matplotlib-0.90.1_r3867-py2.3-linux-i686.egg/matplotlib/_cm.py",
line 5962, in ?
cmapdat_r = revcmap(datad[cmapname])
  File
"/usr/lib/python2.3/site-packages/matplotlib-0.90.1_r3867-py2.3-linux-i686.egg/matplotlib/_cm.py",
line 5955, in revcmap
valnew = [(1.-a, b, c) for a, b, c in reversed(val)]
ValueError: unpack tuple of wrong size

Here is the output of all the reversed(val):


(10, (1.0, 0.63529413938522339, 0.63529413938522339))
(9, (0.90002, 0.74117648601531982, 0.74117648601531982))
(8, (0.80004, 0.64705884456634521, 0.64705884456634521))
(7, (0.69996, 0.64313727617263794, 0.64313727617263794))
(6, (0.59998, 0.59607845544815063, 0.59607845544815063))
(5, (0.5, 0.74901962280273438, 0.74901962280273438))
(4, (0.40002, 0.54509806632995605, 0.54509806632995605))
(3, (0.2, 0.3803921639919281, 0.3803921639919281))
(2, (0.20001, 0.26274511218070984, 0.26274511218070984))
(1, (0.10001, 0.30980393290519714, 0.30980393290519714))
(0, (0.0, 0.25882354378700256, 0.25882354378700256))

I don't get the error with python-2.5. reversed is defined by cbook if
python doesnt have it as a builtin, but cbook yields an (index, tuple)
whereas the builtin yields only the tuple. I changed cbook's reversed to
agree with the python builtin, and made notes in the CHANGELOG and
API_CHANGES.

Darren


-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Matplotlib-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel


Re: [matplotlib-devel] python-2.3 support

2007-09-21 Thread Christopher Barker
Michael Droettboom wrote:
> Is the current Mac OS-X version also something to consider? 

I don't think so. You really need to install a newer/better version to 
do anything significant with python on OS-X -- particularly anything 
with a GUI.

John Hunter wrote:
> We don't really need generator
> comprehensions -- in the examples you highlighted I think they were
> used for syntactic convenience, though admittedly in some cases syntax
> conveniences are compelling.

Sure they are, but wouldn't list comprehensions be just as good? at 
least in those cases.

-Chris





-- 
Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R(206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115   (206) 526-6317   main reception

[EMAIL PROTECTED]

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
Matplotlib-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel