python, python@2: make PEP 394 compliant#25060
Conversation
65a86dd to
85d8a0f
Compare
There was a problem hiding this comment.
If the poll option is vanishing, then this will be built as if --without-poll were passed, which means we still need the inreplace, right?
There was a problem hiding this comment.
After reviewing the history of this hack, we want to get rid of it (i.e. in effect make --with-poll the new behavior).
Some background: the poll() system call on macOS is limited in some cases (devices, rather than regular files). Someone reported it to python, and suggested turning it off completely, i.e. mimicking a system that has no poll support at all. Upstream considered it, and decided they’d rather ship with poll support “as close to the OS”, rather than disable it altogether. We should follow that decision.
This means python (Python 3) installs as `python3` and that python@2 (Python 2) installs as `python` and `python2`. Also, - make gdbm, readline, sqlite and xz required instead of recommended - depend on sphinx-doc at build-time non-optionally to build the docs - remove quicktest option
This means python (Python 3) installs as `python3` and that python@2 (Python 2) installs as `python` and `python2`. Also, - make gdbm, readline and sqlite required instead of recommended - depend on sphinx-doc at build-time non-optionally to build the docs - remove berkeley-db@4 optional dependency - remove quicktest option - remove poll option and leave poll enabled instead of forcing it off
|
MacVim seems not yet included in this batch of changes. |
|
@adah1972 test passed… is macvim failing since this change? |
|
I’m late to the party, but I’m curious as to why you reversed the decision to avoid shadowing the system |
|
@fxcoudert I misunderstood the change. Let me be clear. Making Making The current way like that |
|
Reading more about this change, I think I am too late to the party. Maintainers really planned to do this half a year ago. I do not think my ‘counter-proposal’ can be accepted today, but I want to insist my point about dependent packages: packages that used to depend on Python should depend on Python2 instead of Python3 after the change of meaning of Python. Whether those packages should upgrade from Python2 to Python3 should be a case-by-case decision. Please notice that |
|
has anyone else encountered issues with their virtualenv and virtualenvwrapper now? |
|
@markstachowski virtualenvs use an absolute path, so whenever brew python is upgraded your virtualenvs are invalidated unless you keep the old versions lying around. Upstream does not consider that a bug. See pypa/pip#5048 |
|
sweet thx, ilovezfs! Not all heroes wear capes! |
|
@ilovezfs I think this change "breaks" $ swift
Traceback (most recent call last):
File "<input>", line 1, in <module>
File "/usr/local/Cellar/python@2/2.7.14_3/Frameworks/Python.framework/Versions/2.7/lib/python2.7/copy.py", line 52, in <module>
import weakref
File "/usr/local/Cellar/python@2/2.7.14_3/Frameworks/Python.framework/Versions/2.7/lib/python2.7/weakref.py", line 14, in <module>
from _weakref import (
ImportError: cannot import name _remove_dead_weakref
Traceback (most recent call last):
File "<input>", line 1, in <module>
NameError: name 'sys' is not defined[EDIT: there's a bunch of these, so I removed them out of mercy to those who need to scroll through this] Would you mind taking a quick look and seeing if it's caused by this? |
|
@saagarjha is anything observably functionally broken other than the unwanted messages about imports? |
|
I couldn't find anything that didn't work, but I'd assume the error is coming from an LLDB script that |
|
@saagarjha OK. At this point, I don't think it's worth making as a workaround. |
Updated to comply with PEP 394: https://www.python.org/dev/peps/pep-0394/
brew install --build-from-source <formula>, where<formula>is the name of the formula you're submitting?brew audit --strict <formula>(after doingbrew install <formula>)?https://www.python.org/dev/peps/pep-0394/
This means python (Python 3) installs as
python3and that python@2(Python 2) installs as
pythonandpython2.Also,
python:
python@2: