News for hackers. Stuff that matters.
Re:Python 2.7.4 Released by masklinn on Sunday April 07, 2013 @04:55AM (#5506566)
In 2.7.3, you can create a buffer which is the "old" buffer interface: http://docs.python.org/2/library/functions.html#buffer

And you can create a memoryview which is the "new" and more flexible buffer interface: http://docs.python.org/2/library/stdtypes.html#typememoryvie...

You can get a buffer of a string:

    >>> buffer("foo")
    <read-only buffer for 0x1005a5ee0, size -1, offset 0 at 0x10054f270>
and a view of a string:

    >>> memoryview("foo")
    <memory at 0x100574d60>
but when you get this unhelpful and really stupid result:

    >>> memoryview(buffer("foo"))
    Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
    TypeError: cannot make memory view because object does not have the buffer interface
2.7.4 fixed this so it actually works and you can get a memoryview out of an old buffer.
Re:Python 2.7.4 Released by cbsmith on Sunday April 07, 2013 @11:40PM (#5509882)
Awesome, that was precisely the kind of annoyance I remember.