Re: [PATCH next 2/2] Remove python 2.5'isms
- From
Sverre Rabbelier <srabbelier@gmail.com>
- Date
- Jun 9, 2010, 22:46 UTC
- Message-ID
- <AANLkTilCVoLJQaGroSFWx46KclPj_PBfNYH6-ghoY0N_@mail.gmail.com>
- In-Reply-To
- <201006100040.54375.johan@herland.net>
Heya,
On Thu, Jun 10, 2010 at 00:40, Johan Herland <johan@herland.net> wrote:
Show 9 quoted lines
> # hashlib is only available in python >= 2.5 > try: > import hashlib > _digest = hashlib.sha1 > except ImportError: > import sha > _digest = sha.sha > > so that we don't get the hideous DeprecationWarning.
This is exactly what I meant to suggest earlier, but I didn't know the appropriate routine in python 2.4, thanks Johan.
-- Cheers, Sverre Rabbelier