git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: yz/p4-py3, was Re: What's cooking in git.git (Feb 2020, #03; Wed, 12)

From
SZEDER Gábor <szeder.dev@gmail.com>
Date
Mar 10, 2020, 17:38 UTC
Message-ID
<20200310173835.GC3122@szeder.dev>
In-Reply-To
<xmqqk14qqj7n.fsf@gitster-ct.c.googlers.com>
On Thu, Feb 13, 2020 at 01:18:52PM -0800, Junio C Hamano wrote:
Show 10 quoted lines
> Junio C Hamano <gitster@pobox.com> writes:
> 
> > OK, any one of you wants to do the honors of wrapping up the
> > proposed patch with a log message to replace the tip commit to allow
> > us to move forward?
> 
> 
> So the diff was taken from <20200123175645.GF6837@szeder.dev>; with
> Szeder's SoB (and possibly wordsmithing the log message) let's tie
> this loose end.
Here is the SoB and the wordsmithed commit message.
Show 14 quoted lines
> Thanks.
> 
> -- >8 --
> 
> From: SZEDER Gábor <szeder.dev@gmail.com>
> Date: Thu, 23 Jan 2020 18:56:45 +0100
> Subject: [PATCH] ci: use python3 in linux-gcc and osx-gcc and python2 elsewhere
> 
> Python2 reached end of life, and we have been preparing git-p4
> (which is the sole in-tree user of Python) to work with Python3
> but we haven't told our CI jobs to use Python3 anywhere yet.
> 
> Pick two jobs and use Python3 there, while leaving other jobs
> to still stick to Python2 for now.
  --- >8 ---
Subject: [PATCH] ci: use python3 in linux-gcc and osx-gcc and python2 elsewhere

Python2 reached end of life, and we have been preparing our Python scripts to work with Python3. 'git p4', the main in-tree user of Python, has just received a number of compatibility updates. Our other notable Python script 'contrib/svn-fe/svnrdump_sim.py' is only used in 't9020-remote-svn.sh', and is apparently already compatible with both Python2 and 3.

Our CI jobs currently only use Python2. We want to make sure that these Python scripts do indeed work with Python3, and we also want to make sure that these scripts keep working with Python2 as well, for the sake of some older LTS/Enterprise setups.

Therefore, pick two jobs and use Python3 there, while leaving other jobs to still stick to Python2 for now.

Signed-off-by: SZEDER Gábor <szeder.dev@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  --- >8 ---
Show 32 quoted lines
> Signed-off-by: Junio C Hamano <gitster@pobox.com>
> ---
>  ci/lib.sh | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/ci/lib.sh b/ci/lib.sh
> index a90d0dc0fd..c3a8cd2104 100755
> --- a/ci/lib.sh
> +++ b/ci/lib.sh
> @@ -162,6 +162,9 @@ linux-clang|linux-gcc)
>  	if [ "$jobname" = linux-gcc ]
>  	then
>  		export CC=gcc-8
> +		MAKEFLAGS="$MAKEFLAGS PYTHON_PATH=$(which python3)"
> +	else
> +		MAKEFLAGS="$MAKEFLAGS PYTHON_PATH=$(which python2)"
>  	fi
>  
>  	export GIT_TEST_HTTPD=true
> @@ -182,6 +185,9 @@ osx-clang|osx-gcc)
>  	if [ "$jobname" = osx-gcc ]
>  	then
>  		export CC=gcc-9
> +		MAKEFLAGS="$MAKEFLAGS PYTHON_PATH=$(which python3)"
> +	else
> +		MAKEFLAGS="$MAKEFLAGS PYTHON_PATH=$(which python2)"
>  	fi
>  
>  	# t9810 occasionally fails on Travis CI OS X
> -- 
> 2.25.0-462-gba6e6679b4
> 
Previous: Junio C HamanoNext: Junio C Hamano
Message 13 of 16 in “What's cooking in git.git (Feb 2020, #03; Wed, 12)”
  1. Junio C HamanoFeb 12, 2020
  2. bw/remote-rename-update-config, was Re: What's cooking in git.git (Feb 2020, #03; Wed, 12)Johannes Schindelin, Feb 13, 2020
  3. yz/p4-py3, was Re: What's cooking in git.git (Feb 2020, #03; Wed, 12)Johannes Schindelin, Feb 13, 2020
  4. Junio C HamanoFeb 13, 2020
  5. Junio C HamanoFeb 13, 2020
  6. Junio C HamanoFeb 14, 2020
  7. Denton LiuFeb 14, 2020
  8. Ben KeeneFeb 14, 2020
  9. Junio C HamanoFeb 14, 2020
  10. Junio C HamanoFeb 14, 2020
  11. Ben KeeneFeb 14, 2020
  12. Junio C HamanoFeb 14, 2020
  13. SZEDER GáborMar 10, 2020
  14. Junio C HamanoMar 10, 2020
  15. Elijah NewrenFeb 16, 2020
  16. Pratyush YadavFeb 17, 2020

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.