[Git][NTPsec/ntpsec][master] Fix ntploggps for newer versions of gps module

Gary E. Miller gitlab at mg.gitlab.com
Mon Dec 17 23:43:21 UTC 2018


Gary E. Miller pushed to branch master at NTPsec / ntpsec


Commits:
87ffc14e by Richard Laager at 2018-12-17T23:13:39Z
Fix ntploggps for newer versions of gps module

Current versions of the gps module have no isnan() function.  This has
been removed in favor of isfinite().

Note that this change breaks ntploggps on older versions of the gps
module.

- - - - -


1 changed file:

- ntpclients/ntploggps.py


Changes:

=====================================
ntpclients/ntploggps.py
=====================================
@@ -171,7 +171,7 @@ class GpsPoller(threading.Thread):
         if isinstance(t, int):
             return t
         if isinstance(t, float):
-            if gps.isnan(t):
+            if not gps.isfinite(t):
                 return None
             return t
         return gps.isotime(t)



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

-- 
View it on GitLab: https://gitlab.com/NTPsec/ntpsec/commit/87ffc14e39bad36fe59f24e93bb172915f2b5e0b
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/20181217/a2c3535c/attachment.html>


More information about the vc mailing list