[bug#71672] [PATCH] python: Prefer python3 over python

2025-02-25 Thread Collin Funk
Hi Karl, Karl Berry writes: > I'm hoping to put out the first pretest tomorrow and 1.18 not long > after. So clearly this Python stuff needs to wait for another release. Thanks for mentioning this again. That plan sounds fine. Python packages seem to have their own packaging stuff that works we

[bug#71672] [PATCH] python: Prefer python3 over python

2025-02-25 Thread Karl Berry
What does your schedule look like for the next Automake release? I'm hoping to put out the first pretest tomorrow and 1.18 not long after. So clearly this Python stuff needs to wait for another release. Thanks for the quick reply. -k

[bug#71672] [PATCH] python: Prefer python3 over python

2025-02-25 Thread Zack Weinberg
On Mon, Feb 24, 2025, at 11:48 AM, Karl Berry wrote: > Returning to this issue of preferring python3, from last year: > > https://debbugs.gnu.org/cgi/bugreport.cgi?bug=71672 > > Add these three macros to Autoconf proper: ..._PYTHON_... > > Have they been added? They have not. Regrettably,

[bug#71672] [PATCH] python: Prefer python3 over python

2025-02-25 Thread Zack Weinberg
On Mon, Feb 24, 2025, at 11:03 PM, Jacob Bachmeyer wrote: > On 2/24/25 10:48, Karl Berry wrote: >> [...] >> >> To be clear, the above suggested factoring-out won't (intentionally) >> affect the behavior of AM_PATH_PYTHON, right? It will still look for >> "python" first, and still do all the stuff i

[bug#71672] [PATCH] python: Prefer python3 over python

2025-02-24 Thread Jacob Bachmeyer
On 2/24/25 10:48, Karl Berry wrote: [...] To be clear, the above suggested factoring-out won't (intentionally) affect the behavior of AM_PATH_PYTHON, right? It will still look for "python" first, and still do all the stuff it does. I want Automake to stay as backward-compatible as possible. Th

[bug#71672] [PATCH] python: Prefer python3 over python

2025-02-24 Thread Karl Berry
Returning to this issue of preferring python3, from last year: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=71672 Add these three macros to Autoconf proper: ..._PYTHON_... Have they been added? I think that should disentangle things reasonably well, but we should defini

[bug#71672] [PATCH] python: Prefer python3 over python

2024-06-23 Thread Karl Berry
zw> Add these three macros to Autoconf proper: ... Automake's python.m4 should also define these if they are not already defined. Then, we split AM_PATH_PYTHON ... Thanks Zack. It all sounds good to me. definitely do this early rather than late in an automake release cycle

[bug#71672] [PATCH] python: Prefer python3 over python

2024-06-22 Thread Collin Funk
Zack Weinberg wrote: > Automake's python.m4 should also define these if they are not already defined. > Then, we split AM_PATH_PYTHON into the part that sets PYTHON, which is > implemented > in terms of the above macros (but still looks for both 2 and 3) and the part > that > does all the rest of

[bug#71672] [PATCH] python: Prefer python3 over python

2024-06-22 Thread Zack Weinberg
Here's what I think might be useful: Add these three macros to Autoconf proper: # AC_PYTHON_VERSION_RANGE_IFELSE([PROG], [MIN-VERSION], [MAX-VERSION = next-major], #[ACTION-IF-TRUE], [ACTION-IF-FALSE]) # - # Run

[bug#71672] [PATCH] python: Prefer python3 over python

2024-06-22 Thread Karl Berry
Or maybe AM_PYTHON3_PATH which requires Python3 so that the interface of the original macro isn't changed. My idea for having a separate options command was for the future: who knows what incompatibilities python will create in the future. Other options besides p3 vs p2 might be needed. In

[bug#71672] [PATCH] python: Prefer python3 over python

2024-06-21 Thread Collin Funk
Hi Karl, Karl Berry wrote: > Yes ... but I feel strongly that we should try very hard not to break > existing configure setups. Reasonable goal. > It occurs to me that we could allow maintainers to specify p3-searching > options in their configure.ac, like > > AM_PYTHON_OPTS(python3-check-first

[bug#71672] [PATCH] python: Prefer python3 over python

2024-06-21 Thread Karl Berry
I thought the intention was to prioritize python 3.X which would cause problems using "python" first. Yes ... but I feel strongly that we should try very hard not to break existing configure setups. It occurs to me that we could allow maintainers to specify p3-searching options in their c

[bug#71672] [PATCH] python: Prefer python3 over python

2024-06-20 Thread Collin Funk
Karl Berry wrote: > I can imagine preferring "python3" to "python" in the future, but this > seems like too big of a change to make at the very end (I hope) of the > pretest cycle. I think it would be better to make it well in advance of > the next release and try to garner feedback on the inevitab

[bug#71672] [PATCH] python: Prefer python3 over python

2024-06-20 Thread Karl Berry
Collin, Zack - > Shouldn't AM_PATH_PYTHON check for the python3 command before python? Yes it should. That seems like a huge change to make. I understand the reasoning, given the world of Python, but the goal of "don't break existing projects" argues against it. Note that PEP 394 i

[bug#71672] [PATCH] python: Prefer python3 over python

2024-06-20 Thread Zack Weinberg
On Thu, Jun 20, 2024, at 5:50 AM, Collin Funk wrote: > Shouldn't AM_PATH_PYTHON check for the python3 command before python? Yes it should. > The full recommendation of how these should be setup is in PEP 394 Note that PEP 394 is dangerously incorrect on one point: a system where /usr/bin/python

[bug#71672] [PATCH] python: Prefer python3 over python

2024-06-20 Thread Collin Funk
Hi, Shouldn't AM_PATH_PYTHON check for the python3 command before python? The full recommendation of how these should be setup is in PEP 394 [1]. On modern systems I don't think it should matter. On Fedora 40: $ command -v python /usr/bin/python $ command -v python3 /usr/bin/pyth