Mercurial > hg
comparison tests/test-extension.t @ 13191:1aea66b71f4f
extensions: warn about invalid extensions when listing disabled commands
Invalid extensions in hgext/ could in some cases cause a crash when searching
for unknown commands in disabled extensions.
With this change we issue a warning if extracting commands from the extensions
fails. Traceback is available on request.
Reported on https://bugzilla.redhat.com/show_bug.cgi?id=663183 with forest.py.
author | Mads Kiilerich <mads@kiilerich.com> |
---|---|
date | Sun, 26 Dec 2010 00:43:49 +0100 |
parents | 4fee1fd3de9a |
children | 1f9e11f65cd7 |
comparison
equal
deleted
inserted
replaced
13190:5314cbb775f6 | 13191:1aea66b71f4f |
---|---|
313 $ hg --config extensions.path=./path.py help broken | 313 $ hg --config extensions.path=./path.py help broken |
314 broken extension - (no help text available) | 314 broken extension - (no help text available) |
315 | 315 |
316 use "hg help extensions" for information on enabling extensions | 316 use "hg help extensions" for information on enabling extensions |
317 | 317 |
318 $ cat > hgext/forest.py <<EOF | |
319 > cmdtable = None | |
320 > EOF | |
318 $ hg --config extensions.path=./path.py help foo > /dev/null | 321 $ hg --config extensions.path=./path.py help foo > /dev/null |
322 warning: error finding commands in $TESTTMP/hgext/forest.py | |
319 hg: unknown command 'foo' | 323 hg: unknown command 'foo' |
324 warning: error finding commands in $TESTTMP/hgext/forest.py | |
320 [255] | 325 [255] |