summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_trace.py
Commit message (Collapse)AuthorAgeFilesLines
* #11565: Fix several typos. Patch by Piotr Kasprzyk.Ezio Melotti2011-03-161-1/+1
|
* Merged revisions 86596 via svnmerge fromEzio Melotti2010-11-211-1/+1
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r86596 | ezio.melotti | 2010-11-20 21:04:17 +0200 (Sat, 20 Nov 2010) | 1 line #9424: Replace deprecated assert* methods in the Python test suite. ........
* Merged revisions 85000 via svnmerge fromAlexander Belopolsky2010-09-261-0/+2
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r85000 | alexander.belopolsky | 2010-09-24 18:04:22 -0400 (Fri, 24 Sep 2010) | 1 line This should fix buildbot failure introduced by r84994 ........
* Merged revisions 84994 via svnmerge fromAlexander Belopolsky2010-09-241-3/+22
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r84994 | alexander.belopolsky | 2010-09-24 14:03:12 -0400 (Fri, 24 Sep 2010) | 1 line Issue #9936: Fixed executable lines' search in the trace module. ........
* Removed debugging settingAlexander Belopolsky2010-09-131-1/+1
|
* Issue #9315: Fix for the trace module to record correct class nameAlexander Belopolsky2010-09-131-0/+320
| | | | when tracing methods. Unit tests. Patch by Eli Bendersky.
* Redo r83142 merge manually. QOTD: svnmerge isn't really your best friendAlexander Belopolsky2010-07-281-214/+0
|
* Reverted r83142: add Lib/test/test_trace.py backAlexander Belopolsky2010-07-281-0/+214
|
* Merged revisions 83140-83141 via svnmerge fromAlexander Belopolsky2010-07-251-789/+0
| | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/branches/py3k ........ r83140 | alexander.belopolsky | 2010-07-25 11:02:55 -0400 (Sun, 25 Jul 2010) | 5 lines Issue #9315: Renamed test_trace to test_sys_settrace and test_profilehooks to test_sys_setprofile so that test_trace can be used for testing the trace module and for naming consistency. ........ r83141 | alexander.belopolsky | 2010-07-25 11:05:42 -0400 (Sun, 25 Jul 2010) | 1 line Corrected comments on where settrace and setprofile are tested. ........
* #7092: Silence more py3k warnings. Patch by Florent Xicluna.Ezio Melotti2010-02-031-1/+1
|
* Reverting the Revision: 77368. I committed Flox's big patch for tests bySenthil Kumaran2010-01-081-1/+1
| | | | mistake. ( It may come in for sure tough)
* Fixing - Issue7026 - RuntimeError: dictionary changed size during iteration. ↵Senthil Kumaran2010-01-081-1/+1
| | | | Patch by flox
* #4547: When debugging a very large function, it was not alwaysAmaury Forgeot d'Arc2009-06-011-0/+17
| | | | possible to update the lineno attribute of the current frame.
* Fix issue #1689458 by teaching frame_setlineno how to jump to the first line ofJeffrey Yasskin2009-05-201-0/+21
| | | | a code object.
* While I was modifying test_trace, it threw an exception when I accidentallyJeffrey Yasskin2009-05-181-1/+1
| | | | | | | made it try to set the line number from the trace callback for a 'call' event. This patch makes the error message a little more helpful in that case, and makes it a little less likely that a future editor will make the same mistake in test_trace.
* Disable gc when running test_trace, or we may record the __del__ of ↵Amaury Forgeot d'Arc2008-04-241-0/+12
| | | | | | | collected objects. See http://mail.python.org/pipermail/python-checkins/2008-April/068633.html the extra events perfectly match several calls to socket._fileobject.__del__()
* Change r60575 broke test_compile:Amaury Forgeot d'Arc2008-02-051-0/+9
| | | | there is no need to emit co_lnotab item when both offsets are zeros.
* #1750076: Debugger did not step on every iteration of a while statement.Amaury Forgeot d'Arc2008-02-041-3/+48
| | | | | | | | | | | | The mapping between bytecode offsets and source lines (lnotab) did not contain an entry for the beginning of the loop. Now it does, and the lnotab can be a bit larger: in particular, several statements on the same line generate several entries. However, this does not bother the settrace function, which will trigger only one 'line' event. The lnotab seems to be exactly the same as with python2.4.
* #1648: add sys.gettrace() and sys.getprofile().Georg Brandl2008-01-201-0/+14
|
* Merge from py3k branch:Amaury Forgeot d'Arc2007-11-131-2/+47
| | | | | | | | | | | | | | | | | | | | | | Correction for issue1265 (pdb bug with "with" statement). When an unfinished generator-iterator is garbage collected, PyEval_EvalFrameEx is called with a GeneratorExit exception set. This leads to funny results if the sys.settrace function itself makes use of generators. A visible effect is that the settrace function is reset to None. Another is that the eventual "finally" block of the generator is not called. It is necessary to save/restore the exception around the call to the trace function. This happens a lot with py3k: isinstance() of an ABCMeta instance runs def __instancecheck__(cls, instance): """Override for isinstance(instance, cls).""" return any(cls.__subclasscheck__(c) for c in {instance.__class__, type(instance)}) which lets an opened generator expression each time it returns True. Backport candidate, even if the case is less frequent in 2.5.
* Bug #1191458: tracing over for loops now produces a line eventNeal Norwitz2006-08-041-2/+2
| | | | | | | | | | | | on each iteration. I'm not positive this is the best way to handle this. I'm also not sure that there aren't other cases where the lnotab is generated incorrectly. It would be great if people that use pdb or tracing could test heavily. Also: * Remove dead/duplicated code that wasn't used/necessary because we already handled the docstring prior to entering the loop. * add some debugging code into the compiler (#if 0'd out).
* Generate line number table entries for except handlers.Jeremy Hylton2006-04-041-25/+37
| | | | Re-enable all the tests in test_trace.py except one. Still not sure that these tests test what they used to test, but they pass. One failing test seems to be caused by undocumented line number table behavior in Python 2.4.
* Disable some tests in anticipation of merging ast-branch to the headJeremy Hylton2005-10-201-16/+21
|
* Port from the Python 2.4 branch, patches for SF bug # 900092,Barry Warsaw2005-08-151-0/+1
| | | | hotshot.stats.load.
* The fix in ceval.c 2.386 allows iteration-by-iteration line tracing even inArmin Rigo2004-03-221-0/+23
| | | | single-line loops.
* Fix (really) for tight loop line eventsNicholas Bastin2004-03-221-1/+2
|
* Test for tight loop line event fix, SF bug #765624Nicholas Bastin2004-03-221-0/+25
|
* Test for lack of implicit return line eventNicholas Bastin2004-03-221-9/+27
|
* Combine the functionality of test_support.run_unittest()Walter Dörwald2003-05-011-3/+5
| | | | | | | | | | and test_support.run_classtests() into run_unittest() and use it wherever possible. Also don't use "from test.test_support import ...", but "from test import test_support" in a few spots. From SF patch #662807.
* Armin Rigo's fix & test forMichael W. Hudson2003-04-291-0/+21
| | | | | | [ 729622 ] line tracing hook errors with massaging from me to integrate test into test suite.
* This is Richie Hindle's patchMichael W. Hudson2002-12-171-0/+289
| | | | | | | | [ 643835 ] Set Next Statement for Python debuggers with a few tweaks by me: adding an unsigned or two, mentioning that not all jumps are allowed in the doc for pdb, adding a NEWS item and a note to whatsnew, and AuCTeX doing something cosmetic to libpdb.tex.
* Whitespace normalization.Tim Peters2002-11-091-9/+9
|
* This is Richie Hindle's patch:Michael W. Hudson2002-11-081-6/+31
| | | | | | | [ 631276 ] Exceptions raised by line trace function It conflicted with the patches from Armin I just checked it, so I had to so some bits by hand.
* Fix for the recursion_level bug Armin Rigo reported in sfMichael W. Hudson2002-10-021-0/+20
| | | | | | | patch #617312, both on the trunk and the 22-maint branch. Also added a test case, and ported the test_trace I wrote for HEAD to 2.2.2 (with all those horrible extra 'line' events ;-).
* A slight change to SET_LINENO-less tracing.Michael W. Hudson2002-09-111-1/+1
| | | | | This makes things a touch more like 2.2. Read the comments in Python/ceval.c for more details.
* Bunch more tests.Michael W. Hudson2002-09-111-9/+83
|
* Further SET_LINENO reomval fixes. See comments in patch #587933.Michael W. Hudson2002-08-301-0/+110
Use a slightly different strategy to determine when not to call the line trace function. This removes the need for the RETURN_NONE opcode, so that's gone again. Update docs and comments to match. Thanks to Neal and Armin! Also add a test suite. This should have come with the original patch...