Roundup Robot added the comment:
New changeset 14d1018940cb by Serhiy Storchaka in branch '2.7':
Issue #5633: Fixed timeit when the statement is a string and the setup is not.
https://hg.python.org/cpython/rev/14d1018940cb
New changeset 89de73c0d848 by Serhiy Storchaka in branch '3.4':
Issue
Changes by Serhiy Storchaka storch...@gmail.com:
--
resolution: - fixed
stage: patch review - resolved
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5633
___
Changes by Serhiy Storchaka storch...@gmail.com:
--
assignee: - serhiy.storchaka
versions: +Python 3.6
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5633
___
Serhiy Storchaka added the comment:
Definitely there is a bug. The code of timeit is written to support string stmt
and callable setup. Expected that locals available when the function is
created, would be available when the function is executed. But this doesn't
work. May be it worked in the
Changes by Serhiy Storchaka storch...@gmail.com:
Added file: http://bugs.python.org/file39358/timeit_callable_setup.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5633
___
Serhiy Storchaka added the comment:
Here is more complicated patch, that not only fixes handling of callable setup,
but also simplifies the implementation of timeit constructor.
--
Added file:
http://bugs.python.org/file39360/timeit_callable_setup_refactor.patch
Changes by Georg Brandl ge...@python.org:
--
assignee: georg.brandl -
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5633
___
___
Python-bugs-list
Changes by Tshepang Lekhonkhobe tshep...@gmail.com:
--
title: fix for timeit when the statment is a string and the setup is not (and
tests) - fix for timeit when the statement is a string and the setup is not
(and tests)
___
Python tracker