[PATCH 4 of 6 v4] debuginstall: expose modulepolicy

timeless timeless at gmail.com
Wed May 18 14:00:44 EDT 2016


Yuya Nishihara wrote:
> I don't know if it is better idea than making policy module, but we can add
> a utility function to avoid "from . import modulepolicy" in commands.py.
>
> --- a/mercurial/util.py
> +++ b/mercurial/util.py
> @@ -357,6 +357,10 @@ def popen4(cmd, env=None, newlines=False
>                           env=env)
>      return p.stdin, p.stdout, p.stderr, p
>
> +def modulepolicy():
> +    from . import modulepolicy
> +    return modulepolicy

Personally, I'd like this. I did it the hard way because iirc augie
objected to that style saying it's poor form.

I don't really care which way we do it. I just need the ability to use
hg debuginstall so that ./run-tests.py --with-hg works properly. The
sooner the better.


More information about the Mercurial-devel mailing list