Gmail Calendar Documents Reader Web more »
Recently Visited Groups | Help | Sign in
Google Groups Home
Pep 3105: the end of print?
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  Messages 51 - 75 of 85 - Collapse all  -  Translate all to Translated (View all originals) < Older  Newer >
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Peter mayne  
View profile  
 More options Feb 19 2007, 7:44 pm
Newsgroups: comp.lang.python
From: Peter mayne <Peter.Ma...@hp.com>
Date: Tue, 20 Feb 2007 00:44:24 GMT
Local: Mon, Feb 19 2007 7:44 pm
Subject: Re: Pep 3105: the end of print?

Steven D'Aprano wrote:
> If Python 3 dropped the print
> statement and replaced it with official_print_function(), how would that
> help you in your goal to have a single code base that will run on both
> Python 2.3 and Python 3, while still using print?

Is there any reason why official_print_function isn't sys.stdout.write?

I can't remember the last time I used print in actual code (apart from
short-lived debugging lines), so I'm bewildered as to why print seems to
be so important.

PJDM


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Steven D'Aprano  
View profile  
 More options Feb 20 2007, 8:02 am
Newsgroups: comp.lang.python
From: Steven D'Aprano <st...@REMOVE.THIS.cybersource.com.au>
Date: Wed, 21 Feb 2007 00:02:43 +1100
Local: Tues, Feb 20 2007 8:02 am
Subject: Re: Pep 3105: the end of print?

On Tue, 20 Feb 2007 00:44:24 +0000, Peter mayne wrote:
> Steven D'Aprano wrote:
>> If Python 3 dropped the print
>> statement and replaced it with official_print_function(), how would that
>> help you in your goal to have a single code base that will run on both
>> Python 2.3 and Python 3, while still using print?

> Is there any reason why official_print_function isn't sys.stdout.write?

Why would you want a convenience function like print to take one import,
three look-ups and 16 characters instead of always available, one look-up
and five characters?

> I can't remember the last time I used print in actual code (apart from
> short-lived debugging lines), so I'm bewildered as to why print seems to
> be so important.

print is important for the convenience, for short-lived debugging, and for
use in the interactive interpreter.

--
Steven.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Discussion subject changed to "Python 3.0 unfit for serious work?" by Jay Tee
Jay Tee  
View profile  
(2 users)  More options Feb 20 2007, 11:49 am
Newsgroups: comp.lang.python
From: "Jay Tee" <jeff.temp...@gmail.com>
Date: 20 Feb 2007 08:49:10 -0800
Local: Tues, Feb 20 2007 11:49 am
Subject: Python 3.0 unfit for serious work?
Yo,

On Feb 16, 6:07 am, Steven Bethard <steven.beth...@gmail.com> wrote:

> Python 3.0 is determined not to be hampered by backwards incompatibility
> concerns. It's not even clear yet that your average 2.6 code will work

Then Python is pretty much determined to remove itself from
consideration
from various kinds of international projects like the one I work on.
We're already catching flack from people due to a few things that were
valid
in 2.2 that are not valid in 2.3 (I don't have the details but could
scare them
up).  The project we work on contains code from many different people
and has to
run on thousands of computers all over the world.  The installed base
at the
moment is a mix of RHEL 3, RHEL 4, and Debian, with a few other
machines thrown in.
The relevant Python versions at this moment IIRC are 2.2.3 and 2.3.4,
because these
are the native versions on those platforms.

We are estimating, due to the speed at which our applications follow
OS releases, that
we can drop RHEL 3 (and hence Python 2.2) support a year from now.  Go
figure when you
think we might be ready to require that all programs run on python
3.0.  If it's not
backwards compatible, meaning if 2.4 code doesn't run on 3.0, it's
rather likely that
strong pressure will be applied to port *away* from Python into
something less capricious.

Bottom line: practicality and beauty is always a tradeoff.  Oberon is
the most beautiful
language I ever saw, but there is almost nobody using it any more.
Too many beauty contests over who had the best proposal for a standard
library.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Discussion subject changed to "Pep 3105: the end of print?" by Beliavsky
Beliavsky  
View profile  
(1 user)  More options Feb 20 2007, 1:46 pm
Newsgroups: comp.lang.python
From: "Beliavsky" <beliav...@aol.com>
Date: 20 Feb 2007 10:46:31 -0800
Local: Tues, Feb 20 2007 1:46 pm
Subject: Re: Pep 3105: the end of print?
On Feb 16, 10:17 am, Steven D'Aprano

The attitudes towards backwards compatibility of the Fortran standards
committee and the Python BDFL is very different.

Fortran 90 was a superset of Fortran 77, so standard-conforming
Fortran 77 programs have the same meaning when compiled with an F90
compiler. The committee does not consider changing things like the
meaning of 1/2. Even though WRITE provides a superset of the
functionality of PRINT, the committee would not dream of breaking so
much code by removing PRINT. No feature is deleted without being
declared obsolescent in a previous standard, which makes it easier to
plan ahead. In practice Fortran 95 compilers accept deleted features,
but they are required to a have a switch that identifies non-standard
code.

I think the C and C++ committees also take backwards compatibility
seriously, in part because they know
that working programmers will ignore them if they break too much old
code.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Discussion subject changed to "Python 3.0 unfit for serious work?" by Steven Bethard
Steven Bethard  
View profile  
 More options Feb 20 2007, 2:59 pm
Newsgroups: comp.lang.python
From: Steven Bethard <steven.beth...@gmail.com>
Date: Tue, 20 Feb 2007 12:59:53 -0700
Local: Tues, Feb 20 2007 2:59 pm
Subject: Re: Python 3.0 unfit for serious work?

Jay Tee wrote:
> Yo,

> On Feb 16, 6:07 am, Steven Bethard <steven.beth...@gmail.com> wrote:
>> Python 3.0 is determined not to be hampered by backwards incompatibility
>> concerns. It's not even clear yet that your average 2.6 code will work

> Then Python is pretty much determined to remove itself from
> consideration
> from various kinds of international projects like the one I work on.

You snipped the rest of that comment:

"It's not even clear yet that your average 2.6 code will work on 3.0 --
though there's a pretty large contingent trying to make this true."

If you want to make sure average 2.6 code works on 3.0, please help
contribute to Python. You can find out where best to focus your efforts
by asking on python-dev:

     http://mail.python.org/mailman/listinfo/python-dev

> If it's not backwards compatible, meaning if 2.4 code doesn't run on
> 3.0, it's rather likely that strong pressure will be applied to port
> *away* from Python into something less capricious.

Well, Python 2.4 code will work on Python 2.6 and 2.7 so just because
your code isn't yet compatible with Python 3.0 doesn't mean you should
give up on Python.

Python 2.2 was released in early 2003 and you said you'd be dropping
support for 2.2 in early 2008, so I conclude that since Python 2.5 was
released in late 2006, you'll be ready to drop Python 2.5 support (and
have 2.6/3.0 compatible code) by late 2011. Sure, it's a long way off,
but you're writing 2.2 compatible code *now*. Is it really that bad to
wait four years for Python 3.0?

STeVe


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jay Tee  
View profile  
 More options Feb 20 2007, 3:44 pm
Newsgroups: comp.lang.python
From: "Jay Tee" <jeff.temp...@gmail.com>
Date: 20 Feb 2007 12:44:53 -0800
Local: Tues, Feb 20 2007 3:44 pm
Subject: Re: Python 3.0 unfit for serious work?
Hi,

On Feb 20, 8:59 pm, Steven Bethard <steven.beth...@gmail.com> wrote:

> You snipped the rest of that comment:

> "It's not even clear yet that your average 2.6 code will work on 3.0 --
> though there's a pretty large contingent trying to make this true."

Thanks for pointing this out.  I voted for the comp.lang.python
newsgroup back in the early 90's, my active days of python
'development' are over, it's all i can do to hang on to the code i've
been posting about.

> have 2.6/3.0 compatible code) by late 2011. Sure, it's a long way off,
> but you're writing 2.2 compatible code *now*. Is it really that bad to
> wait four years for Python 3.0?

As long as when python 3.0 shows up, i don't have to do a massive
rewrite.  I think I've really only had to change two or three things
over the years .. one was that I used to use words like "dict" and
"list" in my code, which broke in subtle ways when d = dict() became
legal.

I just dug out some code laying around on disk from 1994, and ran it,
unchanged, under python 2.3.5. If I can achieve this (running 2007
code under python3.0 in 2011 with no modifications), that'd be OK.

    JT


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
BJörn Lindqvist  
View profile  
 More options Feb 20 2007, 3:47 pm
Newsgroups: comp.lang.python
From: "BJörn Lindqvist" <bjou...@gmail.com>
Date: Tue, 20 Feb 2007 21:47:57 +0100
Local: Tues, Feb 20 2007 3:47 pm
Subject: Re: Python 3.0 unfit for serious work?
What a load of bull crap. Python is one of the simplest packages to
have multiple version of installed. When Python 3.0 is released, all
Linux distros will acquire a symlink at /usr/bin/python2 pointing to
the latest Python 2.x version installed. Or something equivalent.
Rest assured that Linux distributors will not drop Python 2.x support
in the nearest decade. They are not stupid.

On 20 Feb 2007 08:49:10 -0800, Jay Tee <jeff.temp...@gmail.com> wrote:

--
mvh Björn

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Paul Boddie  
View profile  
 More options Feb 20 2007, 3:56 pm
Newsgroups: comp.lang.python
From: "Paul Boddie" <p...@boddie.org.uk>
Date: 20 Feb 2007 12:56:13 -0800
Local: Tues, Feb 20 2007 3:56 pm
Subject: Re: Python 3.0 unfit for serious work?

Steven Bethard wrote:

> Well, Python 2.4 code will work on Python 2.6 and 2.7 so just because
> your code isn't yet compatible with Python 3.0 doesn't mean you should
> give up on Python.

Perhaps the most important concern in the context of Python 3.0 is
what the term "Python" will come to mean to the different communities
using the language. Some people will be maintaining software that
needs to be compatible with older releases; these people aren't
technologically backwards: they just find that such older releases
provide sufficient capabilities for the implementation of their
solutions. For such people, "Python" will be the language they've
always used, with a gradual accumulation of features, some known
quirks, and some relatively minor incompatibility issues over the
years.

Meanwhile, the risk is that the core developers will only consider
Python 3.0 as "Python" and that people doing anything with older
releases will be on their own. If the gap is too wide between 2.x and
3.x, any lack of maintenance in the 2.x series will be perceived as an
abandonment of "Python" for certain kinds of user, and the result will
probably be a loss of confidence in both variants of the language.
Although I believe that some of the recent attempts to lower the
disruptiveness of Python 3.0 may have helped to maintain "Python" as a
single narrow continuum, I think some people overlook how fortunate
the relationship between Python's evolution and momentum has been, and
how easily such a relationship can be broken.

Paul


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jeff Templon  
View profile  
 More options Feb 20 2007, 4:04 pm
Newsgroups: comp.lang.python
From: "Jeff Templon" <jeff.temp...@gmail.com>
Date: Tue, 20 Feb 2007 22:04:44 +0100
Local: Tues, Feb 20 2007 4:04 pm
Subject: Re: Python 3.0 unfit for serious work?
yo,

Bjorn, I am not sure I see why my post is bull crap.  I think all you
are doing is agreeing with me.  My post was entitled "Python 3.0 unfit
for serious work", you just indicated that the Linux distros will
agree with me, in order to be taken seriously, the distros will have
to include 2.x python for a very long time.  If 3.0 and 2.x have any
serious degree of incompatibility, python will be a favorite subject
for religious rants and heated arguments for many people.  And if we
don't manage to restrain our developers from using features that force
us prematurely to move to 3.0 ... and don't underestimate what this
means, because this means other things will have to move as well,
which may have dependencies on yet other things like C++ library
versions ... then I would have to, for reasons of maintainability,
argue against continuing to allow python code development in the
project.  I love python, but not enough to make 20+ people's lives
difficult.

There are already people making this sort of argument in our project.

                       JT

On 2/20/07, BJörn Lindqvist <bjou...@gmail.com> wrote:


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jay Tee  
View profile  
 More options Feb 20 2007, 4:53 pm
Newsgroups: comp.lang.python
From: "Jay Tee" <jeff.temp...@gmail.com>
Date: 20 Feb 2007 13:53:07 -0800
Local: Tues, Feb 20 2007 4:53 pm
Subject: Re: Python 3.0 unfit for serious work?
Hi,

Paul, thanks for this, I didn't realize the scope of the situation.  I
agree with your assessment to the extent that I understand what the
whole python 3.0 thing is about.

Let's see if I can scare up something I wrote about ten years ago on a
now-dead language that I really wanted to use (wound up sticking with
python instead because "it was supported" ;-)

=======================
to figure out how to work things.  The fact that there are three (or
four depending if you count Linz V4) different Oberon System
implementations, and several different compilers, and even four or
five separate dialects of Oberon with none of them appearing to be
really "official", gives the impression of a fragmented, directionless
development effort, and a probability bordering on 1.0000 that
whatever you try to do will be incompatible with all but a small
subset of what's available (unless you stick to writing small programs
like in the books.)  It does not matter if you tell people that this
is not so; something has to clearly stand out as being THE STANDARD
STUFF and all the other stuff as INTERESTING BUT NONTHREATENING SIDE
PROJECTS.  The STANDARD STUFF must include a sufficient number of
=========================

Oberon is really really cool, seriously, ... but nobody is using it.
People working on python development are of course free to do what
they want, but so are the users ...

           J "actie-reactie is what my ex-brother-in-law would say" T


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Steven Bethard  
View profile  
 More options Feb 20 2007, 5:09 pm
Newsgroups: comp.lang.python
From: Steven Bethard <steven.beth...@gmail.com>
Date: Tue, 20 Feb 2007 15:09:53 -0700
Local: Tues, Feb 20 2007 5:09 pm
Subject: Re: Python 3.0 unfit for serious work?

Well, the problem of multiple standards shouldn't really apply in the
same way to Python. Right now, Python 2.X is the standard. Python 2.6,
2.7 and any later 2.X versions are intended to be transitional versions
while the standard is migrating to Python 3.X. At some point, the 2.X
line will almost certainly be discontinued.

So as a Python programmer, the path is clear. As soon as possible, you
should make your code compatible with Python 3.0. That will likely mean
taking advantage of some new features in Python 2.6, so "as soon as
possible" may still mean many years for projects that need to support
older versions of Python. Still, once Python 2.6 is installed everywhere
by default, it shouldn't be difficult to start making code compatible
with the new standard, Python 3.0.

STeVe


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Paul Boddie  
View profile  
 More options Feb 20 2007, 5:13 pm
Newsgroups: comp.lang.python
From: "Paul Boddie" <p...@boddie.org.uk>
Date: 20 Feb 2007 14:13:16 -0800
Local: Tues, Feb 20 2007 5:13 pm
Subject: Re: Python 3.0 unfit for serious work?

Jay Tee wrote:

> Paul, thanks for this, I didn't realize the scope of the situation.  I
> agree with your assessment to the extent that I understand what the
> whole python 3.0 thing is about.

I don't know if I've delimited the scope of any situation, really.
However...

[...]

> The fact that there are three (or
> four depending if you count Linz V4) different Oberon System
> implementations, and several different compilers, and even four or
> five separate dialects of Oberon with none of them appearing to be
> really "official",

[...]

The fortunate thing about different Python implementations and in
contrast to a lot of other languages and their implementations is that
the most actively developed Python implementation, CPython, is very
portable and is present on all major operating systems of consequence
(capable of running it). Other languages have suffered because there'd
be a UNIX version and then a version for Windows or the Mac which
wasn't as well maintained, or perhaps no version at all for one or
more of these platforms. So with Python, even if one implementation is
lagging behind (eg. Jython) there's still likely to be some deployment
solution on one's operating system of choice, given some level of
flexibility.

Where incompatibilities may arise with Python implementations is in
the level of support for recent language developments and additions.
Again, CPython's portability prevents this from becoming an operating
system issue, but we see rifts between implementations targeting
different runtime platforms, and whilst CPython 2.x and CPython 3.x
may continue to cover similar operating systems (although a desire to
drop support for various operating systems was stated), it's the rift
between them that presents the risk to any common notion of what
Python actually is.

Paul


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
BJörn Lindqvist  
View profile  
 More options Feb 20 2007, 7:41 pm
Newsgroups: comp.lang.python
From: "BJörn Lindqvist" <bjou...@gmail.com>
Date: Wed, 21 Feb 2007 01:41:01 +0100
Local: Tues, Feb 20 2007 7:41 pm
Subject: Re: Python 3.0 unfit for serious work?
On 2/20/07, Jeff Templon <jeff.temp...@gmail.com> wrote:

This is why I said that your post was a load of bull crap:

"Then Python is pretty much determined to remove itself from
consideration from various kinds of international projects like the
one I work on [unless py3k is backwards compatible with python 2.x]."

You did not explain why this is so.

"if 2.4 code doesn't run on 3.0, it's rather likely that strong
pressure will be applied to port *away* from Python into something
less capricious."

Who are these people that are applying the strong pressure? How can
you run a international and seemingly very important project without
knowing basic things about how to handle versioning problems?

I mean, they would rather port this big system, deployed on thousands
of computers all over the world, to an entirely different programming
language than to continue using Python 2.x because Python 3.x, when it
is released, MIGHT cause them some problems several YEARS from now?

--
mvh Björn


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
John Nagle  
View profile  
 More options Feb 20 2007, 8:59 pm
Newsgroups: comp.lang.python
From: John Nagle <na...@animats.com>
Date: Wed, 21 Feb 2007 01:59:36 GMT
Local: Tues, Feb 20 2007 8:59 pm
Subject: Re: Python 3.0 unfit for serious work?

Steven Bethard wrote:
> So as a Python programmer, the path is clear. As soon as possible, you
> should make your code compatible with Python 3.0.

     There's always the possiblity that Python 3 won't happen.  Look at
what happened with Perl 6.  That's been talked about for
seven years now.  The user base just wasn't interested.
Perl 5 was good enough, and users migrated to PHP for the
little stuff and other languages for the bigger stuff.
As Wikipedia says, "As of 2007, Perl 6 was still under development,
with no planned completion date."

                                John Nagle


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Paul Rubin  
View profile  
 More options Feb 20 2007, 9:14 pm
Newsgroups: comp.lang.python
From: Paul Rubin <http://phr...@NOSPAM.invalid>
Date: 20 Feb 2007 18:14:56 -0800
Local: Tues, Feb 20 2007 9:14 pm
Subject: Re: Python 3.0 unfit for serious work?

John Nagle <na...@animats.com> writes:
>      There's always the possiblity that Python 3 won't happen.  Look at
> what happened with Perl 6.  That's been talked about for
> seven years now.  The user base just wasn't interested.
> Perl 5 was good enough, and users migrated to PHP for the
> little stuff and other languages for the bigger stuff.
> As Wikipedia says, "As of 2007, Perl 6 was still under development,
> with no planned completion date."

I like to think PyPy will replace CPython as the main Python
implementation.  Python 3.0 can then fork the language fairly
radically, like C++ vs C (ok, not so attractive an example) or Scheme
vs Lisp.  Both dialects would stay active.

It seems to me that the flavor of Python programming has changed
significantly over the past few releases.  That trend will likely
continue and even accelerate.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Steven Bethard  
View profile  
 More options Feb 20 2007, 10:02 pm
Newsgroups: comp.lang.python
From: Steven Bethard <steven.beth...@gmail.com>
Date: Tue, 20 Feb 2007 20:02:06 -0700
Local: Tues, Feb 20 2007 10:02 pm
Subject: Re: Python 3.0 unfit for serious work?
Steven Bethard wrote:

 > So as a Python programmer, the path is clear. As soon as possible, you
 > should make your code compatible with Python 3.0.

John Nagle wrote:
>     There's always the possiblity that Python 3 won't happen.

That's not really a possibility. Unlike Perl 6, Python 3 is not a new
language. And you can see Guido's release plan here:

     http://www.python.org/dev/peps/pep-3000/

In brief:

* An alpha in the first half of 2007
* First real release in the first half of 2008

STeVe


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
John Nagle  
View profile  
 More options Feb 21 2007, 12:19 am
Newsgroups: comp.lang.python
From: John Nagle <na...@animats.com>
Date: Tue, 20 Feb 2007 21:19:26 -0800
Local: Wed, Feb 21 2007 12:19 am
Subject: Re: Python 3.0 unfit for serious work?

Paul Rubin wrote:
> John Nagle <na...@animats.com> writes:

>>     There's always the possiblity that Python 3 won't happen.  Look at
>>what happened with Perl 6.  That's been talked about for
>>seven years now.  The user base just wasn't interested.
>>Perl 5 was good enough, and users migrated to PHP for the
>>little stuff and other languages for the bigger stuff.
>>As Wikipedia says, "As of 2007, Perl 6 was still under development,
>>with no planned completion date."

> I like to think PyPy will replace CPython as the main Python
> implementation.

     Well, something faster really should take over.  It's a bit
embarassing that the main implementation of Python is still a
pure interpreter.  Even Javascript has a JIT compiler now.
And it's tiny, under 1MB.

                                John Nagle


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
greg  
View profile  
 More options Feb 21 2007, 12:27 am
Newsgroups: comp.lang.python
From: greg <g...@cosc.canterbury.ac.nz>
Date: Wed, 21 Feb 2007 18:27:32 +1300
Local: Wed, Feb 21 2007 12:27 am
Subject: Re: Python 3.0 unfit for serious work?

John Nagle wrote:
> It's a bit
> embarassing that the main implementation of Python is still a
> pure interpreter.  Even Javascript has a JIT compiler now.

Pure interpreted Python has always seemed more responsive
to me than any Java application I've tried to use. So I
can't help feeling that this JIT business is over-hyped.

--
Greg


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jay Tee  
View profile  
 More options Feb 21 2007, 2:40 am
Newsgroups: comp.lang.python
From: "Jay Tee" <jeff.temp...@gmail.com>
Date: 20 Feb 2007 23:40:26 -0800
Local: Wed, Feb 21 2007 2:40 am
Subject: Re: Python 3.0 unfit for serious work?
On Feb 21, 1:41 am, "BJörn Lindqvist" <bjou...@gmail.com> wrote:

[ citing me ]

> "if 2.4 code doesn't run on 3.0, it's rather likely that strong
> pressure will be applied to port *away* from Python into something
> less capricious."

> Who are these people that are applying the strong pressure? How can
> you run a international and seemingly very important project without
> knowing basic things about how to handle versioning problems?

This isn't versioning.  At least not the way I see it.  Versioning has
to do with changes in your own product.  Indeed one needs to know how
to handle it.  Lately our project has been doing OK on this front, a
couple years ago was a different story.

Underlying technology is a different story.  This should be reasonably
stable.  Small changes are inevitable but even these are a major pain,
since we have dependency links like the following:

  OS release links to
  Python release which changes an
  Third-party extension module which requires
  A third party library whose
  Version needs to be upgraded but which
  Is used by some other non-python means that
  Requires the earlier version.

Or the earlier problem, an OS upgrade comes with a new python version
on which existing code breaks.

The fraction of code in our system that's written in python is
something like 10% -- it's not a big pure-python system.

Now you're talking about major changes in the underlying technology,
forcing, at some point in the future, an extensive rewrite of the
python code.  Yes, at that point, some people would make the comment
that a language which changes to that extent by major versions is not
fit for production work, and if one was going to have to rewrite, it
would be better to rewrite in a more stable language.

And finally, remember the original post I replied to said that python
3.0 was determined not to be hampered by backwards compatibility.
This is quite a bit different than what you say here ("MIGHT cause
problems"):

> language than to continue using Python 2.x because Python 3.x, when it
> is released, MIGHT cause them some problems several YEARS from now?

If backwards compatibility is not a consideration, then it would be a
miracle if there were no problems.

                            JT


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Steven D'Aprano  
View profile  
 More options Feb 21 2007, 3:21 am
Newsgroups: comp.lang.python
From: Steven D'Aprano <st...@REMOVEME.cybersource.com.au>
Date: Wed, 21 Feb 2007 19:21:54 +1100
Local: Wed, Feb 21 2007 3:21 am
Subject: Re: Python 3.0 unfit for serious work?

On Tue, 20 Feb 2007 21:19:26 -0800, John Nagle wrote:
>      Well, something faster really should take over.  It's a bit
> embarassing that the main implementation of Python is still a
> pure interpreter.  Even Javascript has a JIT compiler now.
> And it's tiny, under 1MB.

Python has a compiler, just like Java. That's where the .pyc files come
from.

You might also notice the built-in function "compile", which compiles text
strings into byte-code and puts it into a code object. The dis module may
also be of interest.

--
Steven D'Aprano


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Aahz  
View profile  
 More options Feb 21 2007, 1:44 pm
Newsgroups: comp.lang.python
From: a...@pythoncraft.com (Aahz)
Date: 21 Feb 2007 10:44:09 -0800
Local: Wed, Feb 21 2007 1:44 pm
Subject: Re: Python 3.0 unfit for serious work?
In article <1172043626.705209.14...@v45g2000cwv.googlegroups.com>,

Jay Tee <jeff.temp...@gmail.com> wrote:

>If backwards compatibility is not a consideration, then it would be a
>miracle if there were no problems.

Backwards compatibility is a consideration AND there will be problems.
That is, the goal of 3.0 is to lower the priority of backwards
compatibility enough to make some incompatible changes, but not to reduce
the priority of compatibility to zero.  Just for example, "foo" will
become a Unicode string.

Note that I believe it will be many years, perhaps even a decade, before
"python" on a Unix system starts up Python 3.0.  Python 2.x will have at
least two releases after 3.0 gets released, and I can't imagine that any
OS will have "python" refer to 3.0 while 2.x is still under active
development or even for a while after.  I'd expect any OS to provide a
python3.
--
Aahz (a...@pythoncraft.com)           <*>         http://www.pythoncraft.com/

"I disrespectfully agree."  --SJM


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
olso...@verizon.net  
View profile  
 More options Feb 21 2007, 2:06 pm
Newsgroups: comp.lang.python
From: olso...@verizon.net
Date: 21 Feb 2007 11:06:05 -0800
Local: Wed, Feb 21 2007 2:06 pm
Subject: Re: Python 3.0 unfit for serious work?
On Feb 20, 9:04 pm, "Jeff Templon" <jeff.temp...@gmail.com> wrote:

I don't know the specifics of your app, but why does everyone insist
that they need to use the 'system' python?

At least one commercial python app I work with installs it's own
completely independant version of python.  For many apps where
predictible behaviour is required you can install 'your' python,
under /opt/myapp or /usr/local/myapp or whatever instead of python,
python2.2, python3, etc.  The downside is that you'll waste another
15Mb harddrive space, and you'll need to update your internal source
tree 4 or 5 times when maintenance releases come out.

Apologies if this sounds like a rant, I really mean it in a
constructive way.

-Grant


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jay Tee  
View profile  
 More options Feb 21 2007, 3:59 pm
Newsgroups: comp.lang.python
From: "Jay Tee" <jeff.temp...@gmail.com>
Date: 21 Feb 2007 12:59:33 -0800
Local: Wed, Feb 21 2007 3:59 pm
Subject: Re: Python 3.0 unfit for serious work?
On Feb 21, 8:06 pm, olso...@verizon.net wrote:

> I don't know the specifics of your app, but why does everyone insist
> that they need to use the 'system' python?

Hey Grant, don't worry it's not a rant.  A completely valid question.
Again it's a problem of dependency management ... one of the things
we've had to deal with is one of the applications : they have a
framework largely built in python, and I think they were indeed at one
point shipping their own python because they used features not present
in the "system" python.

However, they did use the middleware installed on the system, and this
middleware is also partially written in python ... except it was
expecting the system python.  So you get into very tricky things
having to sanity check the PYTHONPATH, that the "user" python path is
not getting exported into middleware land, nor is the application's
desired PYTHONPATH being destroyed by middleware.  We had just such an
issue here last week, we had solved the problem for bourne shell
users, but csh for some reason had a different behavior, and the user
app could not longer find its python modules.

About the only code for which we don't seem to have these issues is
compiled C.  C++ is nasty because the compilers are still catching up
to the standard; the last I heard, a big segment of C++ code was stuck
because it was full of apparently illegal constructs that the previous
compiler (the g++ shipped stock with RHEL3) accepted, but the RHEL-4
native version refused to compile.

A colleague of mine pointed out today that this is an old problem, and
used to be handled by automake at compile time, with code full of
ifdefs ... now we've moved the problem to run time.  Which I think is
harder, because sometimes we don't find the problem until our binary
is halfway across the world ...

JT


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
sjdevnull@yahoo.com  
View profile  
 More options Feb 21 2007, 5:23 pm
Newsgroups: comp.lang.python
From: "sjdevn...@yahoo.com" <sjdevn...@yahoo.com>
Date: 21 Feb 2007 14:23:19 -0800
Local: Wed, Feb 21 2007 5:23 pm
Subject: Re: Python 3.0 unfit for serious work?
On Feb 21, 1:44 pm, a...@pythoncraft.com (Aahz) wrote:

> Note that I believe it will be many years, perhaps even a decade, before
> "python" on a Unix system starts up Python 3.0.

That's a pretty safe bet considering that the factory-installed
"python" on my Linux system is still 1.x and you run "python2" to get
2.x (I haven't done a new OS install in a couple of years, but 2.x had
been out for years when I did the install).  And 2.x is much less
likely to break 1.x code than 3.x will be to break 2.x code.

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Discussion subject changed to "Pep 3105: the end of print?" by Peter Mayne
Peter Mayne  
View profile  
 More options Feb 22 2007, 12:29 am
Newsgroups: comp.lang.python
From: Peter Mayne <Peter.Ma...@hp.com>
Date: Thu, 22 Feb 2007 16:29:17 +1100
Local: Thurs, Feb 22 2007 12:29 am
Subject: Re: Pep 3105: the end of print?

Steven D'Aprano wrote:
> On Tue, 20 Feb 2007 00:44:24 +0000, Peter mayne wrote:

>> Steven D'Aprano wrote:
>>> If Python 3 dropped the print
>>> statement and replaced it with official_print_function(), how would that
>>> help you in your goal to have a single code base that will run on both
>>> Python 2.3 and Python 3, while still using print?
>> Is there any reason why official_print_function isn't sys.stdout.write?

> Why would you want a convenience function like print to take one import,
> three look-ups and 16 characters instead of always available, one look-up
> and five characters?

Because it's compatible between Python 2.x and Python 3.x?  :-)
Because without print as a keyword, I can say "print = sys.stdout.write"
and still have (some) convenience? (Albeit still one import and one
lookup, though given the probable time taken to do the I/O, why worry
about the lookup?) Or, if your editor has an abbreviation facility like
Eclipse, you can type sys.stdout.write with less than 5 keystrokes.

>> I can't remember the last time I used print in actual code (apart from
>> short-lived debugging lines), so I'm bewildered as to why print seems to
>> be so important.

> print is important for the convenience, for short-lived debugging, and for
> use in the interactive interpreter.

Why use print in the interactive interpreter? Just type the expression.

Hmm, I was expecting that that wouldn't always work, but:

 >>> x=3
 >>> if x==3: x
...
3
 >>> for i in range(x):
...   i
...
0
1
2

PJDM


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Messages 51 - 75 of 85 < Older  Newer >
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google