Re: [Python-Dev] PyCon 2009 Call for Proposals

2008-09-27 Thread Tarek Ziadé
On Sat, Sep 27, 2008 at 7:02 AM, Brett Cannon <[EMAIL PROTECTED]> wrote:

> On Fri, Sep 26, 2008 at 7:37 PM, Benjamin Peterson
> <[EMAIL PROTECTED]> wrote:
> > On Fri, Sep 26, 2008 at 9:36 PM, Brett Cannon <[EMAIL PROTECTED]> wrote:
> >> On Fri, Sep 26, 2008 at 4:25 PM, Aahz <[EMAIL PROTECTED]> wrote:
> >>> Call for proposals -- PyCon 2009 -- 
> >>> ===
> >>>
> >>> Want to share your experience and expertise? PyCon 2009 is looking for
> >>> proposals to fill the formal presentation tracks. The PyCon conference
> >>> days will be March 27-29, 2009 in Chicago, Illinois, preceded by the
> >>> tutorial days (March 25-26), and followed by four days of development
> >>> sprints (March 30-April 2).
> >>>
> >>
> >> I am thinking of organizing a panel this year for python-dev (much
> >> like the one I organized in 2007). Who would be willing to be on the
> >> panel with me if I did this?
> >
> > Could you explain what this is to us a little more, please? :)
> >
>
> You sit in front of a bunch of people answering questions asked by the
> audience. You know, a panel. =) It's just a Q&A session so that PyCon
> attendees can ask python-dev a bunch of random questions. Demystifies
> some things and puts faces to python-dev.


>From a non-core developer point of view:

What could be great imho would be to have a short "How Python is developed"
presentation
just before the panel starts.

Tarek

-- 
Tarek Ziadé | Association AfPy | www.afpy.org
Blog FR | http://programmation-python.org
Blog EN | http://tarekziade.wordpress.com/
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


[Python-Dev] Filename as byte string in python 2.6 or 3.0?

2008-09-27 Thread Victor Stinner
Hi,

I read that Python 2.6 is planned to Wednesday. One bug is is still open and 
important for me: Python 2.6/3.0 are unable to use filename as byte strings.
http://bugs.python.org/issue3187

The problem
===

On Windows, all filenames are unicode strings (I guess UTF-16-LE), but on UNIX 
for historical reasons, filenames are byte strings. On Linux, you can expect 
UTF-8 valid filenames but sometimes (eg. copy from a FAT32 USB key to an ext3 
filesystem) you get invalid filename (byte string in a different charset than 
your default filesystem encoding (utf8)).


Python functions using filenames


In Python, you have (incomplete list):
 - filename producer: os.listdir(), os.walk(), glob.glob()
 - filename manipulation: os.path.*()
 - access file: open(), os.unlink(), shutil.rmtree()

If you give unicode to producer, they return unicode _or_ byte strings (type 
may change for each filename :-/). Guido proposed to break this behaviour: 
raise an exception if unicode conversion fails. We may consider an option 
like "skip invalid".

If you give bytes to producer, they only return byte strings. Great.

Filename manipulation: in python 2.6/3.0, os.path.*() is not compatible with 
the type "bytes". So you can not use os.path.join(, ) *nor* os.path.join(, ) because 
os.path.join() (eg. with the posix version) uses path.endswith('/').

Access file: open() rejects the type bytes (it's just a test, open() supports 
bytes if you remove the test). As I remember, unlink() is compatible with 
bytes. But rmtree() fails because it uses os.path.join() (even if you give 
bytes directory, join() fails).


Solutions
=

 - producer: unicode => *only* unicode // bytes => bytes
 - manipulation: support both unicode and bytes but avoid (when it's possible)
   to mix bytes and characters
 - open(): allow bytes

I implemented these solutions as a patch set attached to the issue #3187:
 * posix_path_bytes.patch: fix posixpath.join() to support bytes
 * io_byte_filename.patch: open() allows bytes filename
 * fnmatch_bytes.patch: patch fnmatch.filter() to accept bytes filenames
 * glob1_bytes.patch: fix glob.glob() to accept invalid directory name

Mmmh, there is no patch for stop os.listdir() on invalid filename.


Priority


I think that the problem is important because it's a regression from 2.5 to 
2.6/3.0. Python 2.5 uses bytes filename, so it was possible to 
open/unlink "invalid" unicode strings (since it's not unicode but bytes).

Well, if it's too late for the final versions, this problem should be at least 
fixed quickly.


Test the problem


Example to create invalid filenames on Linux:

$ mkdir /tmp/test
$ cd /tmp/test
$ touch $(echo -e "a\xffb")
$ mkdir $(echo -e "dir\xffname")
$ touch $(echo -e "dir\xffname/file")
$ find
.
./a?b
./dir?name
./dir?name/file

Python 2.5:
>>> import os
>>> os.listdir('.')
['a\xffb', 'dir\xffname']
>>> open(os.listdir('.')[0]).close()  # open file: ok
>>> os.unlink(os.listdir('.')[0]) # remove file: ok
>>> os.listdir('.')
['dir\xffname']
>>> shutil.rmtree(os.listdir('.')[0])  # remove dir: ok


Wrong solutions
===

New type


I proposed an ugly type "InvalidFilename" mixing bytes and characters. As 
everybody using unicode knows, it's a bad idea :-) (and it introduces a new 
type).

Convert bytes to unicode (replace)
--

unicode_filename = unicode(bytes_filename, charset, "replace")

Ok, you will get valid unicode strings which can be used in os.path.join() & 
friends, but open() or unlink() will fails because this filename doesn't 
exist!

-- 
Victor Stinner aka haypo
http://www.haypocalc.com/blog/
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] PyCon 2009 Call for Proposals

2008-09-27 Thread Eric Smith

Brett Cannon wrote:

I am thinking of organizing a panel this year for python-dev (much
like the one I organized in 2007). Who would be willing to be on the
panel with me if I did this?


If you're looking for the perspective of someone who's relatively new to 
Python core programming, I'll do it. You won't offend me by picking 
someone else, though.


Eric.

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


Re: [Python-Dev] PyCon 2009 Call for Proposals

2008-09-27 Thread Benjamin Peterson
On Sat, Sep 27, 2008 at 12:02 AM, Brett Cannon <[EMAIL PROTECTED]> wrote:
> On Fri, Sep 26, 2008 at 7:37 PM, Benjamin Peterson
> <[EMAIL PROTECTED]> wrote:
>> On Fri, Sep 26, 2008 at 9:36 PM, Brett Cannon <[EMAIL PROTECTED]> wrote:

>>>
>>> I am thinking of organizing a panel this year for python-dev (much
>>> like the one I organized in 2007). Who would be willing to be on the
>>> panel with me if I did this?
>>
>> Could you explain what this is to us a little more, please? :)
>>
>
> You sit in front of a bunch of people answering questions asked by the
> audience. You know, a panel. =) It's just a Q&A session so that PyCon
> attendees can ask python-dev a bunch of random questions. Demystifies
> some things and puts faces to python-dev.

Sure. I would be interested in that.



-- 
Cheers,
Benjamin Peterson
"There's no place like 127.0.0.1."
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Filename as byte string in python 2.6 or 3.0?

2008-09-27 Thread Amaury Forgeot d'Arc
Hello Victor,

2008/9/27 Victor Stinner <[EMAIL PROTECTED]>:
> Hi,
>
> I read that Python 2.6 is planned to Wednesday. One bug is is still open and
> important for me: Python 2.6/3.0 are unable to use filename as byte strings.
>http://bugs.python.org/issue3187
[...]

Is it really a 2.6 problem? I could not find any difference with 2.5
in this regard,
the tests you propose still pass.

> Filename manipulation: in python 2.6/3.0, os.path.*() is not compatible with
> the type "bytes"

With python 2.6,
>>> bytes is str
True


But I agree that this is THE unresolved issue of python 3.0.

-- 
Amaury Forgeot d'Arc
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] PyCon 2009 Call for Proposals

2008-09-27 Thread Fredrik Lundh

Brett Cannon wrote:


You sit in front of a bunch of people answering questions asked by the
audience. You know, a panel. =) It's just a Q&A session so that PyCon
attendees can ask python-dev a bunch of random questions. Demystifies
some things and puts faces to python-dev.


and using moderator.appspot.com to gather questions from off-site 
attendees, perhaps?




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


Re: [Python-Dev] call for help: C-API 2 to 3 porting guide

2008-09-27 Thread Christian Heimes

Benjamin Peterson wrote:

Hi guys,
I remember a while back we were bemoaning the fact that little
documentation exists for the extension module transition between 2.x
and 3.x. In the name of this effort, I've created a c porting howto
(Doc/howto/cporting.rst). I have started a few sections, but I can't
do it all alone. Please consider writing a section.


I'll try to find some time over the weekend to assist you. I'm going to 
 contact the Cython developers, too. They have a great deal of 
experience with Python 2.x and 3.0 compatible C code. Perhaps they can 
give us some hints and tell us about gotchas and tricks.


Christian


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


Re: [Python-Dev] Filename as byte string in python 2.6 or 3.0?

2008-09-27 Thread Victor Stinner
Le Saturday 27 September 2008 14:04:25 Victor Stinner, vous avez écrit :
> I read that Python 2.6 is planned to Wednesday. One bug is is still open
> and important for me: Python 2.6/3.0 are unable to use filename as byte
> strings. http://bugs.python.org/issue3187

Ooops, as amaury noticed, the problem is specific to Python 3.0. My example 
works correctly with Python 2.6:
--
$ find
.
./a?b
./dir?name
./dir?name/file

$ ~/prog/python-trunk/python
Python 2.6rc2+ (trunk:66627M, Sep 26 2008, 19:03:31)
>>> import os, shutil
>>> os.listdir('.')
['a\xffb', 'dir\xffname']
>>> open(os.listdir('.')[0]).close()
>>> os.unlink(os.listdir('.')[0])
>>> os.listdir('.')
['dir\xffname']
>>> shutil.rmtree(os.listdir('.')[0])
--


Same test with Python 3.0:
--
$ pwd
/tmp/test

$ find
.
./a?b
./dir?name
./dir?name/file

$ ~/prog/py3k/python
Python 3.0rc1+ (py3k:66627M, Sep 26 2008, 18:10:03)
>>> import os, shutil
>>> os.listdir('.')
[b'a\xffb', b'dir\xffname']
>>> open(os.listdir('.')[0]).close()
Traceback (most recent call last):
  File "", line 1, in 
NOT FOUNT
>>> os.unlink(os.listdir('.')[0])
>>> os.listdir('.')
[b'dir\xffname']
>>> shutil.rmtree(os.listdir('.')[0])
Traceback (most recent call last):
  File "", line 1, in 
NOT FOUNT
--

Results:
 * open() doesn't support bytes
 * unlink() supports bytes
 * shutil.rmtree() doesn't support bytes


Another example to test chdir()/getcwd():
--
$ pwd
/tmp/test

$ ~/prog/py3k/python
Python 3.0rc1+ (py3k:66627M, Sep 26 2008, 18:10:03)
>>> import os, shutil
>>> os.getcwd()
'/tmp/test'
>>> os.chdir(b'/tmp/test/dir\xffname')
>>> os.getcwd()
Traceback (most recent call last):
  File "", line 1, in 
NOT FOUNT
--

Results:
 * chdir() supports byte filename
 * getcwd() fails

-- 
Victor Stinner aka haypo
http://www.haypocalc.com/blog/
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


[Python-Dev] I would like an Python account

2008-09-27 Thread Victor Stinner
Hi,

Would it possible to get more permissions on Python bugtracker, especially to 
add keywords, close a duplicate bug, etc.?

I also would like an SVN account for Python trunk and Python 3000 branch. I 
know that both branches are near "frozen" and commit are only allowed after 
patch review and/or discussion (on the mailing list or the bug tracker. So I 
will after the final versions (2.6 and 3.0) to commit. Or would it be 
possible to have a "mentor"? Someone to ask questions about Python SVN/bug 
tracker, or someone who reviews my patchs/commits.

-- 
Victor Stinner aka haypo
http://www.haypocalc.com/blog/
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] I would like an Python account

2008-09-27 Thread Benjamin Peterson
On Sat, Sep 27, 2008 at 10:32 AM, Victor Stinner
<[EMAIL PROTECTED]> wrote:
> Hi,
>
> Would it possible to get more permissions on Python bugtracker, especially to
> add keywords, close a duplicate bug, etc.?

+1

In the time Victor has been contributing, he's found copious amounts
of bugs and contributed excellent patches for almost every one.

>
> I also would like an SVN account for Python trunk and Python 3000 branch. I
> know that both branches are near "frozen" and commit are only allowed after
> patch review and/or discussion (on the mailing list or the bug tracker. So I
> will after the final versions (2.6 and 3.0) to commit. Or would it be
> possible to have a "mentor"? Someone to ask questions about Python SVN/bug
> tracker, or someone who reviews my patchs/commits.
>
> --
> Victor Stinner aka haypo
> http://www.haypocalc.com/blog/
> ___
> Python-Dev mailing list
> [email protected]
> http://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe: 
> http://mail.python.org/mailman/options/python-dev/musiccomposition%40gmail.com
>



-- 
Cheers,
Benjamin Peterson
"There's no place like 127.0.0.1."
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


[Python-Dev] 2to3 and reST text format

2008-09-27 Thread Victor Stinner
Hi,

As I remember, last month 2to3 was able to fix my reST documentation 
using "-d" option. But trunk version fails to parse my reST documents. Should 
I run fsck on my brain or is it really a regression?

Short example:
-
Title
=

Some text before the example:

>>> print "Hello world!"
Hello world!

Verbatim block: ::

>>> print "Hello world!"
Hello world!
-

The document can be checked with:
   python2.5 -c "import doctest; doctest.testfile('test.rst')"

2to3 output:
-
$ 2to3 -d test.rst
(...)
RefactoringTool: Can't parse test.rst: ParseError: bad input: type=28, 
value='==', context=('', (2, 0))
(...)
-

-- 
Victor Stinner aka haypo
http://www.haypocalc.com/blog/
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] 2to3 and reST text format

2008-09-27 Thread Benjamin Peterson
On Sat, Sep 27, 2008 at 10:38 AM, Victor Stinner
<[EMAIL PROTECTED]> wrote:
> Hi,
>
> As I remember, last month 2to3 was able to fix my reST documentation
> using "-d" option. But trunk version fails to parse my reST documents. Should
> I run fsck on my brain or is it really a regression?

Looks like it's my fault. Fixed in r66644.

>
> Short example:
> -
> Title
> =
>
> Some text before the example:
>
>>>> print "Hello world!"
>Hello world!
>
> Verbatim block: ::
>
>>>> print "Hello world!"
>Hello world!
> -
>
> The document can be checked with:
>   python2.5 -c "import doctest; doctest.testfile('test.rst')"
>
> 2to3 output:
> -
> $ 2to3 -d test.rst
> (...)
> RefactoringTool: Can't parse test.rst: ParseError: bad input: type=28,
> value='==', context=('', (2, 0))
> (...)
> -
>
> --
> Victor Stinner aka haypo
> http://www.haypocalc.com/blog/
> ___
> Python-Dev mailing list
> [email protected]
> http://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe: 
> http://mail.python.org/mailman/options/python-dev/musiccomposition%40gmail.com
>



-- 
Cheers,
Benjamin Peterson
"There's no place like 127.0.0.1."
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


[Python-Dev] Python security team

2008-09-27 Thread Victor Stinner
Hi,

I would like to know if a Python security team does exist. I sent an email 
about an imageop issue, and I didn't get any answer. Later I learned that a 
security ticket was created, I don't have access to it.

First, I would like to access to these informations. Not only this issue, but 
all security related issues. I have some knowledges about security and I can 
help to resolve issues and/or estimate the criticity of an issue.

Second, I would like to help to fix all Python security issues. It looks like 
Python community isn't very reactive (proactive?) about security. Eg. a DoS 
was reported in smtpd server (integrated to Python)... 15 months ago. A patch 
is available but it's not applied in Python trunk.

Third, I'm also looking for a document explaining "how Python is secure" (!). 
If an user can run arbitrary Python code, we know that it can do anything 
(read/remove any file, create/kill any process, read/write anywhere in 
memory, etc.). Brett wrote a paper about CPython sandboxing. PyPy is also 
working on sandboxing using two interpreters: one has high priviledge and 
execute instructions from the second interpreter (after checking the 
permissions and arguments). So is there somewhere a document to explain to 
current status of Python security?

-- 
Victor Stinner aka haypo
http://www.haypocalc.com/blog/
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Filename as byte string in python 2.6 or 3.0?

2008-09-27 Thread Martin v. Löwis
> I think that the problem is important because it's a regression from 2.5 to 
> 2.6/3.0. Python 2.5 uses bytes filename, so it was possible to 
> open/unlink "invalid" unicode strings (since it's not unicode but bytes).

I'd like to stress that the problem is *not* a regression from 2.5 to 2.6.

As for 3.0, I'd like to argue that the problem is a minor issue. Even
though you may run into file names that can't be decoded, that happening
really indicates some bigger problem in the management of the system
where this happens, and the proper solution (IMO) should be to change
the system (leaving open the question whether or not Python should
be also changed to work with such broken systems).

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


Re: [Python-Dev] json decoder speedups, any time left for 2.6?

2008-09-27 Thread Bob Ippolito
simplejson 2.0.0 is now released which is about as optimized as I can
be bothered to make it. It's about 4x faster than cPickle for encoding
and just a little slower and decoding, which is good enough for now ;)
The pure Python source is much uglier now (to avoid global lookups,
etc.), but also several times faster than it was.

http://pypi.python.org/pypi/simplejson

One of the optimizations I made probably isn't good for Py3k, it will
return ASCII strings as str objects instead of converting to unicode,
but that shouldn't be too much work to port (though I haven't looked
at the current _json.c port for Py3k).

I also converted over to using Sphinx documentation, which was nice
because I was able to just re-use the docs that were already in Python
trunk after changing the module name around.

All of the work should be easy to merge back into trunk so I'll try
and take care of that quickly after Python 2.6 is released.

On Wed, Sep 24, 2008 at 9:02 AM, Bob Ippolito <[EMAIL PROTECTED]> wrote:
> http://pypi.python.org/pypi/simplejson
>
> The _speedups module is optional.
>
> On Wed, Sep 24, 2008 at 8:42 AM, Alex Martelli <[EMAIL PROTECTED]> wrote:
>> Meanwhile, can you please release (wherever you normally release
>> things;-) the pure-Python version as well?  I'd like to play around
>> with it in Google App Engine opensource sandboxes (e.g., cfr.
>> gae-json-rest -- I'll be delighted to add you to that project if you
>> want of course;-) and that requires Python 2.5 and only pure-Python
>> add-ons... thanks!
>>
>> Alex
>>
>>
>> On Wed, Sep 24, 2008 at 8:08 AM, Bob Ippolito <[EMAIL PROTECTED]> wrote:
>>> On Wed, Sep 24, 2008 at 6:14 AM, Barry Warsaw <[EMAIL PROTECTED]> wrote:
 -BEGIN PGP SIGNED MESSAGE-
 Hash: SHA1

 On Sep 24, 2008, at 5:47 AM, Nick Coghlan wrote:

> Bob Ippolito wrote:
>>
>> How much time do I
>> have left to get this into Python 2.6?
>
> Zero I'm afraid - with rc1 out, it's release blocker bugs only. Anything
> which can be deferred to the 2.6.1 release without causing any major
> harm is definitely out - and while a 2x speedup is very nice, it isn't
> something to be squeezing in post-rc1.
>
> Still, that should make for a nice incremental improvement when 2.6.1
> rolls around.

 I concur.
>>>
>>> Ok, no problem. The speedup is about 3x now on the trunk ;) I think
>>> that further optimization will require some more C hacking, but 2.6.1
>>> should give me plenty of time to get around to some of that.
>>>
>>> -bob
>>> ___
>>> Python-Dev mailing list
>>> [email protected]
>>> http://mail.python.org/mailman/listinfo/python-dev
>>> Unsubscribe: 
>>> http://mail.python.org/mailman/options/python-dev/aleaxit%40gmail.com
>>>
>>
>
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Python security team

2008-09-27 Thread Josiah Carlson
On Sat, Sep 27, 2008 at 8:54 AM, Victor Stinner
<[EMAIL PROTECTED]> wrote:
> Second, I would like to help to fix all Python security issues. It looks like
> Python community isn't very reactive (proactive?) about security. Eg. a DoS
> was reported in smtpd server (integrated to Python)... 15 months ago. A patch
> is available but it's not applied in Python trunk.

The smtpd module is not meant to be used without modification.  It is
the responsibility of the application writer to decide the limitations
of the emails they want to allow sending, and subsequently handle the
case where emails overrun that limit.  That the bug wasn't assigned to
me outright (I am the maintainer of asyncore, asynchat, and smtpd) was
an understandable mistake.

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


Re: [Python-Dev] Filename as byte string in python 2.6 or 3.0?

2008-09-27 Thread Simon Cross
On Sat, Sep 27, 2008 at 7:41 PM, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote:
> As for 3.0, I'd like to argue that the problem is a minor issue. Even
> though you may run into file names that can't be decoded, that happening
> really indicates some bigger problem in the management of the system
> where this happens, and the proper solution (IMO) should be to change
> the system (leaving open the question whether or not Python should
> be also changed to work with such broken systems).

I can't agree here. File handling is a fundamental operation and I
would expect something like:

>>> for fname in os.listdir('.'):
...   if os.path.isfile(fname):
...  file(fname)

to work for all files.  To have to know to put in special handling for
certain corner case filenames or worse to not be able to open some
files at all would be a serious loss. It would also complicate
migrating code correctly to 3.0.

Regardless of whose fault the underlying issue is, someone has to deal
with the problem and if core Python doesn't, each developer who
encounters the problem will have to come up with his/her own solution.
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] PyCon 2009 Call for Proposals

2008-09-27 Thread Brett Cannon
On Sat, Sep 27, 2008 at 6:01 AM, Fredrik Lundh <[EMAIL PROTECTED]> wrote:
> Brett Cannon wrote:
>
>> You sit in front of a bunch of people answering questions asked by the
>> audience. You know, a panel. =) It's just a Q&A session so that PyCon
>> attendees can ask python-dev a bunch of random questions. Demystifies
>> some things and puts faces to python-dev.
>
> and using moderator.appspot.com to gather questions from off-site attendees,
> perhaps?
>

That was my thinking. That way I don't have to do much moderating
beyond what the community voted for.

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


Re: [Python-Dev] PyCon 2009 Call for Proposals

2008-09-27 Thread Brett Cannon
On Sat, Sep 27, 2008 at 3:25 AM, Tarek Ziadé <[EMAIL PROTECTED]> wrote:
>
>
> On Sat, Sep 27, 2008 at 7:02 AM, Brett Cannon <[EMAIL PROTECTED]> wrote:
>>
>> On Fri, Sep 26, 2008 at 7:37 PM, Benjamin Peterson
>> <[EMAIL PROTECTED]> wrote:
>> > On Fri, Sep 26, 2008 at 9:36 PM, Brett Cannon <[EMAIL PROTECTED]> wrote:
>> >> On Fri, Sep 26, 2008 at 4:25 PM, Aahz <[EMAIL PROTECTED]> wrote:
>> >>> Call for proposals -- PyCon 2009 -- 
>> >>> ===
>> >>>
>> >>> Want to share your experience and expertise? PyCon 2009 is looking for
>> >>> proposals to fill the formal presentation tracks. The PyCon conference
>> >>> days will be March 27-29, 2009 in Chicago, Illinois, preceded by the
>> >>> tutorial days (March 25-26), and followed by four days of development
>> >>> sprints (March 30-April 2).
>> >>>
>> >>
>> >> I am thinking of organizing a panel this year for python-dev (much
>> >> like the one I organized in 2007). Who would be willing to be on the
>> >> panel with me if I did this?
>> >
>> > Could you explain what this is to us a little more, please? :)
>> >
>>
>> You sit in front of a bunch of people answering questions asked by the
>> audience. You know, a panel. =) It's just a Q&A session so that PyCon
>> attendees can ask python-dev a bunch of random questions. Demystifies
>> some things and puts faces to python-dev.
>
> From a non-core developer point of view:
>
> What could be great imho would be to have a short "How Python is developed"
> presentation
> just before the panel starts.
>

I was already planning on giving my "how Python is developed" talk
anyway, and I would do my best to make sure they were run
back-to-back.

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


Re: [Python-Dev] PyCon 2009 Call for Proposals

2008-09-27 Thread Brett Cannon
On Sat, Sep 27, 2008 at 5:24 AM, Eric Smith <[EMAIL PROTECTED]> wrote:
> Brett Cannon wrote:
>>
>> I am thinking of organizing a panel this year for python-dev (much
>> like the one I organized in 2007). Who would be willing to be on the
>> panel with me if I did this?
>
> If you're looking for the perspective of someone who's relatively new to
> Python core programming, I'll do it. You won't offend me by picking someone
> else, though.
>

I don't mind it, but it needs to be balanced. The panel should only be
4 - 6 people in the end and I would like a good balance of someone
from PythonLabs (covered by Barry), long-term, mid-term (covered by
me), and a newbie like yourself. =) I will see who steps forward and I
will pull 3-5 people from those who volunteer. So please speak up
still if you are interested in participating.

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


Re: [Python-Dev] I would like an Python account

2008-09-27 Thread Brett Cannon
On Sat, Sep 27, 2008 at 8:32 AM, Victor Stinner
<[EMAIL PROTECTED]> wrote:
> Hi,
>
> Would it possible to get more permissions on Python bugtracker, especially to
> add keywords, close a duplicate bug, etc.?
>
> I also would like an SVN account for Python trunk and Python 3000 branch. I
> know that both branches are near "frozen" and commit are only allowed after
> patch review and/or discussion (on the mailing list or the bug tracker. So I
> will after the final versions (2.6 and 3.0) to commit. Or would it be
> possible to have a "mentor"? Someone to ask questions about Python SVN/bug
> tracker, or someone who reviews my patchs/commits.

If you were given commit privs, Victor, everyone would be your mentor
to make sure you didn't mess up. =) And python-dev or
python-committers (which you will be subscribed to if you get the
privs) are always available to ask questions.

-Brett

>
> --
> Victor Stinner aka haypo
> http://www.haypocalc.com/blog/
> ___
> Python-Dev mailing list
> [email protected]
> http://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe: 
> http://mail.python.org/mailman/options/python-dev/brett%40python.org
>
___
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com


Re: [Python-Dev] Python security team

2008-09-27 Thread Brett Cannon
On Sat, Sep 27, 2008 at 8:54 AM, Victor Stinner
<[EMAIL PROTECTED]> wrote:
> Hi,
>
> I would like to know if a Python security team does exist. I sent an email
> about an imageop issue, and I didn't get any answer. Later I learned that a
> security ticket was created, I don't have access to it.
>

Yes, the PSRT (Python Security Response Team) does exist. We did get
your email; sorry we didn't respond. There are very few members on
that list and most of them are extremely busy. Responding to your
email just slipped through the cracks. I believe Benjamin was the last
person to work on your submitted patch.

> First, I would like to access to these informations. Not only this issue, but
> all security related issues. I have some knowledges about security and I can
> help to resolve issues and/or estimate the criticity of an issue.
>

That would require commit privileges first. Don't know if the group
requires that a person have a decent amount of time committing to the
core first (I just joined the list in late July).

> Second, I would like to help to fix all Python security issues. It looks like
> Python community isn't very reactive (proactive?) about security. Eg. a DoS
> was reported in smtpd server (integrated to Python)... 15 months ago. A patch
> is available but it's not applied in Python trunk.
>

Historically we have not been proactive. No one on the core team (that
I know of) would claim they are a security expert. And with Python not
making any claims to being secure, we just don't worry about DoS
stuff, etc.; only the severe buffer overflow attacks that get reported
and such typically get immediate attention. Considering we have a
Crashers directory in the test suite I think that shows we are not
stressed over plugging every potential crash (although we obviously
would like to).

> Third, I'm also looking for a document explaining "how Python is secure" (!).
> If an user can run arbitrary Python code, we know that it can do anything
> (read/remove any file, create/kill any process, read/write anywhere in
> memory, etc.). Brett wrote a paper about CPython sandboxing. PyPy is also
> working on sandboxing using two interpreters: one has high priviledge and
> execute instructions from the second interpreter (after checking the
> permissions and arguments). So is there somewhere a document to explain to
> current status of Python security?
>

Nope. I think my paper and blog posts are about the best you are going
to find since we removed Bastion/rexec. Basically the philosophy has
been "fix privilege escalation stuff immediately, fix crashers when
the fix is simple or someone has the time to fix the complicated
ones". Or at least that is the philosophy I personally have followed.

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


Re: [Python-Dev] call for help: C-API 2 to 3 porting guide

2008-09-27 Thread Haoyu Bai
On Sat, Sep 27, 2008 at 9:09 PM, Christian Heimes <[EMAIL PROTECTED]> wrote:
> Benjamin Peterson wrote:
>>
>> Hi guys,
>> I remember a while back we were bemoaning the fact that little
>> documentation exists for the extension module transition between 2.x
>> and 3.x. In the name of this effort, I've created a c porting howto
>> (Doc/howto/cporting.rst). I have started a few sections, but I can't
>> do it all alone. Please consider writing a section.
>
> I'll try to find some time over the weekend to assist you. I'm going to
>  contact the Cython developers, too. They have a great deal of experience
> with Python 2.x and 3.0 compatible C code. Perhaps they can give us some
> hints and tell us about gotchas and tricks.
>

Also, there's a wiki page for some py3k extension moduls migration
tips: http://wiki.python.org/moin/Py3kExtensionModules

Hope it helps.

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