Re: [Python-Dev] [RFC] PEP 418: Add monotonic time, performance counter and process time functions

2012-04-29 Thread Larry Hastings
On 04/28/2012 04:20 PM, Eric V. Smith wrote: But we generally use a namedtuple (or structseq) for things like get_clock_info. For example, for sys.float_info there's no need for it to be a tuple, and it can be extended in the future, yet it's a structseq. I'd prefer an object to a dict, but

Re: [Python-Dev] [RFC] PEP 418: Add monotonic time, performance counter and process time functions

2012-04-29 Thread Eric V. Smith
On 4/29/2012 4:41 AM, Larry Hastings wrote: On 04/28/2012 04:20 PM, Eric V. Smith wrote: But we generally use a namedtuple (or structseq) for things like get_clock_info. For example, for sys.float_info there's no need for it to be a tuple, and it can be extended in the future, yet it's a

Re: [Python-Dev] [RFC] PEP 418: Add monotonic time, performance counter and process time functions

2012-04-29 Thread Larry Hastings
On 04/29/2012 02:01 AM, Eric V. Smith wrote: On 4/29/2012 4:41 AM, Larry Hastings wrote: I'd prefer an object to a dict, but not a tuple / structseq. There's no need for the members to be iterable. I agree with you, but there's already plenty of precedent for this. [...] Iteration for these

Re: [Python-Dev] package imports, sys.path and os.chdir()

2012-04-29 Thread Christian Tismer
On 28.04.12 21:16, Brett Cannon wrote: On Sat, Apr 28, 2012 at 04:08, Nick Coghlan ncogh...@gmail.com mailto:ncogh...@gmail.com wrote: On Sat, Apr 28, 2012 at 6:00 AM, Brett Cannon br...@python.org mailto:br...@python.org wrote: I'm personally in favour of changing the

Re: [Python-Dev] [RFC] PEP 418: Add monotonic time, performance counter and process time functions

2012-04-29 Thread Antoine Pitrou
On Sun, 29 Apr 2012 02:12:41 -0700 Larry Hastings la...@hastings.org wrote: On 04/29/2012 02:01 AM, Eric V. Smith wrote: On 4/29/2012 4:41 AM, Larry Hastings wrote: I'd prefer an object to a dict, but not a tuple / structseq. There's no need for the members to be iterable. I agree with

Re: [Python-Dev] [RFC] PEP 418: Add monotonic time, performance counter and process time functions

2012-04-29 Thread Antoine Pitrou
On Sun, 29 Apr 2012 03:26:26 +0200 Victor Stinner victor.stin...@gmail.com wrote: Hi Guido, 2012/4/28 Guido van Rossum gu...@python.org: I read most of the PEP and I think it is ready for acceptance! Thanks for your patience in shepherding this through such a difficult and long

Re: [Python-Dev] package imports, sys.path and os.chdir()

2012-04-29 Thread Christian Tismer
On 29.04.12 07:05, Nick Coghlan wrote: On Sun, Apr 29, 2012 at 1:41 PM, PJ Ebyp...@telecommunity.com wrote: That's already the case. Actually, sys.path[0] is *always* the absolute path of the script directory -- regardless of whether you invoked the script by a relative path or an absolute

Re: [Python-Dev] [RFC] PEP 418: Add monotonic time, performance counter and process time functions

2012-04-29 Thread Guido van Rossum
On Sun, Apr 29, 2012 at 5:29 AM, Steven D'Aprano st...@pearwood.info wrote: Larry Hastings wrote: On 04/29/2012 02:01 AM, Eric V. Smith wrote: On 4/29/2012 4:41 AM, Larry Hastings wrote: I'd prefer an object to a dict, but not a tuple / structseq.  There's no need for the members to be

Re: [Python-Dev] [RFC] PEP 418: Add monotonic time, performance counter and process time functions

2012-04-29 Thread Guido van Rossum
On Sat, Apr 28, 2012 at 6:26 PM, Victor Stinner victor.stin...@gmail.com wrote: Hi Guido, 2012/4/28 Guido van Rossum gu...@python.org: I read most of the PEP and I think it is ready for acceptance! Thanks for your patience in shepherding this through such a difficult and long discussion.

Re: [Python-Dev] [RFC] PEP 418: Add monotonic time, performance counter and process time functions

2012-04-29 Thread Guido van Rossum
On Sat, Apr 28, 2012 at 1:32 PM, Victor Stinner victor.stin...@gmail.com wrote: As a thin wrapper, adding it to the time module was pretty much uncontroversial, I think. The PEP proposes cross-platform functions with consistent semantics, which is where a discussion was needed. True, but

[Python-Dev] time.clock_info() field names

2012-04-29 Thread Benjamin Peterson
Hi, I see PEP 418 gives time.clock_info() two boolean fields named is_monotonic and is_adjusted. I think the is_ is unnecessary and a bit ugly, and they could just be renamed monotonic and adjusted. Thoughts? -- Regards, Benjamin ___ Python-Dev

Re: [Python-Dev] time.clock_info() field names

2012-04-29 Thread Antoine Pitrou
On Sun, 29 Apr 2012 19:25:16 -0400 Benjamin Peterson benja...@python.org wrote: Hi, I see PEP 418 gives time.clock_info() two boolean fields named is_monotonic and is_adjusted. I think the is_ is unnecessary and a bit ugly, and they could just be renamed monotonic and adjusted. Thoughts?

[Python-Dev] time.clock_info() field names

2012-04-29 Thread Jim J. Jewett
In http://mail.python.org/pipermail/python-dev/2012-April/119134.html Benjamin Peterson wrote: I see PEP 418 gives time.clock_info() two boolean fields named is_monotonic and is_adjusted. I think the is_ is unnecessary and a bit ugly, and they could just be renamed monotonic and adjusted. I

Re: [Python-Dev] time.clock_info() field names

2012-04-29 Thread Benjamin Peterson
2012/4/29 Jim J. Jewett jimjjew...@gmail.com: In http://mail.python.org/pipermail/python-dev/2012-April/119134.html Benjamin Peterson wrote: I see PEP 418 gives time.clock_info() two boolean fields named is_monotonic and is_adjusted. I think the is_ is unnecessary and a bit ugly, and they