Deprecation Warning time.clock()

Bug #1830738 reported by claudio on 2019-05-28
This bug affects 4 people
Affects Status Importance Assigned to Milestone

Bug Description

There is a call to time.clock in Crypto/Random/
it causes the following warning, in the future may become a problem:
DeprecationWarning: time.clock has been deprecated in Python 3.3 and will be removed from Python 3.8: use time.perf_counter or time.process_time instead
  t = time.clock()

Al Smith (ajs1k) wrote :

This is now busted as time.clock() has been removed from python3.8.

s/time.clock/time.process_time/ and all is good again.

Al Smith (ajs1k) wrote :

Or perhaps this:

if 'process_time' in dir(time):
    t = time.process_time()
    t = time.clock()

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers