Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4f0b353

Browse files
committed
Allow savefig to save SVGs on FIPS enabled systems #18192
1 parent 52761de commit 4f0b353

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/matplotlib/backends/backend_svg.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -452,7 +452,7 @@ def _make_id(self, type, content):
452452
salt = mpl.rcParams['svg.hashsalt']
453453
if salt is None:
454454
salt = str(uuid.uuid4())
455-
m = hashlib.md5()
455+
m = hashlib.sha256()
456456
m.update(salt.encode('utf8'))
457457
m.update(str(content).encode('utf8'))
458458
return '%s%s' % (type, m.hexdigest()[:10])

0 commit comments

Comments
 (0)