Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #73242 > unrolled thread
| Started by | Mark Lawrence <breamoreboy@yahoo.co.uk> |
|---|---|
| First post | 2014-06-13 00:35 +0100 |
| Last post | 2014-06-13 09:48 +0100 |
| Articles | 4 — 3 participants |
Back to article view | Back to comp.lang.python
http://bugs.python.org/issue19495 timeit enhancement Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-06-13 00:35 +0100
Re: http://bugs.python.org/issue19495 timeit enhancement Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2014-06-13 00:44 +0000
Re: http://bugs.python.org/issue19495 timeit enhancement Cameron Simpson <cs@zip.com.au> - 2014-06-13 12:14 +1000
Re: http://bugs.python.org/issue19495 timeit enhancement Mark Lawrence <breamoreboy@yahoo.co.uk> - 2014-06-13 09:48 +0100
| From | Mark Lawrence <breamoreboy@yahoo.co.uk> |
|---|---|
| Date | 2014-06-13 00:35 +0100 |
| Subject | http://bugs.python.org/issue19495 timeit enhancement |
| Message-ID | <mailman.11046.1402616146.18130.python-list@python.org> |
The request is for a class within timeit that allows you to test code inside a with block. It strikes me as being useful but there's only one response on the issue, albeit a positive one. If others here think this would be a useful addition I'll see if I can take this forward, unless there are any timeit fans lurking who'd like to run with it themselves. -- My fellow Pythonistas, ask not what our language can do for you, ask what you can do for our language. Mark Lawrence --- This email is free from viruses and malware because avast! Antivirus protection is active. http://www.avast.com
[toc] | [next] | [standalone]
| From | Steven D'Aprano <steve+comp.lang.python@pearwood.info> |
|---|---|
| Date | 2014-06-13 00:44 +0000 |
| Message-ID | <539a4967$0$29988$c3e8da3$5496439d@news.astraweb.com> |
| In reply to | #73242 |
On Fri, 13 Jun 2014 00:35:43 +0100, Mark Lawrence wrote: > The request is for a class within timeit that allows you to test code > inside a with block. It strikes me as being useful but there's only one > response on the issue, albeit a positive one. If others here think this > would be a useful addition I'll see if I can take this forward, unless > there are any timeit fans lurking who'd like to run with it themselves. I have a Stopwatch() context manager which I have been using for a long time, very successfully. There's an early version here: http://code.activestate.com/recipes/577896 I'll clean it up and submit it on the bug tracker. -- Steven D'Aprano http://import-that.dreamwidth.org/
[toc] | [prev] | [next] | [standalone]
| From | Cameron Simpson <cs@zip.com.au> |
|---|---|
| Date | 2014-06-13 12:14 +1000 |
| Message-ID | <mailman.11048.1402627515.18130.python-list@python.org> |
| In reply to | #73246 |
On 13Jun2014 00:44, Steven D'Aprano <steve+comp.lang.python@pearwood.info> wrote: >On Fri, 13 Jun 2014 00:35:43 +0100, Mark Lawrence wrote: >> The request is for a class within timeit that allows you to test code >> inside a with block. It strikes me as being useful but there's only one >> response on the issue, albeit a positive one. If others here think this >> would be a useful addition I'll see if I can take this forward, unless >> there are any timeit fans lurking who'd like to run with it themselves. > >I have a Stopwatch() context manager which I have been using for a long >time, very successfully. There's an early version here: > >http://code.activestate.com/recipes/577896 > >I'll clean it up and submit it on the bug tracker. And I have a LogTimer context manager that emits a log message when a with suite exceeds a threshold. I'm sure it is far cruder and limited than Steven's; I'm mentioning it in support of the use case. Cheers, Cameron Simpson <cs@zip.com.au> 1993 Explorer - Cage? Hell, it's a prison. - Will Hartung vfr750@netcom.com
[toc] | [prev] | [next] | [standalone]
| From | Mark Lawrence <breamoreboy@yahoo.co.uk> |
|---|---|
| Date | 2014-06-13 09:48 +0100 |
| Message-ID | <mailman.11052.1402649332.18130.python-list@python.org> |
| In reply to | #73246 |
On 13/06/2014 01:44, Steven D'Aprano wrote: > On Fri, 13 Jun 2014 00:35:43 +0100, Mark Lawrence wrote: > >> The request is for a class within timeit that allows you to test code >> inside a with block. It strikes me as being useful but there's only one >> response on the issue, albeit a positive one. If others here think this >> would be a useful addition I'll see if I can take this forward, unless >> there are any timeit fans lurking who'd like to run with it themselves. > > I have a Stopwatch() context manager which I have been using for a long > time, very successfully. There's an early version here: > > http://code.activestate.com/recipes/577896 > > I'll clean it up and submit it on the bug tracker. > I see it's there, thanks Steven :) -- My fellow Pythonistas, ask not what our language can do for you, ask what you can do for our language. Mark Lawrence --- This email is free from viruses and malware because avast! Antivirus protection is active. http://www.avast.com
[toc] | [prev] | [standalone]
Back to top | Article view | comp.lang.python
csiph-web