[Python-Dev] Removal of install_misc command from distutils

Paul Moore p.f.moore at gmail.com
Sat Jul 7 05:51:20 EDT 2018


On 7 July 2018 at 01:25, Ned Deily <nad at python.org> wrote:
> On Jul 6, 2018, at 19:43, Alexander Belopolsky <alexander.belopolsky at gmail.com> wrote:

>> I think it will be prudent to get this command back in Python 3.7.1.  My work-around was to simply copy the 20-something lines that define install_misc from Python 3.6 to my setup.py file.

You'll still need those 20 lines in your code if you want to support
Python 3.7.0, and *not* supporting 3.7.0 but supporting 3.7.1 doesn't
seem like a good idea to me. TBH, I'd consider "copy the 20 lines of
code into your own setup.py to be a perfectly acceptable workaround.

>> It was my impression that it is precisely due to situations like this, distutils was considered more or less frozen for development and all new features went to setuptools.

For a long while distutils was frozen, and yes it was basically
because of a fear that nothing could be changed without potentially
disrupting someone. But that resulted in essentially a paralysis of
work on packaging for many years, and wasn't a good thing. The embargo
on changes to distutils was lifted a long time ago - although we
remain cautious about making changes because we don't want to break
people's code. As Ned noted, you had the whole Python 3.7 alpha and
beta phase to test your code, and if you had raised the issue then, we
could have considered reverting this change (but my view would still
have been "we'll remove it and you should just copy the code").

A quick search of bpo [1] shows many changes to distutils in recent time, FWIW.

> If you want to pursue it, I think the best thing to do would be to bring up the issue on the distutils-sig mailing list where the change probably should have been discussed first if it wasn't and also reopen https://bugs.python.org/issue29218.  AFAIK, the removal hasn't come up as a problem before in the nearly 18 months since the change was first merged into the feature branch.

IMO, a tracker issue was fine, and  the OP could have commented there.
Distutils-sig isn't really the right audience for minor detail changes
like this - although if someone wanted to raise the broader principle
"let's reinstate the total freeze on distutils changes" that would be
appropriate for distutils-sig. I'd fully expect a resounding rejection
for that proposition, though.

At this point, I think the only realistic resolution would be to add a
note to the "Porting to Python 3.7" docs explaining that users of
install_misc should copy the code from 3.6 into their setup.py. But
it's quite likely that the only person who needs that documentation is
Alexander (we've not had any other reports of this issue to my
knowledge) so that may be overkill...

Paul

[1] https://bugs.python.org/issue?%40search_text=&ignore=file%3Acontent&title=&%40columns=title&id=&%40columns=id&stage=6&creation=&creator=&activity=&%40columns=activity&%40sort=activity&actor=&nosy=&type=&components=3&versions=&dependencies=&assignee=&keywords=&priority=&status=2&%40columns=status&resolution=3&nosy_count=&message_count=&%40group=&%40pagesize=50&%40startwith=0&%40sortdir=on&%40action=search


More information about the Python-Dev mailing list