Mercurial > hg
comparison tests/test-devel-warnings.t @ 29784:e3501546f7e4
profiling: add a context manager that no-ops if profiling isn't enabled
And refactor dispatch.py to use it. As you can see, the resulting code
is much simpler.
I was tempted to inline _runcommand as part of writing this series.
However, a number of extensions wrap _runcommand. So keeping it around
is necessary (extensions can't easily wrap runcommand because it calls
hooks before and after command execution).
author | Gregory Szorc <gregory.szorc@gmail.com> |
---|---|
date | Sun, 14 Aug 2016 17:51:12 -0700 |
parents | 39149b6036e6 |
children | 4338f87dbf6f |
comparison
equal
deleted
inserted
replaced
29783:5d44197c208b | 29784:e3501546f7e4 |
---|---|
94 */mercurial/dispatch.py:* in callcatch (glob) | 94 */mercurial/dispatch.py:* in callcatch (glob) |
95 */mercurial/dispatch.py:* in _runcatchfunc (glob) | 95 */mercurial/dispatch.py:* in _runcatchfunc (glob) |
96 */mercurial/dispatch.py:* in _dispatch (glob) | 96 */mercurial/dispatch.py:* in _dispatch (glob) |
97 */mercurial/dispatch.py:* in runcommand (glob) | 97 */mercurial/dispatch.py:* in runcommand (glob) |
98 */mercurial/dispatch.py:* in _runcommand (glob) | 98 */mercurial/dispatch.py:* in _runcommand (glob) |
99 */mercurial/dispatch.py:* in checkargs (glob) | |
100 */mercurial/dispatch.py:* in <lambda> (glob) | 99 */mercurial/dispatch.py:* in <lambda> (glob) |
101 */mercurial/util.py:* in check (glob) | 100 */mercurial/util.py:* in check (glob) |
102 $TESTTMP/buggylocking.py:* in buggylocking (glob) | 101 $TESTTMP/buggylocking.py:* in buggylocking (glob) |
103 $ hg properlocking | 102 $ hg properlocking |
104 $ hg nowaitlocking | 103 $ hg nowaitlocking |
130 */mercurial/dispatch.py:* in callcatch (glob) | 129 */mercurial/dispatch.py:* in callcatch (glob) |
131 */mercurial/dispatch.py:* in _runcatchfunc (glob) | 130 */mercurial/dispatch.py:* in _runcatchfunc (glob) |
132 */mercurial/dispatch.py:* in _dispatch (glob) | 131 */mercurial/dispatch.py:* in _dispatch (glob) |
133 */mercurial/dispatch.py:* in runcommand (glob) | 132 */mercurial/dispatch.py:* in runcommand (glob) |
134 */mercurial/dispatch.py:* in _runcommand (glob) | 133 */mercurial/dispatch.py:* in _runcommand (glob) |
135 */mercurial/dispatch.py:* in checkargs (glob) | |
136 */mercurial/dispatch.py:* in <lambda> (glob) | 134 */mercurial/dispatch.py:* in <lambda> (glob) |
137 */mercurial/util.py:* in check (glob) | 135 */mercurial/util.py:* in check (glob) |
138 $TESTTMP/buggylocking.py:* in oldanddeprecated (glob) | 136 $TESTTMP/buggylocking.py:* in oldanddeprecated (glob) |
139 $ hg blackbox -l 9 | 137 $ hg blackbox -l 9 |
140 1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> devel-warn: revset "oldstyle" uses list instead of smartset | 138 1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> devel-warn: revset "oldstyle" uses list instead of smartset |
154 */mercurial/dispatch.py:* in callcatch (glob) | 152 */mercurial/dispatch.py:* in callcatch (glob) |
155 */mercurial/dispatch.py:* in _runcatchfunc (glob) | 153 */mercurial/dispatch.py:* in _runcatchfunc (glob) |
156 */mercurial/dispatch.py:* in _dispatch (glob) | 154 */mercurial/dispatch.py:* in _dispatch (glob) |
157 */mercurial/dispatch.py:* in runcommand (glob) | 155 */mercurial/dispatch.py:* in runcommand (glob) |
158 */mercurial/dispatch.py:* in _runcommand (glob) | 156 */mercurial/dispatch.py:* in _runcommand (glob) |
159 */mercurial/dispatch.py:* in checkargs (glob) | |
160 */mercurial/dispatch.py:* in <lambda> (glob) | 157 */mercurial/dispatch.py:* in <lambda> (glob) |
161 */mercurial/util.py:* in check (glob) | 158 */mercurial/util.py:* in check (glob) |
162 $TESTTMP/buggylocking.py:* in oldanddeprecated (glob) | 159 $TESTTMP/buggylocking.py:* in oldanddeprecated (glob) |
163 1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> oldanddeprecated --traceback exited 0 after * seconds (glob) | 160 1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> oldanddeprecated --traceback exited 0 after * seconds (glob) |
164 1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> blackbox -l 9 | 161 1970/01/01 00:00:00 bob @cb9a9f314b8b07ba71012fcdbc544b5a4d82ff5b (5000)> blackbox -l 9 |