Modify ↓
Opened 14 years ago
Closed 14 years ago
#7836 closed defect (fixed)
SHA module deprecated warning fix
Reported by: | anonymous | Owned by: | Kamil Kisiel |
---|---|---|---|
Priority: | normal | Component: | TracMathPlugin |
Severity: | normal | Keywords: | |
Cc: | Trac Release: | 0.12 |
Description
Hi,
Enclosed you will find a fix for the SHA deprecated warning.
--- tracmath.py (revision 248) +++ tracmath.py (revision 249) @@ -5,7 +5,7 @@ import codecs import re -import sha +import hashlib from cStringIO import StringIO import os import sys @@ -142,7 +142,7 @@ if m: label = m.group(1) - key = sha.new(content.encode('utf-8')).hexdigest() + key = hashlib.sha1(content.encode('utf-8')).hexdigest() imgname = key + '.png' imgpath = os.path.join(self.cacheDirectory, imgname)
regards
Mario
Attachments (0)
Change History (2)
comment:1 Changed 14 years ago by
Owner: | changed from rlotun to Kamil Kisiel |
---|---|
Status: | new → assigned |
comment:2 Changed 14 years ago by
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Note: See
TracTickets for help on using
tickets.
This is fixed in the 0.3 release.