Bug 1712819: Fix VirtualenvManager not being expandable in debugger r=ahal

At least in PyCharm, expanding a `VirtualenvManager` instance means
resolving all the properties and fields of the instance.
However, if that property is doing non-trivial work, the debugger
wouldn't run that subprocess while we're stopped at a breakpoint.
So, the instance would sit there with the "Collecting data..." text.

Differential Revision: https://phabricator.services.mozilla.com/D115935
This commit is contained in:
Mitchell Hentges
2021-05-27 23:04:06 +00:00
parent 538a14a56a
commit c34c3a1b61
2 changed files with 1 additions and 2 deletions

View File

@@ -222,7 +222,7 @@ class MachCommands(MachCommandBase):
tests = mp.active_tests( tests = mp.active_tests(
filters=filters, filters=filters,
disabled=False, disabled=False,
python=self.virtualenv_manager.version_info[0], python=self.virtualenv_manager.version_info()[0],
**mozinfo.info **mozinfo.info
) )

View File

@@ -135,7 +135,6 @@ class VirtualenvManager(VirtualenvHelper):
self.topsrcdir, "third_party", "python", "virtualenv", "virtualenv.py" self.topsrcdir, "third_party", "python", "virtualenv", "virtualenv.py"
) )
@property
def version_info(self): def version_info(self):
return eval( return eval(
subprocess.check_output( subprocess.check_output(