On 1/1/07, Mike Orr <[EMAIL PROTECTED]> wrote:

On 1/1/07, Brett Cannon <[EMAIL PROTECTED]> wrote:
> * thread
>     + People should use 'threading' instead.

'threading' has no equivalent to 'thread.get_ident()'.  If this
function is ported, I'd support renaming 'thread'.  You need it to
print "Thread #123 doing bla bla bla" messages, to distinguish threads
in a thread pool, to keep track of thread-local data, etc.  The
threading.Thread name isn't the same thing because it's an arbitrary
string, not a guaranteed-unique integer, and the routine creating the
threads may be third-party and not setting unique identifiers.


This one you are going to have to argue it out with the people who want to
hide  the interface.  As for thread.get_ident(), it could be added to
threading.

* stat
>     + ``os.stat`` now returns a tuple with attributes.

Certain things in 'stat' do not exist elsewhere:  S_ISCHR, S_ISBLK,
S_ISFIFO, S_ISSOCK.  These could be made into more friendly
os.path.is*() functions that take the pathname rather than the
st_mode.  I've never used them, but it would be a pity to make people
calculate the bitmasks manually.


It would be better to add them as methods to the tuple object returned by
os.stat.  But the module should still go.

* fileinput

+1 to leave it.



People seem to really like this module, so it can stay.

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

Reply via email to