Re: [Python-Dev] this is why we shouldn't call it a monotonic clock (was: PEP 418 is too divisive and confusing and should be postponed)

2012-04-07 Thread Stephen J. Turnbull
On Fri, Apr 6, 2012 at 11:32 PM, Victor Stinner victor.stin...@gmail.com wrote: On Linux, I now prefer to use CLOCK_MONOTONIC (monotonic) than CLOCK_MONOTONIC_RAW (monotonic and steady as defined by C++) *because* its frequency is adjusted. I don't think that's a reason that should be

Re: [Python-Dev] cpython: Issue #3033: Add displayof parameter to tkinter font.

2012-04-07 Thread Senthil Kumaran
Hi Andrew, On Thu, Apr 05, 2012 at 11:16:54PM +0300, Andrew Svetlov wrote: I tried to: andrew@tiktaalik2 ~/projects hg clone ssh://h...@hg.python.org/cpython ssh://h...@hg.python.org/sandbox/tkdocs repo created, public URL is http://hg.python.org/sandbox/tkdocs abort: clone from remote to

Re: [Python-Dev] Pep 393 and debugging

2012-04-07 Thread Martin v. Löwis
I wonder if there is a way to make this situation easier? Perhaps for debug builds, we can store some debug information in the frame object, e.g. utf8 encoding of the filename and function? I'd like to stress Benjamin's recommendation. Dave Malcolm's gdb extensions (requires gdb with Python

Re: [Python-Dev] this is why we shouldn't call it a monotonic clock (was: PEP 418 is too divisive and confusing and should be postponed)

2012-04-07 Thread Stephen J. Turnbull
On Sat, Apr 7, 2012 at 8:47 AM, Victor Stinner victor.stin...@gmail.com wrote: Objects of class steady_clock represent clocks for which values of time_point advance at a steady rate relative to real time. That is, the clock may not be adjusted.

Re: [Python-Dev] PEP 418 is too divisive and confusing and should be postponed

2012-04-07 Thread Victor Stinner
2012/4/7 Janzert janz...@janzert.com: On 4/5/2012 6:32 AM, Victor Stinner wrote: I prefer to use CLOCK_MONOTONIC, not because it is also available for older Linux kernels, but because it is more reliable. Even if the underlying clock source is unstable (unstable frequency), a delta of two

Re: [Python-Dev] this is why we shouldn't call it a monotonic clock (was: PEP 418 is too divisive and confusing and should be postponed)

2012-04-07 Thread Paul Moore
On 7 April 2012 09:12, Stephen J. Turnbull step...@xemacs.org wrote: I don't think that's a reason that should be considered.  There just doesn't seem to be a single best clock, nor do clocks of similar character seem to be easy to find across platforms.  So the reasons I'd like to see are of

Re: [Python-Dev] PEP 418 is too divisive and confusing and should be postponed

2012-04-07 Thread Steven D'Aprano
Victor Stinner wrote: 2012/4/7 Janzert janz...@janzert.com: On 4/5/2012 6:32 AM, Victor Stinner wrote: I prefer to use CLOCK_MONOTONIC, not because it is also available for older Linux kernels, but because it is more reliable. Even if the underlying clock source is unstable (unstable

Re: [Python-Dev] cpython: Issue #3033: Add displayof parameter to tkinter font.

2012-04-07 Thread Andrew Svetlov
Thank you. That works. Is there way to delete unused repo? On Sat, Apr 7, 2012 at 11:20 AM, Senthil Kumaran sent...@uthcode.com wrote: Hi Andrew, On Thu, Apr 05, 2012 at 11:16:54PM +0300, Andrew Svetlov wrote: I tried to: andrew@tiktaalik2 ~/projects hg clone ssh://h...@hg.python.org/cpython

Re: [Python-Dev] cpython: Issue #3033: Add displayof parameter to tkinter font.

2012-04-07 Thread R. David Murray
On Sat, 07 Apr 2012 15:15:00 +0300, Andrew Svetlov andrew.svet...@gmail.com wrote: Thank you. That works. Is there way to delete unused repo? This is what I've heard: If a repo isn't used (at all) it eventually gets deleted automatically. Otherwise, you have to ask. Probably python-committers

Re: [Python-Dev] cpython: Issue #3033: Add displayof parameter to tkinter font.

2012-04-07 Thread Serhiy Storchaka
Andrew, when you prepare the tkinter documentation, I advise you to include a link to www.tkdocs.com -- probably the best resource in this way (at least it was very useful for me). Maybe even should offer these guys do official documentation, if they agree and if there would be no conflict of

Re: [Python-Dev] cpython: Issue #3033: Add displayof parameter to tkinter font.

2012-04-07 Thread Andrew Svetlov
On Sat, Apr 7, 2012 at 5:06 PM, Serhiy Storchaka storch...@gmail.com wrote: Andrew, when you prepare the tkinter documentation, I advise you to include a link to www.tkdocs.com -- probably the best resource in this way (at least it was very useful for me). Done in sanbox/tkdoc repo. --

Re: [Python-Dev] PEP 418 is too divisive and confusing and should be postponed

2012-04-07 Thread Victor Stinner
2012/4/7 Steven D'Aprano st...@pearwood.info: Victor Stinner wrote: 2012/4/7 Janzert janz...@janzert.com: On 4/5/2012 6:32 AM, Victor Stinner wrote: I prefer to use CLOCK_MONOTONIC, not because it is also available for older Linux kernels, but because it is more reliable. Even if the

Re: [Python-Dev] PEP 418 is too divisive and confusing and should be postponed

2012-04-07 Thread Cameron Simpson
On 07Apr2012 20:40, Steven D'Aprano st...@pearwood.info wrote: | Victor Stinner wrote: | I don't think that NTP works like that. NTP only uses very smooth adjustements: [...] | http://www.python.org/dev/peps/pep-0418/#ntp-adjustment | | That is incorrect. NTP by default will only slew the

Re: [Python-Dev] this is why we shouldn't call it a monotonic clock (was: PEP 418 is too divisive and confusing and should be postponed)

2012-04-07 Thread Cameron Simpson
On 07Apr2012 01:47, Victor Stinner victor.stin...@gmail.com wrote: | I don't understand this definition. All clocks have a clock drift. | This is just one exception: atomic clocks, but such clocks are rare | and very expensive. They've got drift too. It is generally very small. Anecdote: I used

Re: [Python-Dev] this is why we shouldn't call it a monotonic clock (was: PEP 418 is too divisive and confusing and should be postponed)

2012-04-07 Thread Raymond Hettinger
On Apr 7, 2012, at 3:08 AM, Paul Moore wrote: Use cases: Display the current time to a human (e.g. display a calendar or draw a wall clock): use system clock, i.e. time.time() or datetime.datetime.now(). Event scheduler, timeout: time.monotonic(). Benchmark, profiling: time.clock() on

Re: [Python-Dev] PEP 418 is too divisive and confusing and should be postponed

2012-04-07 Thread Glyph Lefkowitz
On Apr 7, 2012, at 3:40 AM, Steven D'Aprano wrote: In any case, NTP is not the only thing that adjusts the clock, e.g. the operating system will adjust the time for daylight savings. Daylight savings time is not a clock adjustment, at least not in the sense this thread has mostly been

Re: [Python-Dev] Pep 393 and debugging

2012-04-07 Thread Kristján Valur Jónsson
Thanks, _PyObject_Dump sounds like just the ticket. Most of the time, the VS2010 debugger can just run functions willie nillie and thing should simply work. Frá: Martin v. Löwis [mar...@v.loewis.de] Sent: 7. apríl 2012 09:08 To: Kristján Valur Jónsson

Re: [Python-Dev] this is why we shouldn't call it a monotonic clock (was: PEP 418 is too divisive and confusing and should be postponed)

2012-04-07 Thread Kristján Valur Jónsson
Thank you for your veto. Still, again for the sake of keeping track of things and such, there is this: http://en.wikipedia.org/wiki/Wall_clock_time and also my original suggestion: http://bugs.python.org/issue10278 In the end, the world shall be ruled by the nomenclaturists. K

Re: [Python-Dev] this is why we shouldn't call it a monotonic clock (was: PEP 418 is too divisive and confusing and should be postponed)

2012-04-07 Thread Raymond Hettinger
Just to clarify my previous post. It seems clear that benchmarking and timeout logic would benefit from a clock that cannot be adjusted by NTP. I'm unclear on whether time.sleep() will be based on the same clock so that timeouts and sleeps are on the same basis. For scheduling logic (such as

Re: [Python-Dev] this is why we shouldn't call it a monotonic clock (was: PEP 418 is too divisive and confusing and should be postponed)

2012-04-07 Thread Cameron Simpson
Victor et al, Just an update note: I've started marking up clocks with attributes; not yet complete and I still need to make a small C extension to present the system clocks to Python space (which means learning to do that, too). But you can glance over the start on it here:

Re: [Python-Dev] this is why we shouldn't call it a monotonic clock (was: PEP 418 is too divisive and confusing and should be postponed)

2012-04-07 Thread Guido van Rossum
On Sat, Apr 7, 2012 at 6:26 PM, Raymond Hettinger raymond.hettin...@gmail.com wrote: Just to clarify my previous post. It seems clear that benchmarking and timeout logic would benefit from a clock that cannot be adjusted by NTP. I'm unclear on whether time.sleep() will be based on the same

Re: [Python-Dev] this is why we shouldn't call it a monotonic clock (was: PEP 418 is too divisive and confusing and should be postponed)

2012-04-07 Thread Cameron Simpson
On 07Apr2012 18:49, Guido van Rossum gu...@python.org wrote: | On Sat, Apr 7, 2012 at 6:26 PM, Raymond Hettinger | raymond.hettin...@gmail.com wrote: | Just to clarify my previous post. | It seems clear that benchmarking and timeout logic would benefit | from a clock that cannot be adjusted by