Mercurial > public > mercurial-scm > hg-stable
diff hgext/phabricator.py @ 45272:b1f2659c1c34
phabricator: unconditionally pop `test_vcr` to fix debugcallconduit
11592ce6a711 / D8525 accidentally broke debugcallconduit in non-test scenarios
because it stopped popping `test_vcr` from `kwargs` unconditionally, so when
`--test-vcr` isn't set the empty string still gets passed down as the value of
`test_vcr` in `kwargs`. However unlike all the other commands debugcallconduit
doesn't have an `**opts` argument to receive it, so it aborts because of
invalid arguments.
Differential Revision: https://phab.mercurial-scm.org/D8852
author | Ian Moody <moz-ian@perix.co.uk> |
---|---|
date | Thu, 30 Jul 2020 16:58:38 +0100 |
parents | b3b0cd8b9366 |
children | 1a5d3e555c70 |
line wrap: on
line diff
--- a/hgext/phabricator.py Thu Jul 30 16:52:12 2020 +0100 +++ b/hgext/phabricator.py Thu Jul 30 16:58:38 2020 +0100 @@ -238,8 +238,9 @@ def decorate(fn): def inner(*args, **kwargs): - if kwargs.get('test_vcr'): - cassette = pycompat.fsdecode(kwargs.pop('test_vcr')) + vcr = kwargs.pop('test_vcr') + if vcr: + cassette = pycompat.fsdecode(vcr) import hgdemandimport with hgdemandimport.deactivated():