Russell E. Owen | 18 Sep 21:29

Outdated pytz and dateutil

The versions of pytz and dateutil that are included with matplotlib 
0.98.3 are outdated.

dateutil 1.2 is included, but 1.4.1 is available
pytz: 2008c (from pypi)

I am against including them at all (especially if they are installed 
even if the user already has the packages available). They are both 
trivial to install from source.

In the case of pytz one can also use easy_install (and presumably this 
can happen automatically via dependency handling). Unfortunately that is 
not a good idea for dateutil; I just tried it and got version 1.1. Yow.

-- Russell

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
John Hunter | 18 Sep 22:36
Gravatar

Re: Outdated pytz and dateutil

On Thu, Sep 18, 2008 at 2:33 PM, Russell E. Owen <rowen <at> u.washington.edu> wrote:
> The versions of pytz and dateutil that are included with matplotlib
> 0.98.3 are outdated.
>
> dateutil 1.2 is included, but 1.4.1 is available
> pytz: 2008c (from pypi)
>
> I am against including them at all (especially if they are installed
> even if the user already has the packages available). They are both
> trivial to install from source.
>
> In the case of pytz one can also use easy_install (and presumably this
> can happen automatically via dependency handling). Unfortunately that is
> not a good idea for dateutil; I just tried it and got version 1.1. Yow.

Hey Russell, thanks for the head's up.

For our source installs, by default we install them only if they are
not on the system, but you can configure this with setup.cfg to
always, never or conditionally install them.

I have updated the mpl versions to the ones you point to above.

svn users -- if you want to upgrade to the latest using the mpl
versions, cp setup.cfg.template to setup.cfg, uncomment the following
lines, and set them to True

   ## Date/timezone support:
   pytz = True
   dateutil = True
(Continue reading)

Russell E. Owen | 24 Sep 02:19

Re: Outdated pytz and dateutil

In article 
<88e473830809181336k29ca7ec1n1e1d2c3ba24c3dac@...>,
 "John Hunter" <jdh2358@...> wrote:

> On Thu, Sep 18, 2008 at 2:33 PM, Russell E. Owen <rowen <at> u.washington.edu> 
> wrote:
> > The versions of pytz and dateutil that are included with matplotlib
> > 0.98.3 are outdated....
> 
> Hey Russell, thanks for the head's up.
> 
> For our source installs, by default we install them only if they are
> not on the system, but you can configure this with setup.cfg to
> always, never or conditionally install them.
> 
> I have updated the mpl versions to the ones you point to above.

I just discovered that matplotlib 0.98.3 is not compatible with pytz 
2008c due to an unexpected change in pytz. The following fix works (I 
chucked it into __init__.py near the beginning).

# the following fix for compatibility with pytz 1.4.1 is from
# <http://www.mail-archive.com/pythonmac-sig-+ZN9ApsXKcEdnm+yROfE0A <at> public.gmane.org/msg07816.html>
import pytz
try:
    import pytz.zoneinfo
except ImportError:
    pytz.zoneinfo = pytz.tzinfo
    pytz.zoneinfo.UTC = pytz.UTC

(Continue reading)


Gmane