diff --git a/testing/mozharness/mozharness/base/vcs/mercurial.py b/testing/mozharness/mozharness/base/vcs/mercurial.py index b3ca8f5de6db..8362cc5d7fe2 100755 --- a/testing/mozharness/mozharness/base/vcs/mercurial.py +++ b/testing/mozharness/mozharness/base/vcs/mercurial.py @@ -388,8 +388,9 @@ class MercurialVCS(ScriptMixin, LogMixin, TransferMixin): parser = RepositoryUpdateRevisionParser(config=self.config, log_obj=self.log_obj) - if self.run_command(args, output_parser=parser, - partial_env={'PYTHONUNBUFFERED': '1'}): + env = dict(os.environ) + env[b'PYTHONUNBUFFERED'] = b'1' + if self.run_command(args, output_parser=parser, env=env): raise VCSException('repo checkout failed!') if not parser.revision: