[PATCH STABLE] setup: properly package distutils in py2exe virtualenv builds

Yuya Nishihara yuya at tcha.org
Sat Apr 20 20:47:56 EDT 2019


On Sat, 20 Apr 2019 07:29:31 -0700, Gregory Szorc wrote:
> # HG changeset patch
> # User Gregory Szorc <gregory.szorc at gmail.com>
> # Date 1555770547 25200
> #      Sat Apr 20 07:29:07 2019 -0700
> # Branch stable
> # Node ID f9255e70f459cda1391194497b23346f3a402997
> # Parent  84b5ad5fc2aa81d114d0c8ff869367104e997dd3
> setup: properly package distutils in py2exe virtualenv builds

Queued for stable, thanks.

Packaging for Windows is always a hard job.

> +            # Replace virtualenv's distutils modules with the real ones.
> +            res.modules = {
> +                k: v for k, v in res.modules.items()
> +                if k != 'distutils' and not k.startswith('distutils.')}

We might want to keep setup.py parsable by Python 2.6 to show a better warning.


More information about the Mercurial-devel mailing list