Re: [Python-Dev] libpython added to ABI tracker

2014-04-03 Thread Nick Coghlan
On 3 April 2014 00:18, Andrey Ponomarenko  wrote:
>
> Nick Coghlan wrote:
>>
>> Regarding the warnings for this one - is there a way for the checker
>> to warn if data structures are exposed directly, rather than as opaque
>> types? It's fine if there isn't, it would just be cool if there was -
>> one of the premises of the stable ABI is that it *doesn't* expose the
>> type definitions directly to consuming code, just the pointers to them
>> (hence allowing the struct size to change without actually breaking
>> compatibility with the defined ABI).
>
>
> The ABI of the library can be dumped by the abi-compliance-checker basic
> tool to a text file in the human readable format, so anyone can analyse it
> in order to find problems of any kind.

Thanks! I've now filed http://bugs.python.org/issue21142 as an RFE -
I'll definitely be looking into setting up a regular run of this to
help us avoid any new issues with managing the evolution of the stable
ABI (and the public ABI in general).

Cheers,
Nick.



-- 
Nick Coghlan   |   [email protected]   |   Brisbane, Australia
___
Python-Dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


[Python-Dev] Python 4?

2014-04-03 Thread Skip Montanaro
I saw mention recently of Python 4 and assumed all such references
were either April Fool's jokes or pie-in-the-sky dreams for a new
version of Python which may never arrive.

Then I saw this message to webmaster. I would have guessed he meant
3.4 except he mentions having a Python3 (well, actually, a Phython3)
directory.

WTH is Python 4?

Skip

-- Forwarded message --
From: C. Reese 
Date: Thu, Apr 3, 2014 at 8:03 AM
Subject: Updated phython
To: [email protected]


just updated to Python 4.  (installed to C: drive) ... now i notice
there are separate Python2 & Python3 directories as well.  i am not a
programmer in any sense (just a basic computer user).

1. do i need to have python on my computer at all for basic use?
(word, excel, power point, etc.)'
2. can i safely remove the Python 2 & Phython3 directories? (to save
hard disk space)

thanks
CR
___
Python-Dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Python 4?

2014-04-03 Thread Brett Cannon
On Thu, Apr 3, 2014 at 9:51 AM, Skip Montanaro  wrote:

> I saw mention recently of Python 4 and assumed all such references
> were either April Fool's jokes or pie-in-the-sky dreams for a new
> version of Python which may never arrive.
>

It's the latter. Some of us have been tossing around "Python 4" like we did
"Py3k" before we starting Python 3 in earnest; maybe we should make sure to
say Py4k to be perfectly clear there are no Python 4 plans ATM.


>
> Then I saw this message to webmaster. I would have guessed he meant
> 3.4 except he mentions having a Python3 (well, actually, a Phython3)
> directory.
>
> WTH is Python 4?
>

Who the heck knows what the person specifically means, although it sounds
like he did mean Python 3.4 which would explain why he know has a Python3
directory.

-Brett


> Skip
>
> -- Forwarded message --
> From: C. Reese 
> Date: Thu, Apr 3, 2014 at 8:03 AM
> Subject: Updated phython
> To: [email protected]
>
>
> just updated to Python 4.  (installed to C: drive) ... now i notice
> there are separate Python2 & Python3 directories as well.  i am not a
> programmer in any sense (just a basic computer user).
>
> 1. do i need to have python on my computer at all for basic use?
> (word, excel, power point, etc.)'
> 2. can i safely remove the Python 2 & Phython3 directories? (to save
> hard disk space)
>
> thanks
> CR
> ___
> Python-Dev mailing list
> [email protected]
> https://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe:
> https://mail.python.org/mailman/options/python-dev/brett%40python.org
>
___
Python-Dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Python 4?

2014-04-03 Thread Skip Montanaro
On Thu, Apr 3, 2014 at 8:59 AM, Brett Cannon  wrote:
>
> Who the heck knows what the person specifically means, although it sounds 
> like he did mean Python 3.4 which would explain why he know has a Python3 
> directory.

Thanks. I'll try and see what he really has. I was worried that an
April Fool's prank went so far as to put a tarted up version of Python
3.x out in the wild where unsuspecting folks would find and install
it.

Skip
___
Python-Dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Python 4?

2014-04-03 Thread Chris Angelico
On Fri, Apr 4, 2014 at 1:02 AM, Skip Montanaro  wrote:
> On Thu, Apr 3, 2014 at 8:59 AM, Brett Cannon  wrote:
>>
>> Who the heck knows what the person specifically means, although it sounds 
>> like he did mean Python 3.4 which would explain why he know has a Python3 
>> directory.
>
> Thanks. I'll try and see what he really has. I was worried that an
> April Fool's prank went so far as to put a tarted up version of Python
> 3.x out in the wild where unsuspecting folks would find and install
> it.
>

I doubt it, from the sound of the rest of the email. Two likely
possibilities: One, he actually just meant "Python 3" and typo'd it;
two, he's abbreviating the version numbers in Java style - Python 2 =
3.2, Python 3 = 3.3, and he now has a Python 4 = 3.4.

Either way, I'd advise him to post to python-list, where people will
be happy to help out. Exact path names would help.

ChrisA
___
Python-Dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Python 4?

2014-04-03 Thread R. David Murray
On Thu, 03 Apr 2014 09:59:55 -0400, Brett Cannon  wrote:
> On Thu, Apr 3, 2014 at 9:51 AM, Skip Montanaro  wrote:
> 
> > I saw mention recently of Python 4 and assumed all such references
> > were either April Fool's jokes or pie-in-the-sky dreams for a new
> > version of Python which may never arrive.
> >
> 
> It's the latter. Some of us have been tossing around "Python 4" like we did
> "Py3k" before we starting Python 3 in earnest; maybe we should make sure to
> say Py4k to be perfectly clear there are no Python 4 plans ATM.

I think Python4 is just what follows python 3.9, myself :).

More seriously, I don't believe there should ever be a Py4k the way there
was a Py3k, and would prefer not to feed any rumours that there might be.

--David
___
Python-Dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Python 4?

2014-04-03 Thread Tres Seaver
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 04/03/2014 10:36 AM, R. David Murray wrote:

> More seriously, I don't believe there should ever be a Py4k the way
> there was a Py3k, and would prefer not to feed any rumours that there
> might be.

Amen!


Tres.
- -- 
===
Tres Seaver  +1 540-429-0999  [email protected]
Palladion Software   "Excellence by Design"http://palladion.com
-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iEYEARECAAYFAlM9dDoACgkQ+gerLs4ltQ6ikACgrneAqvKimcm64/AKCbFmp4pn
zEoAoK0q6nFXDDRL+UY3zI/PPFDvr3cg
=gTu1
-END PGP SIGNATURE-

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


Re: [Python-Dev] libpython added to ABI tracker

2014-04-03 Thread Andrey Ponomarenko

Nick Coghlan wrote:

On 3 April 2014 00:18, Andrey Ponomarenko  wrote:

Nick Coghlan wrote:

Regarding the warnings for this one - is there a way for the checker
to warn if data structures are exposed directly, rather than as opaque
types? It's fine if there isn't, it would just be cool if there was -
one of the premises of the stable ABI is that it *doesn't* expose the
type definitions directly to consuming code, just the pointers to them
(hence allowing the struct size to change without actually breaking
compatibility with the defined ABI).


The ABI of the library can be dumped by the abi-compliance-checker basic
tool to a text file in the human readable format, so anyone can analyse it
in order to find problems of any kind.

Thanks! I've now filed http://bugs.python.org/issue21142 as an RFE -
I'll definitely be looking into setting up a regular run of this to
help us avoid any new issues with managing the evolution of the stable
ABI (and the public ABI in general).


I wrote some instructions on how to setup local ABI checker in the 
comment to issue 21142.


The main idea is to create ABI dump of the reference libpython version 
(say, 3.2) and compare it with the ABI dump of the current version. The 
ABI dump of the reference version can be stored somewhere in the source 
tree.


Thanks.

--
Andrey Ponomarenko, NTC IT ROSA.

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


[Python-Dev] Incorrect behavior in str.format() method when padding with '\x00'

2014-04-03 Thread John Tyree
Hi all,

Is there any particularly reason for the following behavior on both 2.7.6
and 3.4.0 ?

>>> "{:\x00<5}".format(2)
> '2'
> >>>
> "{:\x20<5}".format(2)
>
> '2'
> >>>
> "{:\x01<5}".format(2)
>
> '2\x01\x01\x01\x01'
> >>> "{:\x00<5}".format(2) ==
> "{:\x20<5}".format(2)
>
> True
>

The docs say "If a valid *align* value is specified, it can be preceded by
a *fill* character that can be any character and defaults to a space if
omitted," so I'm inclined to call this a good old fashioned bug.

-- 
John Tyree
Scientific Software Developer
Enthought, Inc.
www.enthought.com
___
Python-Dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Incorrect behavior in str.format() method when padding with '\x00'

2014-04-03 Thread Eric V. Smith
On 04/02/2014 04:08 PM, John Tyree wrote:
> 
> Hi all,
> 
> Is there any particularly reason for the following behavior on both
> 2.7.6 and 3.4.0 ?
> 
> >>> "{:\x00<5}".format(2)
> '2'
> >>>
> "{:\x20<5}".format(2) 
>
> 
> '2'
> >>>
> "{:\x01<5}".format(2) 
>
> 
> '2\x01\x01\x01\x01'
> >>> "{:\x00<5}".format(2) ==
> "{:\x20<5}".format(2) 
>   
> 
> True
> 
> 
> The docs say "If a valid /align/ value is specified, it can be preceded
> by a /fill/ character that can be any character and defaults to a space
> if omitted," so I'm inclined to call this a good old fashioned bug.

I'd say it's a bug. Please open a bug, assign it to me (eric.smith), and
I'll comment on it there.

Eric.


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


Re: [Python-Dev] Incorrect behavior in str.format() method when padding with '\x00'

2014-04-03 Thread R. David Murray
On Thu, 03 Apr 2014 11:20:20 -0400, "Eric V. Smith"  wrote:
> On 04/02/2014 04:08 PM, John Tyree wrote:
> > 
> > Hi all,
> > 
> > Is there any particularly reason for the following behavior on both
> > 2.7.6 and 3.4.0 ?
> > 
> > >>> "{:\x00<5}".format(2)
> > '2'
> > >>>
> > "{:\x20<5}".format(2)   
> >  
> > 
> > '2'
> > >>>
> > "{:\x01<5}".format(2)   
> >  
> > 
> > '2\x01\x01\x01\x01'
> > >>> "{:\x00<5}".format(2) ==
> > "{:\x20<5}".format(2)   
> > 
> > 
> > True
> > 
> > 
> > The docs say "If a valid /align/ value is specified, it can be preceded
> > by a /fill/ character that can be any character and defaults to a space
> > if omitted," so I'm inclined to call this a good old fashioned bug.
> 
> I'd say it's a bug. Please open a bug, assign it to me (eric.smith), and
> I'll comment on it there.

There is an existing bug report (assigned to you :), with a partial patch:
http://bugs.python.org/issue12546

--David
___
Python-Dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Incorrect behavior in str.format() method when padding with '\x00'

2014-04-03 Thread MRAB

On 2014-04-03 16:20, Eric V. Smith wrote:

On 04/02/2014 04:08 PM, John Tyree wrote:


Hi all,

Is there any particularly reason for the following behavior on both
2.7.6 and 3.4.0 ?

>>> "{:\x00<5}".format(2)
'2'
>>>
"{:\x20<5}".format(2)

'2'
>>>
"{:\x01<5}".format(2)

'2\x01\x01\x01\x01'
>>> "{:\x00<5}".format(2) ==
"{:\x20<5}".format(2)

True


The docs say "If a valid /align/ value is specified, it can be preceded
by a /fill/ character that can be any character and defaults to a space
if omitted," so I'm inclined to call this a good old fashioned bug.


I'd say it's a bug. Please open a bug, assign it to me (eric.smith), and
I'll comment on it there.


I'd agree. It looks like '\x00' is being confused with a NUL terminator
in the C code. I've seen such a thing before (now fixed).
___
Python-Dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Incorrect behavior in str.format() method when padding with '\x00'

2014-04-03 Thread Eric V. Smith
On 04/03/2014 11:37 AM, R. David Murray wrote:
> On Thu, 03 Apr 2014 11:20:20 -0400, "Eric V. Smith"  
> wrote:
>> On 04/02/2014 04:08 PM, John Tyree wrote:
>>>
>>> Hi all,
>>>
>>> Is there any particularly reason for the following behavior on both
>>> 2.7.6 and 3.4.0 ?
>>>
>>> >>> "{:\x00<5}".format(2)
>>> '2'
>>> >>>
>>> "{:\x20<5}".format(2)   
>>>  
>>>
>>> '2'
>>> >>>
>>> "{:\x01<5}".format(2)   
>>>  
>>>
>>> '2\x01\x01\x01\x01'
>>> >>> "{:\x00<5}".format(2) ==
>>> "{:\x20<5}".format(2)   
>>> 
>>>
>>> True
>>>
>>>
>>> The docs say "If a valid /align/ value is specified, it can be preceded
>>> by a /fill/ character that can be any character and defaults to a space
>>> if omitted," so I'm inclined to call this a good old fashioned bug.
>>
>> I'd say it's a bug. Please open a bug, assign it to me (eric.smith), and
>> I'll comment on it there.
> 
> There is an existing bug report (assigned to you :), with a partial patch:
> http://bugs.python.org/issue12546

Heh. I'll add this to my list of things to do at PyCon sprints.

Eric.


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


Re: [Python-Dev] Incorrect behavior in str.format() method when padding with '\x00'

2014-04-03 Thread Eric V. Smith
On 04/03/2014 11:49 AM, MRAB wrote:
> On 2014-04-03 16:20, Eric V. Smith wrote:
>> On 04/02/2014 04:08 PM, John Tyree wrote:
>>>
>>> Hi all,
>>>
>>> Is there any particularly reason for the following behavior on both
>>> 2.7.6 and 3.4.0 ?
>>>
>>> >>> "{:\x00<5}".format(2)
>>> '2'
>>> >>>
>>> "{:\x20<5}".format(2)
>>>
>>> '2'
>>> >>>
>>> "{:\x01<5}".format(2)
>>>
>>> '2\x01\x01\x01\x01'
>>> >>> "{:\x00<5}".format(2) ==
>>> "{:\x20<5}".format(2)
>>>
>>> True
>>>
>>>
>>> The docs say "If a valid /align/ value is specified, it can be preceded
>>> by a /fill/ character that can be any character and defaults to a space
>>> if omitted," so I'm inclined to call this a good old fashioned bug.
>>
>> I'd say it's a bug. Please open a bug, assign it to me (eric.smith), and
>> I'll comment on it there.
>>
> I'd agree. It looks like '\x00' is being confused with a NUL terminator
> in the C code. I've seen such a thing before (now fixed).

Now that I recall the other issue (that I should have fixed already, but
let drop), it's because 0 is used as a flag to mean "use the default".

Eric.


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


Re: [Python-Dev] Gmane not functioning.

2014-04-03 Thread Terry Reedy

It is again now.

--
Terry Jan Reedy

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


[Python-Dev] Pyston: a Python JIT on LLVM

2014-04-03 Thread Kevin Modzelewski
Hi all,

I'm excited to announce Pyston, a Python JIT under development at Dropbox,
built on top of LLVM.  You can read more about it at the introductory blog
post,
or check out the code on github .

Since it's the question that I think most people will inevitably (and
rightly) ask, why do we think there's a place for Pyston when there's PyPy
and (previously) Unladen Swallow?

Compared to PyPy, Pyston makes a number of different technical choices,
such as using a method-at-a-time JIT vs PyPy's tracing JIT.  The
method-at-a-time approach seems to be being validated in the JavaScript
world, so there's reason to think there might be room to improve over PyPy,
though their extremely impressive performance makes that an admittedly
very, very high bar.  We also think that extension module support is a
first-class issue and have some ideas on how to try to make that fast.

As for Unladen Swallow, there are some reasons to think that LLVM has
matured greatly in the past few years, particularly in the JIT engine which
has been completely replaced.  I'm not sure if that's the only part to the
story; I'd be interested in talking with any of the people who were
involved or knowledgeable about the project.


It's definitely a very tall order to try to stand out among the existing
implementations, but in time we think we can do it.

I'll be at the language summit and PyCon sprints, and hope to see some of
you there!

kmod
___
Python-Dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Pyston: a Python JIT on LLVM

2014-04-03 Thread Sturla Molden
Kevin Modzelewski  wrote:

> Since it's the question that I think most people will inevitably (and
> rightly) ask, why do we think there's a place for Pyston when there's PyPy
> and (previously) Unladen Swallow?

Have you seen Numba, the Python JIT that integrates with NumPy?

http://numba.pydata.org

It uses LLVM to compile Python bytecode. When I have tried it I tend to get
speed comparable to -O2 in C for numerical and algorithmic code.

Here is an example, giving a 150 times speed boost to Python:

http://stackoverflow.com/questions/21811381/how-to-shove-this-loop-into-numpy/21818591#21818591


Sturla

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


Re: [Python-Dev] Python 4?

2014-04-03 Thread Emile van Sebille

On 4/3/2014 7:46 AM, Tres Seaver wrote:

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On 04/03/2014 10:36 AM, R. David Murray wrote:


More seriously, I don't believe there should ever be a Py4k the way
there was a Py3k, and would prefer not to feed any rumours that there
might be.


Amen!


+1

Can't we just refer to PySky and leave it at that?

:)

Emile



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


Re: [Python-Dev] Python 4?

2014-04-03 Thread Glenn Linderman

On 4/3/2014 4:02 PM, Emile van Sebille wrote:


Can't we just refer to PySky and leave it at that? 


Hey! That's an excellent idea! And it avoids the version number 
prediction/expectation too.
___
Python-Dev mailing list
[email protected]
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com