Re: [Python-Dev] Another update for PEP 394 -- The "python" Command on Unix-Like Systems

2019-02-14 Thread Sorin Sbarnea
I am glad this resurfaced as back in September I proposed updated that very old 
PEP but I got rejected.
https://github.com/python/peps/pull/785 


The main issue is that most distros will not fix it until PEP is refreshed 
because most of them do want to follow PEPs.

There is still hope.

Cheers
Sorin

> On 13 Feb 2019, at 16:20, Victor Stinner  wrote:
> 
> Hi,
> 
> I'm a (strong) supporter of providing a "python" command which would
> be the latest Python version!
> 
> As php does nowadays (after previous issues with "php4" vs "php5".) I
> don't recall that perl had "perl4" vs "perl5", the command was always
> "perl", no? Same for Ruby: it was still "ruby" after for Ruby 2, no?
> Only Python and PHP used different program names depending on the
> language version, no? And PHP now moved back to a single "php"
> program.
> 
> In the container and virtualenv era, it's now easy to get your
> favorite Python version for the "python" command.
> 
> On my Windows VM, "python" is Python 3.7 :-) In virtual environments,
> "python" can also be Python 3 as well.
> 
> I recall that I saw commands using "python" rather than "python3" in
> the *official* Python 3 documentation: see examples below (*).
> Problem: On Windows, "python" is the right command. "python3" doesn't
> work (doesn't exist) on Windows. Should we write the doc for Windows
> or for Unix? Oooops.
> 
> There was an interesting discussion about the Python version following
> Python 3.9: Python 3.10 or Python 4? And what are the issues which
> would make us prefer 3.10 rather than 4.0?
> https://mail.python.org/pipermail/python-committers/2018-September/006152.html
> 
> One practical issue is that right now, six.PY3 is defined by "PY3 =
> sys.version_info[0] == 3" and so "if six.PY3:" will be false on Python
> 4.
> 
> Another interesting thing to mention is the Unix Python launcher
> ("py") written by Brett Cannon written in Rust:
> https://github.com/brettcannon/python-launcher
> 
> 
> (*) A few examples of "python" commands in the Python official documentation
> 
> "$ python prog.py -h"
> https://docs.python.org/dev/library/argparse.html
> 
> "$ python logctx.py"
> https://docs.python.org/dev/howto/logging-cookbook.html
> 
> "python setup.py install"
> https://docs.python.org/dev/install/index.html
> 
> "python --help"
> https://docs.python.org/dev/howto/argparse.html
> 
> "python setup.py build"
> https://docs.python.org/dev/extending/building.html
> 
> "exec python $0 ${1+"$@"}"
> https://docs.python.org/dev/faq/library.html
> 
> "python setup.py --help build_ext"
> https://docs.python.org/dev/distutils/configfile.html
> 
> Victor
> 
> Le mer. 13 févr. 2019 à 16:49, Antoine Pitrou  a écrit :
>> 
>> On Wed, 13 Feb 2019 16:24:48 +0100
>> Petr Viktorin  wrote:
>>> PEP 394 says:
>>> 
 This recommendation will be periodically reviewed over the next few
 years, and updated when the core development team judges it
 appropriate. As a point of reference, regular maintenance releases
 for the Python 2.7 series will continue until at least 2020.
>>> 
>>> I think it's time for another review.
>>> I'm especially worried about the implication of these:
>>> 
>>> - If the `python` command is installed, it should invoke the same
>>>   version of Python as the `python2` command
>>> - scripts that are deliberately written to be source compatible
>>>   with both Python 2.x and 3.x [...] may continue to use `python` on
>>>   their shebang line.
>>> 
>>> So, to support scripts that adhere to the recommendation, Python 2
>>> needs to be installed :(
>> 
>> I think PEP 394 should acknowledge that there are now years of
>> established usage of `python` as Python 3 for many conda users.
>> 
>> Regards
>> 
>> Antoine.
>> 
>> 
>> ___
>> Python-Dev mailing list
>> Python-Dev@python.org
>> https://mail.python.org/mailman/listinfo/python-dev
>> Unsubscribe: 
>> https://mail.python.org/mailman/options/python-dev/vstinner%40redhat.com
> 
> 
> 
> -- 
> Night gathers, and now my watch begins. It shall not end until my death.
> ___
> Python-Dev mailing list
> Python-Dev@python.org
> https://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe: 
> https://mail.python.org/mailman/options/python-dev/sorin.sbarnea%40gmail.com

___
Python-Dev mailing list
Python-Dev@python.org
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Get a running instance of the doc for a PR.

2018-11-04 Thread Sorin Sbarnea
I can confirm that this is what OpenStack does. Sometimes the build artifacts 
(logs, docs ...) are rotated in two weeks but this is more than enough to 
perform a review. If I remember well retention is based on disk space and not 
hardcoded to a number of days, which is great.

TBH, I don't really know how a human can check the docs if they cannot access 
them on a webserver.

I hope to see the same on python too, very useful.

> On 4 Nov 2018, at 23:48, Victor Stinner  wrote:
> 
> OpenStack does that on review.openstack.org  
> PRs. If I recall correctly, the CI produces files which are online on a 
> static web server. Nothing crazy. And it works. Old files are removed, I 
> don't know when exactly.
> 
> I don't think that it matters where the static files are hosted.
> 
> Victor
> 
> Le dimanche 4 novembre 2018, Stephane Wirtel  > a écrit :
> > Hi all,
> >
> > When we receive a PR about the documentation, I think that could be
> > interesting if we could have a running instance of the doc on a sub
> > domain of python.org .
> >
> > For example, pr-1-doc.python.org  or 
> > whatever, but by this way the
> > reviewers could see the result online.
> >
> > The workflow would be like that:
> >
> > New PR -> build the doc (done by Travis) -> publish it to a server ->
> > once published, the PR is notified by "doc is available at URL".
> >
> > Once merged -> we remove the doc and the link (hello bedevere).
> >
> > I am interested by this feature and if you also interested, tell me.
> > I would like discuss with Julien Palard and Ernest W.  Durbin III for a
> > solution as soon as possible.
> >
> > Have a nice day,
> >
> > Stéphane
> >
> > --
> > Stéphane Wirtel - https://wirtel.be  - @matrixise
> > ___
> > Python-Dev mailing list
> > Python-Dev@python.org 
> > https://mail.python.org/mailman/listinfo/python-dev 
> > 
> > Unsubscribe: 
> > https://mail.python.org/mailman/options/python-dev/vstinner%40redhat.com 
> > 
> > ___
> Python-Dev mailing list
> Python-Dev@python.org
> https://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe: 
> https://mail.python.org/mailman/options/python-dev/sorin.sbarnea%40gmail.com

___
Python-Dev mailing list
Python-Dev@python.org
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com