[Git][NTPsec/ntpsec][master] python's "sha" module was deprecated in 2.5

Matt Selsky gitlab at mg.gitlab.com
Tue Dec 11 17:25:55 UTC 2018


Matt Selsky pushed to branch master at NTPsec / ntpsec


Commits:
a79cbd58 by Matt Selsky at 2018-12-11T17:20:59Z
python's "sha" module was deprecated in 2.5

Use the hashlib module instead

- - - - -


1 changed file:

- contrib/make-leap-seconds.py


Changes:

=====================================
contrib/make-leap-seconds.py
=====================================
@@ -13,7 +13,7 @@ Defaults are start of tomorrow (UTC), and 28 days after the leap.
 from __future__ import print_function, division
 
 import datetime
-import sha
+import hashlib
 import sys
 import time
 
@@ -64,7 +64,7 @@ tai = "40"          # hardwired
 #
 #  All dates use NTP epoch of 1900-01-01
 
-sha1 = sha.new()
+sha1 = hashlib.sha1()
 print("%s %s  # %s" % (leap, tai, leap_txt))
 sha1.update(leap)
 sha1.update(tai)



View it on GitLab: https://gitlab.com/NTPsec/ntpsec/commit/a79cbd58ac6812fb78c2d27d6a588382095f8730

-- 
View it on GitLab: https://gitlab.com/NTPsec/ntpsec/commit/a79cbd58ac6812fb78c2d27d6a588382095f8730
You're receiving this email because of your account on gitlab.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ntpsec.org/pipermail/vc/attachments/20181211/244f8919/attachment-0001.html>


More information about the vc mailing list