On Wed, Mar 14, 2012 at 10:16, Antoine Pitrou <solip...@pitrou.net> wrote: > That's a rather awful name. time.time() is *the* real time. > > time.monotonic(fallback=False) would be a better API.
I think calling the function "monotonic" isn't really a good name if it's not always monotonic. time.monotonic(fallback=False) Really just means time.monotonic(monotonic=False) And time.monotonic(strict=True) Really means time.monotonic(i_really_mean_it=True) This is potentially confusing. Therefore time.clock() time.time() time.realtime() time.wallclock() Are all better options if there is a flag to switch if it's monotonic or not. Since time.clock() apparently can mean different things on different platforms because of it's use of the C-API, we can't use that. I'm not sure why time.time() would differ from time.realtime(). time.time() is per definition not monotonic, but time.time(monotonic=True) is maybe a possibility? //Lennart //Lennart _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com