Python 3.3.0 and PEP 394
Python 3.3.0 should be released around September 22. I would like to
take this opportunity to implement some of the recommendations of the PEP 394 [1]. This PEP was mostly done in reaction to what Arch did to the /usr/bin/python symlink (in summary, most python devs are against the move to python3 as a default at this time). In short: python2 should refer to some version of Python 2.x python3 should refer to some version of Python 3.x python should refer to the same target as python2 but may refer to python3 on some bleeding edge distributions This means that we should never have a reference to '#!/usr/bin/python' in any of our packages. All those reference should be changed to /usr/bin/python2 to refer to Python 2.x and /usr/bin/python3 for Python 3.x. The idea here is that a system without any python symlink should work without problem. Maybe namcap could be used to detect wrong shebang ? Another possibility, suggested by Allan, would be to go even further and use /usr/bin/python3.3 and /usr/bin/python2.7 for all shebangs. Then /usr/bin/python can point to any version and /usr/bin/python2 and /usr/bin/python3 can point to any pyhton2.x and python3.x respectively. These numbers in the shebangs will be changed when python bump is version number as we need to rebuild almost everything anyway. Any opinions ? Cheers, Stéphane [1] http://www.python.org/dev/peps/pep-0394/ |
Python 3.3.0 and PEP 394
On 13/09/12 10:00, Stéphane Gaudreault wrote:
> Python 3.3.0 should be released around September 22. I would like to > take this opportunity to implement some of the recommendations of the > PEP 394 [1]. This PEP was mostly done in reaction to what Arch did to > the /usr/bin/python symlink (in summary, most python devs are against > the move to python3 as a default at this time). > > In short: > python2 should refer to some version of Python 2.x > python3 should refer to some version of Python 3.x > python should refer to the same target as python2 but may refer to > python3 on some bleeding edge distributions > > This means that we should never have a reference to '#!/usr/bin/python' > in any of our packages. All those reference should be changed to > /usr/bin/python2 to refer to Python 2.x and /usr/bin/python3 for Python > 3.x. The idea here is that a system without any python symlink should > work without problem. Maybe namcap could be used to detect wrong shebang ? This is necessary as far as I am concerned. > Another possibility, suggested by Allan, would be to go even further and > use /usr/bin/python3.3 and /usr/bin/python2.7 for all shebangs. Then > /usr/bin/python can point to any version and /usr/bin/python2 and > /usr/bin/python3 can point to any pyhton2.x and python3.x respectively. > These numbers in the shebangs will be changed when python bump is > version number as we need to rebuild almost everything anyway. I'm leaning towards that being to much effort. Just using python2/python3 should be enough. One thing not mentioned in this email is that we really need to sort out the package naming in the repos. Two options: python-foo python2-foo or python3-foo python2-foo I personally would go for the first option, under the assumption that python4 will not exist for many years. Allan |
Python 3.3.0 and PEP 394
On 13 September 2012 12:18, Allan McRae <allan@archlinux.org> wrote:
> On 13/09/12 10:00, Stéphane Gaudreault wrote: >> Python 3.3.0 should be released around September 22. I would like to >> take this opportunity to implement some of the recommendations of the >> PEP 394 [1]. This PEP was mostly done in reaction to what Arch did to >> the /usr/bin/python symlink (in summary, most python devs are against >> the move to python3 as a default at this time). >> >> In short: >> python2 should refer to some version of Python 2.x >> python3 should refer to some version of Python 3.x >> python should refer to the same target as python2 but may refer to >> python3 on some bleeding edge distributions >> >> This means that we should never have a reference to '#!/usr/bin/python' >> in any of our packages. All those reference should be changed to >> /usr/bin/python2 to refer to Python 2.x and /usr/bin/python3 for Python >> 3.x. The idea here is that a system without any python symlink should >> work without problem. Maybe namcap could be used to detect wrong shebang ? > > This is necessary as far as I am concerned. And you have also been mentioning this from as far back as I can remember since the move. Therefore I would assume this is not (going to be) a problem if we have been listening. So now do we simply remove the python symlink and leave it up to the users? -- GPG/PGP ID: C0711BF1 |
Python 3.3.0 and PEP 394
On 13/09/12 20:32, Ray Rashif wrote:
> On 13 September 2012 12:18, Allan McRae <allan@archlinux.org> wrote: >> On 13/09/12 10:00, Stéphane Gaudreault wrote: >>> Python 3.3.0 should be released around September 22. I would like to >>> take this opportunity to implement some of the recommendations of the >>> PEP 394 [1]. This PEP was mostly done in reaction to what Arch did to >>> the /usr/bin/python symlink (in summary, most python devs are against >>> the move to python3 as a default at this time). >>> >>> In short: >>> python2 should refer to some version of Python 2.x >>> python3 should refer to some version of Python 3.x >>> python should refer to the same target as python2 but may refer to >>> python3 on some bleeding edge distributions >>> >>> This means that we should never have a reference to '#!/usr/bin/python' >>> in any of our packages. All those reference should be changed to >>> /usr/bin/python2 to refer to Python 2.x and /usr/bin/python3 for Python >>> 3.x. The idea here is that a system without any python symlink should >>> work without problem. Maybe namcap could be used to detect wrong shebang ? >> >> This is necessary as far as I am concerned. > > And you have also been mentioning this from as far back as I can > remember since the move. Therefore I would assume this is not (going > to be) a problem if we have been listening. > > So now do we simply remove the python symlink and leave it up to the users? > No. We keep it as python -> python3. The user can change it to point it at python2 if they want but given we have no alternatives system in pacman, it will revert on python3 upgrades. Maybe something to implement... Allan |
Python 3.3.0 and PEP 394
On Thu, Sep 13, 2012 at 2:00 AM, Stéphane Gaudreault
<stephane@archlinux.org> wrote: > Any opinions ? I think this PEP give convention between distro and python developers to have portable scripts. Our part is to provide python2* and python3* symlinks. The dev parts is to use correct sheebang is there scripts (or better, let installer define it). The main message in this PEP to developper is DO_NOT_USE python it can refer to python 2.x or python 3.x. We can thanks this PEP to legitimate what archlinux is doing (promoting the future of python). Let user choose if his python is symlinked to python2 or python3 will not fix a day to day use of python2 and python3 scripts which doesn't respect this PEP and increase the current mess. About packages we fix by a sexy sed line, we can stay to our official /usr/bin/python interpreter as we do for each packages. -- Sébastien "Seblu" Luttringer www.seblu.net |
Python 3.3.0 and PEP 394
Le 2012-09-13 00:18, Allan McRae a écrit :
On 13/09/12 10:00, Stéphane Gaudreault wrote: Python 3.3.0 should be released around September 22. I would like to take this opportunity to implement some of the recommendations of the PEP 394 [1]. This PEP was mostly done in reaction to what Arch did to the /usr/bin/python symlink (in summary, most python devs are against the move to python3 as a default at this time). In short: python2 should refer to some version of Python 2.x python3 should refer to some version of Python 3.x python should refer to the same target as python2 but may refer to python3 on some bleeding edge distributions This means that we should never have a reference to '#!/usr/bin/python' in any of our packages. All those reference should be changed to /usr/bin/python2 to refer to Python 2.x and /usr/bin/python3 for Python 3.x. The idea here is that a system without any python symlink should work without problem. Maybe namcap could be used to detect wrong shebang ? This is necessary as far as I am concerned. Another possibility, suggested by Allan, would be to go even further and use /usr/bin/python3.3 and /usr/bin/python2.7 for all shebangs. Then /usr/bin/python can point to any version and /usr/bin/python2 and /usr/bin/python3 can point to any pyhton2.x and python3.x respectively. These numbers in the shebangs will be changed when python bump is version number as we need to rebuild almost everything anyway. I'm leaning towards that being to much effort. Just using python2/python3 should be enough. One thing not mentioned in this email is that we really need to sort out the package naming in the repos. Two options: python-foo python2-foo or python3-foo python2-foo I personally would go for the first option, under the assumption that python4 will not exist for many years. Allan I did not mentioned the packages name because I am fine with the statu quo on this. If there is a concensus that we want to change the naming, I would suggest - change the name of the python pkg -> python3 - Change the package names with the following structure: pkgbase = python-something pkgname = ('python2-something' 'python3-something') - If a package only has python 2 or 3 version, it could follow a similar structure : pkgbase = python-something pkgname = ('python3-something') OR pkgname = ('python2-something') Stéphane |
Python 3.3.0 and PEP 394
On 13/09/12 21:53, Stéphane Gaudreault wrote:
> Le 2012-09-13 00:18, Allan McRae a écrit : >> On 13/09/12 10:00, Stéphane Gaudreault wrote: >>> Python 3.3.0 should be released around September 22. I would like to >>> take this opportunity to implement some of the recommendations of the >>> PEP 394 [1]. This PEP was mostly done in reaction to what Arch did to >>> the /usr/bin/python symlink (in summary, most python devs are against >>> the move to python3 as a default at this time). >>> >>> In short: >>> python2 should refer to some version of Python 2.x >>> python3 should refer to some version of Python 3.x >>> python should refer to the same target as python2 but may refer to >>> python3 on some bleeding edge distributions >>> >>> This means that we should never have a reference to '#!/usr/bin/python' >>> in any of our packages. All those reference should be changed to >>> /usr/bin/python2 to refer to Python 2.x and /usr/bin/python3 for Python >>> 3.x. The idea here is that a system without any python symlink should >>> work without problem. Maybe namcap could be used to detect wrong >>> shebang ? >> This is necessary as far as I am concerned. >> >>> Another possibility, suggested by Allan, would be to go even further and >>> use /usr/bin/python3.3 and /usr/bin/python2.7 for all shebangs. Then >>> /usr/bin/python can point to any version and /usr/bin/python2 and >>> /usr/bin/python3 can point to any pyhton2.x and python3.x respectively. >>> These numbers in the shebangs will be changed when python bump is >>> version number as we need to rebuild almost everything anyway. >> I'm leaning towards that being to much effort. Just using >> python2/python3 should be enough. >> >> >> One thing not mentioned in this email is that we really need to sort out >> the package naming in the repos. Two options: >> >> python-foo >> python2-foo >> >> or >> >> python3-foo >> python2-foo >> >> >> I personally would go for the first option, under the assumption that >> python4 will not exist for many years. >> >> Allan >> > > I did not mentioned the packages name because I am fine with the statu > quo on this. What is the status quo? Something called python-foo can be either python2 or python3 at the moment. > If there is a concensus that we want to change the naming, > I would suggest > > - change the name of the python pkg -> python3 > > - Change the package names with the following structure: > pkgbase = python-something > pkgname = ('python2-something' 'python3-something') > > - If a package only has python 2 or 3 version, it could follow a similar > structure : > pkgbase = python-something > pkgname = ('python3-something') OR pkgname = ('python2-something') > > Stéphane > > |
Python 3.3.0 and PEP 394
Le 2012-09-13 08:04, Allan McRae a écrit :
On 13/09/12 21:53, Stéphane Gaudreault wrote: Le 2012-09-13 00:18, Allan McRae a écrit : On 13/09/12 10:00, Stéphane Gaudreault wrote: Python 3.3.0 should be released around September 22. I would like to take this opportunity to implement some of the recommendations of the PEP 394 [1]. This PEP was mostly done in reaction to what Arch did to the /usr/bin/python symlink (in summary, most python devs are against the move to python3 as a default at this time). In short: python2 should refer to some version of Python 2.x python3 should refer to some version of Python 3.x python should refer to the same target as python2 but may refer to python3 on some bleeding edge distributions This means that we should never have a reference to '#!/usr/bin/python' in any of our packages. All those reference should be changed to /usr/bin/python2 to refer to Python 2.x and /usr/bin/python3 for Python 3.x. The idea here is that a system without any python symlink should work without problem. Maybe namcap could be used to detect wrong shebang ? This is necessary as far as I am concerned. Another possibility, suggested by Allan, would be to go even further and use /usr/bin/python3.3 and /usr/bin/python2.7 for all shebangs. Then /usr/bin/python can point to any version and /usr/bin/python2 and /usr/bin/python3 can point to any pyhton2.x and python3.x respectively. These numbers in the shebangs will be changed when python bump is version number as we need to rebuild almost everything anyway. I'm leaning towards that being to much effort. Just using python2/python3 should be enough. One thing not mentioned in this email is that we really need to sort out the package naming in the repos. Two options: python-foo python2-foo or python3-foo python2-foo I personally would go for the first option, under the assumption that python4 will not exist for many years. Allan I did not mentioned the packages name because I am fine with the statu quo on this. What is the status quo? Something called python-foo can be either python2 or python3 at the moment. I mean that I don't really care if we use python-foo python2-foo or python3-foo python2-foo even if I have a preference for the latter (also used in many other distro). However, it would be nice if we could have consistent maning across all the packages at the end of the python 3.3.0 rebuild. |
Python 3.3.0 and PEP 394
On Thu, Sep 13, 2012 at 7:03 PM, Stéphane Gaudreault
<stephane@archlinux.org> wrote: > Le 2012-09-13 08:04, Allan McRae a écrit : > >> On 13/09/12 21:53, Stéphane Gaudreault wrote: >>> >>> Le 2012-09-13 00:18, Allan McRae a écrit : >>>> >>>> On 13/09/12 10:00, Stéphane Gaudreault wrote: >>>>> >>>>> Python 3.3.0 should be released around September 22. I would like to >>>>> take this opportunity to implement some of the recommendations of the >>>>> PEP 394 [1]. This PEP was mostly done in reaction to what Arch did to >>>>> the /usr/bin/python symlink (in summary, most python devs are against >>>>> the move to python3 as a default at this time). >>>>> >>>>> In short: >>>>> python2 should refer to some version of Python 2.x >>>>> python3 should refer to some version of Python 3.x >>>>> python should refer to the same target as python2 but may refer to >>>>> python3 on some bleeding edge distributions >>>>> >>>>> This means that we should never have a reference to '#!/usr/bin/python' >>>>> in any of our packages. All those reference should be changed to >>>>> /usr/bin/python2 to refer to Python 2.x and /usr/bin/python3 for Python >>>>> 3.x. The idea here is that a system without any python symlink should >>>>> work without problem. Maybe namcap could be used to detect wrong >>>>> shebang ? >>>> >>>> This is necessary as far as I am concerned. >>>> >>>>> Another possibility, suggested by Allan, would be to go even further >>>>> and >>>>> use /usr/bin/python3.3 and /usr/bin/python2.7 for all shebangs. Then >>>>> /usr/bin/python can point to any version and /usr/bin/python2 and >>>>> /usr/bin/python3 can point to any pyhton2.x and python3.x respectively. >>>>> These numbers in the shebangs will be changed when python bump is >>>>> version number as we need to rebuild almost everything anyway. >>>> >>>> I'm leaning towards that being to much effort. Just using >>>> python2/python3 should be enough. >>>> >>>> >>>> One thing not mentioned in this email is that we really need to sort out >>>> the package naming in the repos. Two options: >>>> >>>> python-foo >>>> python2-foo >>>> >>>> or >>>> >>>> python3-foo >>>> python2-foo >>>> >>>> >>>> I personally would go for the first option, under the assumption that >>>> python4 will not exist for many years. >>>> >>>> Allan >>>> >>> I did not mentioned the packages name because I am fine with the statu >>> quo on this. >> >> What is the status quo? Something called python-foo can be either >> python2 or python3 at the moment. >> >> > I mean that I don't really care if we use > > > python-foo > python2-foo > > or > > python3-foo > python2-foo > > even if I have a preference for the latter (also used in many other distro). We also have python libraries not prefixed by python- (e.g: pyalpm, pycups, pygtk, etc), I think we should also update with pkgbase=pygtk pkgname=(python-gtk python2-gtk) > However, it would be nice if we could have consistent maning across all the > packages at the end of the python 3.3.0 rebuild. I prefer the first, we have the same case with lua and we should let program name be the last upstream "stable" version. Python is python 3, python 2 is dying (hardly) and I hope move from python 3 to python 4 will be smooth. Cheers, -- Sébastien "Seblu" Luttringer www.seblu.net |
Python 3.3.0 and PEP 394
On 14 September 2012 02:18, Sébastien Luttringer <seblu@seblu.net> wrote:
> We also have python libraries not prefixed by python- (e.g: pyalpm, > pycups, pygtk, etc), I think we should also update with > pkgbase=pygtk > pkgname=(python-gtk python2-gtk) That breaks common knowledge and conventional project names. This happened with pyqt: python2-qt python-qt Those look absolutely nothing like 'PyQt', which is the project name. We worked around this for a while using 'PyQt:' in the description so that it'd come up in searches for 'pyqt'. You could also provide for it in both, but that would still be a workaround. Andrea has since repackaged them as 'python2-pyqt' and simply 'pyqt', which looks, sounds and feels much better. >> However, it would be nice if we could have consistent maning across all the >> packages at the end of the python 3.3.0 rebuild. > > I prefer the first, we have the same case with lua and we should let > program name be the last upstream "stable" version. > Python is python 3, python 2 is dying (hardly) and I hope move from > python 3 to python 4 will be smooth. > > Cheers, > > -- > Sébastien "Seblu" Luttringer > www.seblu.net -- GPG/PGP ID: C0711BF1 |
| All times are GMT. The time now is 05:31 AM. |
VBulletin, Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.