From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 88294 invoked by alias); 21 Feb 2019 18:35:20 -0000 Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org Received: (qmail 88263 invoked by uid 89); 21 Feb 2019 18:35:20 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-0.4 required=5.0 tests=BAYES_00,KAM_LAZY_DOMAIN_SECURITY,KAM_NUMSUBJECT,RCVD_IN_DNSWL_NONE autolearn=no version=3.3.2 spammy=HX-HELO:sk:mailout, Hx-spam-relays-external:194.25.134.17, H*RU:194.25.134.17, H*f:sk:1e11ab8 X-HELO: mailout02.t-online.de Received: from mailout02.t-online.de (HELO mailout02.t-online.de) (194.25.134.17) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Thu, 21 Feb 2019 18:35:18 +0000 Received: from fwd12.aul.t-online.de (fwd12.aul.t-online.de [172.20.26.241]) by mailout02.t-online.de (Postfix) with SMTP id 4427141C3E71; Thu, 21 Feb 2019 19:35:15 +0100 (CET) Received: from localhost (SUkseBZaQhoUNW9zTyf7UB2wTtE8iYx9RIvzhsD9xV6ulZ13+00C+E8MCTqNipIQyD@[91.65.71.127]) by fwd12.t-online.de with (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384 encrypted) esmtp id 1gwtBh-4VCgoi0; Thu, 21 Feb 2019 19:35:13 +0100 Date: Thu, 21 Feb 2019 18:35:00 -0000 From: =?iso-8859-1?Q?Andr=E9_P=F6nitz?= To: Kevin Buettner Cc: gdb@sourceware.org Subject: Re: Proposal: Drop GDB support for Python versions < 2.6 Message-ID: <20190221183729.GA2024@klara.mpi.htwm.de> References: <20190220134506.13960235@f29-4.lan> <1e11ab8bf081211e6cd21f052244c834cd0f21e4.camel@fit.cvut.cz> <20190220151145.04ca21c2@f29-4.lan> <20190220232848.GB30732@klara.mpi.htwm.de> <20190220233915.30b52f4c@f29-4.lan> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20190220233915.30b52f4c@f29-4.lan> X-IsSubscribed: yes X-SW-Source: 2019-02/txt/msg00051.txt.bz2 On Wed, Feb 20, 2019 at 11:39:15PM -0700, Kevin Buettner wrote: > On Thu, 21 Feb 2019 00:28:48 +0100 > André Pönitz wrote: > > > On Wed, Feb 20, 2019 at 03:11:45PM -0700, Kevin Buettner wrote: > > > On Wed, 20 Feb 2019 21:44:39 +0000 > > > Jan Vrany wrote: > > > > > > > Actually, I'd even be fine with more radical move, dropping support > > > > for 2.x altogether. Python 2.7 support will end in less a year > > > > from now anyway. > > > > > > I'm not ready to drop support for all of 2.X. > > > > Out of curiosity: Why? > > > > I.e. are there realistic scenarios where people actively use GDB's Python > > interface (in this context here I am tempted to call it a fairly "recent" > > addition to GDB, the first commit seems to be dated Aug 6, 2008), but are > > not able to use it with Python 3.x (3.0 released on Dec 3, also 2008)? > > I think so. See Eli's reply in this thread. I saw it after I wrote my mail. > When I build GDB on Fedora, I get a gdb enabled for python 2.7 unless > I take measures (via --with-python=/usr/bin/python3) to use python 3.X > instead. > > I just checked three recent linux distro releases: Mint 19.1, Debian 9.8, and > Fedora 29. For each of them, running "python --version" shows that they're > all Python 2.7.X. Python 3 is often available, but you have to use the > python3 command to use it. > > Checking my CentOS 7.6 box, I find that Python 2.7.5 is installed, but > Python 3 is not. However, I see that I could install some version of > Python 3 if I needed it. (I'm not using this machine for development.) > > I think we can drop Python 2.7 (and lower) sometime after the major > Linux distributions start defaulting to python 3.X for the "python" > command. I am not sure that the name of the python command is a good indicator for the timimg of the dropping support for Python 2.x: First, the version of Python used for 'python' is technical, and in a few cases also practically to the version of Python GDB uses. E.g. on some Ubuntu machine here I see something like: ~ > gdb -batch -ex 'import sys' -ex 'py print(sys.version)' 3.6.7 (default, Oct 22 2018, 11:32:17) ~ > python --version 2.7.15rc1 ~ > python3 --version 3.6.7 Second, there might be reasons for a distribution to never change the name of the python command, i.e. always keep it at e.g. 'python3', with no 'python' provided even after the distribution drops Python 2.x, so waiting for a 'python --version' to produe 3.x might as well mean 'never'. Andre' > > Kevin >