John Hunter <jdh2...@gmail.com> writes:

> * I commented out the random number appending, because I do not see
> the use case, but we can re-add it when you enlighten me :-)

I did that in case someone wanted to retrieve files from several
different locations -- my version of the cache handler was not tied to
any particular base URL. Since all cached files were in one flat
directory, there was the danger of filename collisions. 

> * I added support for nested subdirs, so you can now do, as in
> examples/misc/sample_data_test.py::
>
>     datafile = 'testdir/subdir/testsub.csv'
>     fh = cbook.get_sample_data(datafile)

I think mirroring a directory structure is somewhat more complicated
than caching a set of arbitrary URLs in a flat cache directory. For
example, I think the remove_stale_files method will need to be changed
to walk all subdirectories, and handling cases such as having a
subdirectory named foo that is replaced by a file named foo could be
complicated.

One thing that's still missing is off-line usage: if the user does not
have net connectivity at the moment but does have the file in the cache,
it should not cause an error.

Perhaps the base URL should be 
http://matplotlib.svn.sourceforge.net/svnroot/matplotlib/trunk/sample_data/
instead of
http://matplotlib.svn.sourceforge.net/viewvc/matplotlib/trunk/sample_data/
to avoid dependency on the viewvc service of SourceForge.

-- 
Jouni K. Seppänen
http://www.iki.fi/jks


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel

Reply via email to