Opened 9 years ago

Closed 9 years ago

Last modified 8 years ago

#10588 closed task (fixed)

Upgrade to matplotlib 1.0.1

Reported by: ryan Owned by: tbd
Priority: major Milestone: sage-4.6.2
Component: packages: standard Keywords: matplotlib
Cc: kcrisman Merged in: sage-4.6.2.alpha1
Authors: Ryan Grout Reviewers: Jason Grout, Dan Drake
Report Upstream: N/A Work issues:
Branch: Commit:
Dependencies: Stopgaps:

Description (last modified by ryan)

Upgrading from matplotlib 1.0.0 to matplotlib 1.0.1

This supposedly fixes #4194 Also we can remove 2 patches in the patches directory (font_config.py and WrapPython?.py) as they were committed upstream.

http://sage.math.washington.edu/home/rgrout/matplotlib-1.0.1.spkg

Change History (12)

comment:1 Changed 9 years ago by ryan

  • Description modified (diff)
  • Status changed from new to needs_review

comment:2 Changed 9 years ago by ryan

  • Description modified (diff)

comment:3 Changed 9 years ago by kcrisman

  • Cc kcrisman added

comment:4 Changed 9 years ago by jason

Looks good on OSX

comment:5 Changed 9 years ago by ddrake

Installs and plots on sage.math.

comment:6 Changed 9 years ago by kcrisman

  • Reviewers set to Jason Grout, Dan Drake

Do all the plots seem good - or at least a representative sample of our doctests? This is what always takes me a long time in reviewing such things, though using the notebook version of the docs helps.

Also, be sure to review it on Solaris, given the failures in the past :(

Unhelpfully yours (as not actually doing any work for it), kcrisman

comment:7 follow-up: Changed 9 years ago by jason

Dan: quick ping about Solaris. Did it compile okay on Solaris? That was one of the bugfixes that went in upstream in this release, so we should definitely test it.

comment:8 in reply to: ↑ 7 Changed 9 years ago by ddrake

  • Status changed from needs_review to positive_review

Replying to jason:

Dan: quick ping about Solaris. Did it compile okay on Solaris? That was one of the bugfixes that went in upstream in this release, so we should definitely test it.

Sorry for the delay...I started compiling on t2.math and forgot about it. (Soon I hope to have access to a faster Solaris machine.) I installed this spkg and all tests in sage/plot passed. I think we can call this a positive review; it's a small update and works on Linux, OS X, and Solaris.

comment:9 Changed 9 years ago by jdemeyer

  • Merged in set to sage-4.6.2.alpha1
  • Resolution set to fixed
  • Status changed from positive_review to closed

comment:10 follow-up: Changed 8 years ago by leif

~/Sage/spkgs/matplotlib-1.0.1$ du -ch src/build/
1.4M    src/build/temp.linux-i686-2.7/src
192K    src/build/temp.linux-i686-2.7/lib/matplotlib/tri
84K     src/build/temp.linux-i686-2.7/lib/matplotlib/delaunay
280K    src/build/temp.linux-i686-2.7/lib/matplotlib
284K    src/build/temp.linux-i686-2.7/lib
192K    src/build/temp.linux-i686-2.7/CXX
64K     src/build/temp.linux-i686-2.7/agg24/src
68K     src/build/temp.linux-i686-2.7/agg24
76K     src/build/temp.linux-i686-2.7/ttconv
2.0M    src/build/temp.linux-i686-2.7
172K    src/build/lib.linux-i686-2.7/mpl_toolkits/axisartist
96K     src/build/lib.linux-i686-2.7/mpl_toolkits/axes_grid
88K     src/build/lib.linux-i686-2.7/mpl_toolkits/mplot3d
152K    src/build/lib.linux-i686-2.7/mpl_toolkits/axes_grid1
540K    src/build/lib.linux-i686-2.7/mpl_toolkits
36K     src/build/lib.linux-i686-2.7/matplotlib/backends/Matplotlib.nib
32K     src/build/lib.linux-i686-2.7/matplotlib/backends/qt4_editor
1.5M    src/build/lib.linux-i686-2.7/matplotlib/backends
112K    src/build/lib.linux-i686-2.7/matplotlib/tests/baseline_images/test_text
712K    src/build/lib.linux-i686-2.7/matplotlib/tests/baseline_images/test_image
8.5M    src/build/lib.linux-i686-2.7/matplotlib/tests/baseline_images/test_axes
224K    src/build/lib.linux-i686-2.7/matplotlib/tests/baseline_images/test_simplification
1.3M    src/build/lib.linux-i686-2.7/matplotlib/tests/baseline_images/test_mathtext
388K    src/build/lib.linux-i686-2.7/matplotlib/tests/baseline_images/test_dates
76K     src/build/lib.linux-i686-2.7/matplotlib/tests/baseline_images/test_spines
12M     src/build/lib.linux-i686-2.7/matplotlib/tests/baseline_images
12M     src/build/lib.linux-i686-2.7/matplotlib/tests
64K     src/build/lib.linux-i686-2.7/matplotlib/testing/jpl_units
92K     src/build/lib.linux-i686-2.7/matplotlib/testing
2.2M    src/build/lib.linux-i686-2.7/matplotlib/mpl-data/fonts/ttf
816K    src/build/lib.linux-i686-2.7/matplotlib/mpl-data/fonts/afm
668K    src/build/lib.linux-i686-2.7/matplotlib/mpl-data/fonts/pdfcorefonts
3.7M    src/build/lib.linux-i686-2.7/matplotlib/mpl-data/fonts
268K    src/build/lib.linux-i686-2.7/matplotlib/mpl-data/images
4.0M    src/build/lib.linux-i686-2.7/matplotlib/mpl-data
8.0K    src/build/lib.linux-i686-2.7/matplotlib/numerix/random_array
8.0K    src/build/lib.linux-i686-2.7/matplotlib/numerix/ma
8.0K    src/build/lib.linux-i686-2.7/matplotlib/numerix/mlab
8.0K    src/build/lib.linux-i686-2.7/matplotlib/numerix/fft
8.0K    src/build/lib.linux-i686-2.7/matplotlib/numerix/linear_algebra
52K     src/build/lib.linux-i686-2.7/matplotlib/numerix
40K     src/build/lib.linux-i686-2.7/matplotlib/tri
48K     src/build/lib.linux-i686-2.7/matplotlib/delaunay
60K     src/build/lib.linux-i686-2.7/matplotlib/sphinxext
56K     src/build/lib.linux-i686-2.7/matplotlib/projections
22M     src/build/lib.linux-i686-2.7/matplotlib
22M     src/build/lib.linux-i686-2.7
24M     src/build/
24M     total


Also, this spkg reintroduced the race condition in creating the TeX font cache directory (#10159), because the patch to font_manager.py was dropped, apparently without having checked whether the issue had really been fixed (see #11686):

  • spkg-install

    diff -r 766b19e00183 -r cd80018a5dc7 spkg-install
    a b  
    1717
    1818# Use patched versions.  See SPKG.txt for why and what.
    1919$CP patches/setupext.py src
    20 $CP patches/WrapPython.h src/CXX
    21 $CP patches/font_manager.py src/lib/matplotlib
    2220cd src
    2321
    2422# Now build

The bug indeed hasn't been fixed in the new upstream release, it just moved to another file, src/lib/matplotlib/texmanager.py.


Both SPKG.txt and the commit message lack a ticket number.

comment:11 in reply to: ↑ 10 Changed 8 years ago by leif

Replying to leif:

Also, this spkg reintroduced the race condition in creating the TeX font cache directory (#10159), because the patch to font_manager.py was dropped, apparently without having checked whether the issue had really been fixed (see #11686):

Whoops, the situation is a bit different:

While the spkg here did reintroduce the bug, it didn't because a patch was removed, but because it was based on an obsolete spkg, and not that of #10159 (which was merged into Sage 4.6.1.alpha0):

== Changelog ==
=== matplotlib 1.0.1 (Ryan Grout, 10 Jan 2011) ===
 * Update to matplotlib 1.0.1.  Fixes a handful of annoying bugs in SAGE.

=== matplotlib 1.0.0 (Jason Grout, 01 Oct 2010) ===
 * Update to matplotlib 1.0.0.  Include two upstream fixes that were committed since 1.0.0.

vs.

== Changelog ==

=== matplotlib 1.0.0.p0 (John Palmieri, 23 Oct 2010) ===
 * Patch __init__.py, finance.py, and texmanager.py to avoid race
   conditions when creating directories.

=== matplotlib 1.0.0 (Jason Grout, 01 Oct 2010) ===
 * Update to matplotlib 1.0.0.  Include two upstream fixes that were
   committed since 1.0.0.

So the bug is still in the upstream sources, and in the same file(s), e.g. src/lib/matplotlib/texmanager.py:

~/Sage/spkgs/matplotlib-1.0.1$ grep -n -C2 mkdir src/lib/matplotlib/texmanager.py 
90-        shutil.move(oldcache, texcache)
91-    if not os.path.exists(texcache):
92:        os.mkdir(texcache)
93-
94-    _dvipng_hack_alpha = None
--
132-
133-        if not os.path.isdir(self.texcache):
134:            os.mkdir(self.texcache)
135-        ff = rcParams['font.family'].lower()
136-        if ff in self.font_families:

(Just to clarify; this certainly belongs to the new ticket, #11686.)

comment:12 Changed 8 years ago by jdemeyer

My merge script will now check for the existence of the version number of the old spkg inside the new SPKG.txt, so this kind of error should not happen again (or at least it will be less likely).

Note: See TracTickets for help on using tickets.