Homec4science

Work around `hg` echoing warnings to stdout under --debug

Authored by epriestley <git@epriestley.com> on Dec 18 2013, 03:04.

Description

Work around hg echoing warnings to stdout under --debug

Summary:
Ref T615. Ref T4237. With --debug, Mercurial will echo an "ignoring untrusted configuration option" warning to stdout if .hgrc has the wrong owner.

However, we need --debug to make {parents} usable, at least until the patches I got into the upstream are widely deployed. So after getting --debug output, strip off any leading warnings.

These warnings should always be in English, at least, since we set LANG explicitly.

Test Plan: Unit tests. @asherkin, maybe you can confirm this? I can't actually get the warning, but I think my hg in PATH is just a bit out of date.

Reviewers: asherkin, btrahan

Reviewed By: asherkin

CC: asherkin, aran

Maniphest Tasks: T615, T4237

Differential Revision: https://secure.phabricator.com/D7784

Details

Committed
epriestley <git@epriestley.com>Dec 18 2013, 03:04
Pushed
aubortJan 31 2017, 17:16
Parents
rPH3386920971b8: Add Herald support for blocking ref changes
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPHb0f7e7a6af2d: Work around `hg` echoing warnings to stdout under --debug (authored by epriestley <git@epriestley.com>).Dec 18 2013, 03:04