[issue3792] Module variable overridden in child processes with multiprocessing

2008-09-06 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

What do you mean, "overriden"? The behaviour looks totally normal to me.
You change the value of "p" before the subprocess is started, so the
subprocess inherits the new value, not the old one.

--
nosy: +pitrou

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3792] Module variable overridden in child processes with multiprocessing

2008-09-06 Thread Benjamin Peterson

Benjamin Peterson <[EMAIL PROTECTED]> added the comment:

I agree; this is the expected behavior. Perhaps you don't understand how
globals work in Python?

--
nosy: +benjamin.peterson
resolution:  -> invalid
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3792] Module variable overridden in child processes with multiprocessing

2008-09-06 Thread Amaury Forgeot d'Arc

Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment:

Well, I get the OP's expected result on windows:

C:\dev\python\trunk>PCbuild\python_d t.py
Got 'p' of Correct
C:\dev\python\trunk>PCbuild\python_d t.py -m
Got 'p' of Correct

This is easy to explain: on Unix, the forked process has a copy of the
memory and reads the last value in the module. 
But on Windows, the freshly spawned process imports the module, and get
the initial value (since it does not enter the "__main__" block).

This is documented:
http://docs.python.org/dev/library/multiprocessing.html#windows , under
"Global Variables".

By the way, the Windows way may have some advantages for some uses.
Could the same method (start a new interpreter, import modules, copy
needed objects), be made available on Unix?

--
nosy: +amaury.forgeotdarc

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3040] optparse documentation: variable arguments example doesn't work as listed

2008-09-06 Thread A.M. Kuchling

A.M. Kuchling <[EMAIL PROTECTED]> added the comment:

Fixed in rev. 66250 of trunk; thanks!

--
nosy: +akuchling
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3604] broken link in curses module docs

2008-09-06 Thread A.M. Kuchling

A.M. Kuchling <[EMAIL PROTECTED]> added the comment:

This is fixed in the Python 2.6 documentation, where the HOWTOs 
have been incorporated and the link is therefore automatic.  Thanks for 
your report!

--
nosy: +akuchling
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3793] Small RST fix in datamodel.rst

2008-09-06 Thread Matt Giuca

New submission from Matt Giuca <[EMAIL PROTECTED]>:

A missing blank line under the heading for __bool__ in datamodel.rst (in
Python 3.0 docs) causes the following line to appear in the output HTML.

".. index:: single: __len__() (mapping object method)"

Visible here:
http://docs.python.org/dev/3.0/reference/datamodel.html#object.__bool__

Fixed in attached patch by adding a blank line.

Commit log:
Added blank line to avoid RST source leaking into HTML output.

--
assignee: georg.brandl
components: Documentation
files: patch
messages: 72668
nosy: georg.brandl, mgiuca
severity: normal
status: open
title: Small RST fix in datamodel.rst
versions: Python 3.0
Added file: http://bugs.python.org/file11405/patch

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3794] __div__ still documented in Python 3

2008-09-06 Thread Matt Giuca

New submission from Matt Giuca <[EMAIL PROTECTED]>:

The "special method names" section of the Python 3.0 documentation still
mentions the __div__ method. I believe this method has been totally
removed in Python 3 in favour of __truediv__. (Perhaps I am mistaken,
but 'int' object has no attribute '__div__', so I assume this is correct).

Note here:
http://docs.python.org/dev/3.0/reference/datamodel.html#object.__div__

__div__ is still documented. Most of the __div__/__truediv__ section
describes the issues distinguishing the two. Now that __div__ is gone,
surely there is no need for this section, and __truediv__ can just be
pushed up above with all the other operators?

Attached a patch doing that. Also deleted __rdiv__ and __idiv__ from the
following sections. (And one minor extra fix: added ``//`` to the list
of operators in reflected methods, since it was missing - note this
required a reflow of text, which is why the diff shows the whole
paragraph changing).

Change log:

Doc/reference/datamodel.rst: Removed section under "emulating numeric
types" about difference between __div__ and __truediv__, since __div__
has been removed from the language. Also deleted __rdiv__ and __idiv__
from the following sections, also removed.

--
assignee: georg.brandl
components: Documentation
files: datamodel.patch
keywords: patch
messages: 72669
nosy: georg.brandl, mgiuca
severity: normal
status: open
title: __div__ still documented in Python 3
versions: Python 3.0
Added file: http://bugs.python.org/file11406/datamodel.patch

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3792] Module variable overridden in child processes with multiprocessing

2008-09-06 Thread Steve Smith

Steve Smith <[EMAIL PROTECTED]> added the comment:

Ugh, sorry.  Stupidity on the reporter's part.

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3777] PyNumber_Long fails from Float

2008-09-06 Thread Barry Alan Scott

Barry Alan Scott <[EMAIL PROTECTED]> added the comment:

You are right that its the Py::Long( Py::Float( double( x ) ) )
that is triggering this problem.

Here is the gdb from the powerpc build that shows the
info you asked for and show res being corrupt.

I'm going to try and build a smaller version of this
problem using a minimal PyCXX module.

>>> import pysvn;pysvn.Client().ls('pysvn/__init__.py')

Breakpoint 1, bp () at pysvn_client_cmd_list.cpp:33
33  }
(gdb) c
Continuing.
Current language:  auto; currently c++

Breakpoint 2, pysvn_client::cmd_ls (this=0x1114830, [EMAIL PROTECTED],
[EMAIL PROTECTED]) at pysvn_client_cmd_list.cpp:138
138 Py::Long l_tmp( f_tmp );
(gdb) b PyNumber_Long
Breakpoint 5 at 0x213cfc: file Objects/abstract.c, line 1673.
(gdb) c
Continuing.

Breakpoint 5, PyNumber_Long (o=0x1809384) at Objects/abstract.c:1673
1673if (trunc_name == NULL) {
(gdb) p o
$25 = (PyObject *) 0x1809384
Current language:  auto; currently c
(gdb) p *o
$26 = {
  ob_refcnt = 1, 
  ob_type = 0x35723c
}
(gdb) p *o->ob_type
$27 = {
  ob_refcnt = 4, 
  ob_type = 0x35f0bc, 
  ob_size = 0, 
  tp_name = 0x339d98 "float", 
  tp_basicsize = 16, 
  tp_itemsize = 0, 
  tp_dealloc = 0x23de30 , 
  tp_print = 0x23fa90 , 
  tp_getattr = 0, 
  tp_setattr = 0, 
  tp_compare = 0, 
  tp_repr = 0x23fa50 , 
  tp_as_number = 0x357ab4, 
  tp_as_sequence = 0x0, 
  tp_as_mapping = 0x0, 
  tp_hash = 0x23e570 , 
  tp_call = 0, 
  tp_str = 0x23fa10 , 
  tp_getattro = 0x263800 , 
  tp_setattro = 0, 
  tp_as_buffer = 0x0, 
  tp_flags = 394747, 
  tp_doc = 0x357a4c "float(x) -> floating point number\n\nConvert a
string or number to a floating point number, if possible.", 
  tp_traverse = 0, 
  tp_clear = 0, 
  tp_richcompare = 0x23e000 , 
  tp_weaklistoffset = 0, 
  tp_iter = 0, 
  tp_iternext = 0, 
  tp_methods = 0x35733c, 
  tp_members = 0x0, 
  tp_getset = 0x357300, 
  tp_base = 0x0, 
  tp_dict = 0x0, 
  tp_descr_get = 0, 
  tp_descr_set = 0, 
  tp_dictoffset = 0, 
  tp_init = 0, 
  tp_alloc = 0, 
  tp_new = 0x241a10 , 
  tp_free = 0, 
  tp_is_gc = 0, 
  tp_bases = 0x0, 
  tp_mro = 0x0, 
  tp_cache = 0x0, 
  tp_subclasses = 0x0, 
  tp_weaklist = 0x0, 
  tp_del = 0, 
  tp_version_tag = 0
}
(gdb) n
1679if (o == NULL)
(gdb) 
1681m = o->ob_type->tp_as_number;
(gdb) 
1682if (m && m->nb_long) { /* This should include subclasses
of long */
(gdb) p *m
$28 = {
  nb_add = 0x242980 , 
  nb_subtract = 0x242c40 , 
  nb_multiply = 0x242f00 , 
  nb_divide = 0x2431c0 , 
  nb_remainder = 0x243510 , 
  nb_divmod = 0x243830 , 
  nb_power = 0x243bf0 , 
  nb_negative = 0x241d70 , 
  nb_positive = 0x241b60 , 
  nb_absolute = 0x241e70 , 
  nb_nonzero = 0x23e580 , 
  nb_invert = 0, 
  nb_lshift = 0, 
  nb_rshift = 0, 
  nb_and = 0, 
  nb_xor = 0, 
  nb_or = 0, 
  nb_coerce = 0x241f70 , 
  nb_int = 0x23e6e0 , 
  nb_long = 0x23e6e0 , 
  nb_float = 0x241b60 , 
  nb_oct = 0, 
  nb_hex = 0, 
  nb_inplace_add = 0, 
  nb_inplace_subtract = 0, 
  nb_inplace_multiply = 0, 
  nb_inplace_divide = 0, 
  nb_inplace_remainder = 0, 
  nb_inplace_power = 0, 
  nb_inplace_lshift = 0, 
  nb_inplace_rshift = 0, 
  nb_inplace_and = 0, 
  nb_inplace_xor = 0, 
  nb_inplace_or = 0, 
  nb_floor_divide = 0x243b60 , 
  nb_true_divide = 0x244340 , 
  nb_inplace_floor_divide = 0, 
  nb_inplace_true_divide = 0, 
  nb_index = 0
}
(gdb) n

Breakpoint 3, PyNumber_Long (o=0x1809384) at Objects/abstract.c:1684
1684PyObject *res = m->nb_long(o);
(gdb) s
float_trunc (v=0x1809384) at Objects/floatobject.c:1084
1084double x = PyFloat_AsDouble(v);
(gdb) p o
$29 = (PyObject *) 0x1809384
(gdb) p v
$30 = (PyObject *) 0x1809384
(gdb) n
1087(void)modf(x, &wholepart);
(gdb) p x
$31 = 0
(gdb) n
1100if (LONG_MIN < wholepart && wholepart < LONG_MAX) {
(gdb) p wholepart
$32 = 4555
(gdb) n
1102return PyInt_FromLong(aslong);
(gdb) p asLong
No symbol "asLong" in current context.
(gdb) p aslong
No symbol "aslong" in current context.
(gdb) n
1105}
(gdb) n
PyNumber_Long (o=0x1809384) at Objects/abstract.c:1685
1685if (res && (!PyInt_Check(res) &&
!PyLong_Check(res))) {
(gdb) p res
$33 = (PyObject *) 0x383cf0
(gdb) p *res
$34 = {
  ob_refcnt = 1362084, 
  ob_type = 0x140
}
(gdb) n

Breakpoint 4, PyNumber_Long (o=0x1809384) at Objects/abstract.c:1735
1735}
(gdb)

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3781] warnings.catch_warnings fails gracelessly when recording warnings but no warnings are emitted

2008-09-06 Thread Barry A. Warsaw

Barry A. Warsaw <[EMAIL PROTECTED]> added the comment:

I hate to make API suggestions this late in the process, but this is the
first
time I've looked at this.  I think the basic problem is that the context
manager API is a bit weird.  What I don't like is the fact that
__getattr__()
indexes the last item in the WarningsRecorder.  I don't know the history
here,
but why wouldn't this be a better API?

with catch_warnings(True) as w:
assert len(w) > 0, 'No caught warnings'
assert str(w[-1].message) == 'foo', 'blah blah'

--
nosy: +barry

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3657] pickle can pickle the wrong function

2008-09-06 Thread Barry A. Warsaw

Barry A. Warsaw <[EMAIL PROTECTED]> added the comment:

Neal, can you verify that this is still a problem now that bsddb has
been removed?  The tests, run in the order of the last comment, succeed
for me in both 2.6 and 3.0, debug build or not, on both my single
processor Ubuntu box and dual core Mac.

--
nosy: +barry
priority: release blocker -> deferred blocker
resolution:  -> works for me

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3794] __div__ still documented in Python 3

2008-09-06 Thread Georg Brandl

Georg Brandl <[EMAIL PROTECTED]> added the comment:

Fixed in r66260.

--
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3793] Small RST fix in datamodel.rst

2008-09-06 Thread Georg Brandl

Georg Brandl <[EMAIL PROTECTED]> added the comment:

Fixed in r66260.

--
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3794] __div__ still documented in Python 3

2008-09-06 Thread Georg Brandl

Georg Brandl <[EMAIL PROTECTED]> added the comment:

Uh, I meant r66261. Thanks for the patch!

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3783] dbm.sqlite proof of concept

2008-09-06 Thread Gregory P. Smith

Changes by Gregory P. Smith <[EMAIL PROTECTED]>:


--
nosy: +gregory.p.smith

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3790] in zlib decompressor objects, unused_data and unconsumed_tail must be immutable

2008-09-06 Thread Gregory P. Smith

Changes by Gregory P. Smith <[EMAIL PROTECTED]>:


--
assignee:  -> gregory.p.smith
nosy: +gregory.p.smith

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3783] dbm.sqlite proof of concept

2008-09-06 Thread Raymond Hettinger

Raymond Hettinger <[EMAIL PROTECTED]> added the comment:

I would like to see something like this go into 3.0 so that shelves
don't become useless for Windows users.

--
nosy: +rhettinger

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3781] warnings.catch_warnings fails gracelessly when recording warnings but no warnings are emitted

2008-09-06 Thread Brett Cannon

Brett Cannon <[EMAIL PROTECTED]> added the comment:

And I forgot to mention that subclassing list is a new thing I tossed in
when I moved the code and tweaked the API so that's another reason that
using list's abilities was not pervasive.

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3781] warnings.catch_warnings fails gracelessly when recording warnings but no warnings are emitted

2008-09-06 Thread Barry A. Warsaw

Barry A. Warsaw <[EMAIL PROTECTED]> added the comment:

Sounds good.  This needs to go into 2.6 and 3.0.  And while you're add
it, can you add catch_warnings to the __all__?

--
versions: +Python 3.0

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3781] warnings.catch_warnings fails gracelessly when recording warnings but no warnings are emitted

2008-09-06 Thread Brett Cannon

Brett Cannon <[EMAIL PROTECTED]> added the comment:

The use of __getattr__ is a historical artifact. Originally there was no
way to record multiple warnings as the object returned by
catch_warnings() represented only a single instance of a warning. But
then the ability to record multiple warnings was added. To not break
existing code (I am guessing), the setting of attributes on the
WarningsRecorder was added. To tawdry life of catch_warnings(). =)

While having the attributes of the last warning directly accessible is
handy, I am in no way married to the idea. Actually, if we run with the
list analogy we can just ditch WarningsRecorder and return a list itself
that is directly appended to through a version of showwarning() that is
a closure instead. That cuts out code and everyone knows how to work
with lists as sequential recording of events.

OK, I'm sold. =) I will work on this today or tomorrow and get the patch
done and ready to go no later than Sunday evening for review.

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3777] PyNumber_Long fails from Float

2008-09-06 Thread Barry Alan Scott

Barry Alan Scott <[EMAIL PROTECTED]> added the comment:

O.k. I know what is going on.

Here is the description from abstracts.h for PyNumber_Long:

 PyAPI_FUNC(PyObject *) PyNumber_Long(PyObject *o);

   /*
 Returns the o converted to a long integer object on success,
 or NULL on failure.  This is the equivalent of the Python
 expression: long(o).

   */

Its says that I can expect a long integer. However PyNumber_long
can return an int or a long.

PyCXX checks for a long, but an int is not a long and I raise
a type error.

This is a contract break on the Python API.

The change that causes this break is in floatobject.c
>From 2.5.2 code:

static PyNumberMethods float_as_number = {
...
float_int,  /*nb_int*/
float_long, /*nb_long*/

>From 2.6b3 code:

static PyNumberMethods float_as_number = {
...
float_trunc,/*nb_int*/
float_trunc,/*nb_long*/

float_trunc returns either an int or a long.
Which is not what is required for the API.

Here is the same bug at the pure python level.

 $ python2.6
Python 2.6b3 (r26b3:65922, Aug 25 2008, 15:44:46) 
[GCC 4.0.1 (Apple Computer, Inc. build 5370)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> long(4)
4L
>>> long(4.3)
4
>>> long("6")
6L
>>> type(long(4.3))

>>> 

Barry

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3705] py3k aborts if "-c" or "-m" is given a non-ascii value

2008-09-06 Thread Benjamin Peterson

Benjamin Peterson <[EMAIL PROTECTED]> added the comment:

Hmm. I suppose anything is better than segfaulting. I think the patch is
fine for now, though.

--
keywords:  -needs review
nosy: +benjamin.peterson

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1638033] Add httponly to Cookie module

2008-09-06 Thread Benjamin Peterson

Benjamin Peterson <[EMAIL PROTECTED]> added the comment:

Ok. Applied in r66262.

--
resolution:  -> accepted
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3795] wsgiref.simple_server fails to run demo_app

2008-09-06 Thread Bjarke Walling

New submission from Bjarke Walling <[EMAIL PROTECTED]>:

To reproduce the error start Python 3.0 and enter the usual WSGI "hello
world" application:

>>> from wsgiref.simple_server import make_server, demo_app
>>> httpd = make_server('', 8000, demo_app)
>>> httpd.serve_forever()

Open a browser and point it at http://location:8000/. On each HTTP
request an exception will be thrown:


Exception happened during processing of request from ('127.0.0.1', 55779)
Traceback (most recent call last):
  File "/usr/local/lib/python3.0/socketserver.py", line 281, in
_handle_request_noblock
self.process_request(request, client_address)
  File "/usr/local/lib/python3.0/socketserver.py", line 307, in
process_request
self.finish_request(request, client_address)
  File "/usr/local/lib/python3.0/socketserver.py", line 320, in
finish_request
self.RequestHandlerClass(request, client_address, self)
  File "/usr/local/lib/python3.0/socketserver.py", line 614, in __init__
self.handle()
  File "/usr/local/lib/python3.0/wsgiref/simple_server.py", line 136, in
handle
self.rfile, self.wfile, self.get_stderr(), self.get_environ()
  File "/usr/local/lib/python3.0/wsgiref/simple_server.py", line 115, in
get_environ
k,v = h.split(':',1)
ValueError: need more than 1 value to unpack


Expected result: The nice demo page containing WSGI environment
variables is displayed in the browser.

--
components: Library (Lib)
messages: 72684
nosy: Walling
severity: normal
status: open
title: wsgiref.simple_server fails to run demo_app
versions: Python 3.0

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3777] long(4.2) now returns an int

2008-09-06 Thread Amaury Forgeot d'Arc

Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment:

You are right: long(4.2) used to return a long.

This was changed by the introduction of the float_trunc() function,
which is now used for float.__trunc__, float.__int__ and float.__long__.

OTOH, long() has always been allowed to return an int. Checked with
python2.2:
>>> class C:
...   def __long__(self): return 4
...
>>> type(long(C()))


I suggest that:
- your code should be more tolerant, specially when calling API
functions from the "Abstract Objects Layer", accept both longs and ints.
- Concerning long(float()), the new behavior breaks existing code, and
should be reverted. I will try to come with a patch.

--
priority:  -> release blocker
title: PyNumber_Long fails from Float -> long(4.2) now returns an int

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3492] Zlib compress/decompress functions returning bytearray

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

fixed in r66266 along with #3790.

leaving this open and assigned to me while i investigate the other uses
of ByteArray in the Modules/ directory.

IMHO, its fine if we fix any remaining bytearray uses up for rc2.

--
resolution:  -> fixed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3790] in zlib decompressor objects, unused_data and unconsumed_tail must be immutable

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

fixed in r66266 along with #3492.

--
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3492] Zlib compress/decompress functions returning bytearray

2008-09-06 Thread Gregory P. Smith

Changes by Gregory P. Smith <[EMAIL PROTECTED]>:


--
priority: release blocker -> deferred blocker

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3669] sqlite3.Connection.iterdump docs pythonicity

2008-09-06 Thread A.M. Kuchling

A.M. Kuchling <[EMAIL PROTECTED]> added the comment:

Applied in rev. 66268; thanks!

--
nosy: +akuchling
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3796] some tests are not run in test_float

2008-09-06 Thread Amaury Forgeot d'Arc

New submission from Amaury Forgeot d'Arc <[EMAIL PROTECTED]>:

r62680 moved some tests from test_builtin to test_float,
but the list of classes to run was not updated.
Some minor updated were needed to let these tests pass.

--
files: test_float.patch
keywords: needs review, patch, patch
messages: 72689
nosy: amaury.forgeotdarc
severity: normal
status: open
title: some tests are not run in test_float
versions: Python 2.6, Python 3.0
Added file: http://bugs.python.org/file11407/test_float.patch

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3796] some tests are not run in test_float

2008-09-06 Thread Benjamin Peterson

Benjamin Peterson <[EMAIL PROTECTED]> added the comment:

Go ahead and commit.

--
nosy: +benjamin.peterson

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3797] mmap, dbm and ossaudiodev return bytearray instead of bytes

2008-09-06 Thread Gregory P. Smith

New submission from Gregory P. Smith <[EMAIL PROTECTED]>:

As noted in issue #3492 the following py3k modules still erroneously
return bytearray objects instead of bytes objects from their read functions:

mmap
dbm
ossaudiodev

Attached is a trivial patch to fix those.

--
assignee: gregory.p.smith
components: Extension Modules
files: mmap-dbm-oss_bytes.patch
keywords: easy, needs review, patch, patch
messages: 72691
nosy: gregory.p.smith
priority: deferred blocker
severity: normal
status: open
title: mmap, dbm and ossaudiodev return bytearray instead of bytes
type: behavior
versions: Python 3.0
Added file: http://bugs.python.org/file11408/mmap-dbm-oss_bytes.patch

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3705] py3k fails under Windows if "-c" or "-m" is given a non-ascii value

2008-09-06 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

Committed in r66269.

--
priority: deferred blocker -> high
title: py3k aborts if "-c" or "-m" is given a non-ascii value -> py3k fails 
under Windows if "-c" or "-m" is given a non-ascii value
type: crash -> behavior

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3797] mmap, dbm, ossaudiodev, marshal & winreg return bytearray instead of bytes

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

attached a patch for PC/winreg.c and Python/marshal.c.

--
title: mmap, dbm and ossaudiodev return bytearray instead of bytes -> mmap, 
dbm, ossaudiodev, marshal & winreg return bytearray instead of bytes
Added file: http://bugs.python.org/file11409/marshal-winreg_bytes.patch

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3492] Zlib compress/decompress functions returning bytearray

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

issue #3797 has been opened to track the other files mentioned.

--
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3796] some tests are not run in test_float

2008-09-06 Thread Amaury Forgeot d'Arc

Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment:

Committed r66270 and r66271.

--
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1674032] Make threading.Event().wait(timeout=3) return isSet

2008-09-06 Thread A.M. Kuchling

Changes by A.M. Kuchling <[EMAIL PROTECTED]>:


--
components:  -Documentation

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3797] mmap, dbm, ossaudiodev, marshal & winreg return bytearray instead of bytes

2008-09-06 Thread Hirokazu Yamamoto

Hirokazu Yamamoto <[EMAIL PROTECTED]> added the comment:

Hello. I confirmed test_winreg.py passed after applied
marshal-winreg_bytes.patch.

--
nosy: +ocean-city

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com




[issue1674032] Make threading.Event().wait(timeout=3) return isSet

2008-09-06 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

I agree this would be a worthwhile addition too. Unfortunately given the
current schedule this will probably have to wait for 2.7/3.1.

--
nosy: +pitrou
versions: +Python 2.7, Python 3.1 -Python 2.6

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3797] mmap, dbm, ossaudiodev, marshal & winreg return bytearray instead of bytes

2008-09-06 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

Tests pass here as well, under Windows and Linux.

--
nosy: +pitrou

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3797] mmap, dbm, ossaudiodev, marshal & winreg return bytearray instead of bytes

2008-09-06 Thread Amaury Forgeot d'Arc

Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment:

- PyBytes_Resize takes a PyObject**, you should pass &rv. Didn't you get
a compiler warning?

- Here is an additional test for the winreg module, your patch is needed
for it to pass.

--
nosy: +amaury.forgeotdarc

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3797] mmap, dbm, ossaudiodev, marshal & winreg return bytearray instead of bytes

2008-09-06 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

As for ossaudiodev:

-PyByteArray_Resize(rv, count);
+_PyBytes_Resize(rv, count);

I think this should be _PyBytes_Resize(&rv, count) instead.

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3797] mmap, dbm, ossaudiodev, marshal & winreg return bytearray instead of bytes

2008-09-06 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

Amaury beat me to the punch :-o

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3777] long(4.2) now returns an int

2008-09-06 Thread Amaury Forgeot d'Arc

Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment:

Here is a patch that restores the float->long conversion. The function
was simply copied from 2.5.

--
keywords: +needs review, patch
Added file: http://bugs.python.org/file11410/float_long.patch

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1317] smtplib.SMTP docs

2008-09-06 Thread A.M. Kuchling

A.M. Kuchling <[EMAIL PROTECTED]> added the comment:

Documentation added in rev. 66272.

--
assignee:  -> akuchling
nosy: +akuchling
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3795] wsgiref.simple_server fails to run demo_app

2008-09-06 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

This seems to be a duplicate of #3348.

--
nosy: +pitrou
resolution:  -> duplicate
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3348] Cannot start wsgiref simple server in Py3k

2008-09-06 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

Also reported in #3795.
PJE, are you willing to work on this some day?

--
nosy: +Walling

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3797] mmap, dbm, ossaudiodev, marshal & winreg return bytearray instead of bytes

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

heh indeed it should be &rv.  i made the patch on a mac and hadn't run
it on my linux host before opening the issue.

fixed locally and given all of the reviews across all relevant
platforms.. committing.  py3k r66273.

--
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue2320] Race condition in subprocess using stdin

2008-09-06 Thread David Naylor

David Naylor <[EMAIL PROTECTED]> added the comment:

I'm currently developing a script that makes extensive use of threads 
and Popen, with threads being created dynamically and each thread 
creating a large number of Popen processes.  

If I limit the thread count to 2 (main + worker) then the problem 
appears to disappear (or is just intermittent) however if I run with 
more than 2 threads or from within winpdb then the dead lock occurres 
rather consistently (and in the case of winpdb, always)

According to winpdb the script hangs on line 1086 of subprocess.py 
(from 2.5.2), strangely all remaining worker threads hand at this 
point:
# Wait for exec to fail or succeed; possibly raising exception
==> data = os.read(errpipe_read, 1048576) # Exceptions limited to 1 MB
os.close(errpipe_read)
if data != "":
os.waitpid(self.pid, 0)
child_exception = pickle.loads(data)
raise child_exception

I tried the suggestion of adding close_fds=True or using a global lock 
but the script still hangs under winpdb.  A solution that did appear 
to work was having both a global lock and adding close_fds=True to the 
call list.  

Running the script under pdb or cProfile appears to fix the problem as 
well...

NOTE: winpdb appears to bring out the worst case scenario and reliably 
reproduces the problem.

This is running on FreeBSD 8-Current amd64 (from early August) with 2 
cores.

--
nosy: +DragonSA

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3798] SystemExit incorrectly displays unicode message

2008-09-06 Thread Amaury Forgeot d'Arc

New submission from Amaury Forgeot d'Arc <[EMAIL PROTECTED]>:

When SystemExit is raised with a string argument, it is printed as UTF-8
to the (libc) stderr, and does not use the terminal's encoding.

handle_system_exit() should use PyFile_WriteString() instead of
PyObject_Print().

--
messages: 72708
nosy: amaury.forgeotdarc
severity: normal
status: open
title: SystemExit incorrectly displays unicode message
versions: Python 3.0

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1068268] subprocess is not EINTR-safe

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

its too late in the release process for subprocess internals being EINTR
safe to make it into 2.6 but it is reasonable for 2.6.1.

--
priority: low -> normal
type:  -> behavior
versions: +Python 2.5, Python 2.6

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3645] readline module Crashs on OpenBSD/amd64

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

true, issue 1204 is more general.  i'll leave this in but it can be
removed once the better general fix is in with 1204.  i won't backport
this one.

--
keywords: +64bit
status: pending -> closed
versions: +Python 2.6

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3799] Byte/string inconsistencies between different dbm modules

2008-09-06 Thread Skip Montanaro

New submission from Skip Montanaro <[EMAIL PROTECTED]>:

Consider these two timeit commands:

py3k% python3.0 -m timeit -s 'import dbm.ndbm as db' -s 'f = 
db.open("/tmp/trash.db", "c")' 'for i in range(1000): f[str(i)] = str(i)'
100 loops, best of 3: 5.51 msec per loop
py3k% python3.0 -m timeit -s 'import dbm.dumb as db' -s 'f = 
db.open("/tmp/trash.db", "c")' 'for i in range(1000): f[str(i)] = str(i)'
Traceback (most recent call last):
  File "/Users/skip/local/lib/python3.0/timeit.py", line 297, in main
x = t.timeit(number)
  File "/Users/skip/local/lib/python3.0/timeit.py", line 193, in timeit
timing = self.inner(it, self.timer)
  File "", line 7, in inner
for i in range(1000): f[str(i)] = str(i)
  File "/Users/skip/local/lib/python3.0/dbm/dumb.py", line 165, in 
__setitem__
raise TypeError("keys must be bytes")
TypeError: keys must be bytes

Seems to me they should either both succeed or both fail.  What are keys
and values supposed to be for these modules?

Marking it as high priority.  When 3.0 is released all these modules
should probably agree.

--
messages: 72711
nosy: skip.montanaro
priority: high
severity: normal
status: open
title: Byte/string inconsistencies between different dbm modules
type: behavior
versions: Python 3.0

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1204] readline configuration for shared libs w/o curses dependencies

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

when committing this one, the platform specific openbsd/amd64 fix I
committed for this in issue 3645 should probably be verified as unneeded
and undone.

marking as release blocker as we should make sure this autoconf update
goes in before the 2.6/3.0 release.  compiling for 64bit with readline
should work out of the box withing requiring patches on the most common
OSes.

I'm verifying rpetrov's patch in my centos4 VM now...

--
assignee: akuchling -> gregory.p.smith
nosy: +gregory.p.smith
priority: normal -> release blocker

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3348] Cannot start wsgiref simple server in Py3k

2008-09-06 Thread Phillip J. Eby

Phillip J. Eby <[EMAIL PROTECTED]> added the comment:

Not any time soon; I don't currently use Py3K and can't even vouch for
the correctness of the posted patch within Py3K.  (i.e., what really
happened to the message class?)  Sorry; all I can really do here is
clarify WSGI-related questions.

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3705] py3k fails under Windows if "-c" or "-m" is given a non-ascii value

2008-09-06 Thread Amaury Forgeot d'Arc

Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment:

This patch corrects the "-m" case on windows: the path has to be
decoded/recoded using the filesystem encoding, and not the default utf-8.
Review is needed, of course.

--
nosy: +amaury.forgeotdarc
Added file: http://bugs.python.org/file11411/find_module_unicode.patch

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3781] warnings.catch_warnings fails gracelessly when recording warnings but no warnings are emitted

2008-09-06 Thread Brett Cannon

Brett Cannon <[EMAIL PROTECTED]> added the comment:

On Sat, Sep 6, 2008 at 11:31 AM, Barry A. Warsaw <[EMAIL PROTECTED]> wrote:
>
> Barry A. Warsaw <[EMAIL PROTECTED]> added the comment:
>
> Sounds good.  This needs to go into 2.6 and 3.0.

Oh, definitely.

>  And while you're add
> it, can you add catch_warnings to the __all__?
>

Yep. And I will also change the __init__() so that it properly forces
keyword-only arguments in 2.6 like 3.0.

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue874900] threading module can deadlock after fork

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

forkthread2.patch looks good to me.  to be consistent shouldn't we also
apply that fix to 2.6?

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue874900] threading module can deadlock after fork

2008-09-06 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

Le samedi 06 septembre 2008 à 22:27 +, Gregory P. Smith a écrit :
> Gregory P. Smith <[EMAIL PROTECTED]> added the comment:
> 
> forkthread2.patch looks good to me.  to be consistent shouldn't we also
> apply that fix to 2.6?

Only the ident-resetting part needs to be backported, the rest is
py3k-specific (especially _stopped vs. _Thread__stopped :-)).

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3777] long(4.2) now returns an int

2008-09-06 Thread Barry Alan Scott

Barry Alan Scott <[EMAIL PROTECTED]> added the comment:

My concern and yours is that this is not backwards
compatible. I would hate to see "random" failures
of extensions written using PyCXX because of this.

I'm tempted to says that I'll keep PyCXX 5.x as is for
Python 2.x and leave all the changes in semantics
for PyCXX 6.0 that will support Python 3.0.
And in Python 3.0 this problem does not exist
by design.

I don't think you example proves anything.
Python does not check at the pure python level at all.

>>> class X:
... def __long__( self ):
... return "Hello"
... 
>>> long( X() )
'Hello'
>>> 

You get all you deserve if you define __long__ and break its
API.

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3783] dbm.sqlite proof of concept

2008-09-06 Thread Josiah Carlson

Josiah Carlson <[EMAIL PROTECTED]> added the comment:

Here's an alternate version with most of bsddb's interface intact.

--
nosy: +josiahcarlson
Added file: http://bugs.python.org/file11412/sq_dict.py

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3705] py3k fails under Windows if "-c" or "-m" is given a non-ascii value

2008-09-06 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

Looks good and works under Linux.
One small nit, you could just as well use "NN(ssi)" for the
Py_BuildValue and remove Py_DECREF(fob), so as to be more consistent.

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue874900] threading module can deadlock after fork

2008-09-06 Thread Antoine Pitrou

Antoine Pitrou <[EMAIL PROTECTED]> added the comment:

Committed in r66274, r66275. Thanks!

--
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue2420] Faq 4.28 -- Trailing comas

2008-09-06 Thread A.M. Kuchling

A.M. Kuchling <[EMAIL PROTECTED]> added the comment:

I've edited the suggested text and added it to the FAQ
in rev. 11722.  Thanks for your contribution!

--
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1204] readline configuration for shared libs w/o curses dependencies

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

I've attached an updated patch.  Not much changed other than the better
diff -u format, a couple grammar errors in comments and inclusion of the
new autoconf generated configure script.

It works fine for me on ubuntu hardy 32bit, CentOS 5.x x86_64, MacOS X
10.5 32-bit and 64-bit.

Could someone confirm on a platform where linking with 64bit readline
was broken before that this fixes it.  I added Henry Precheur to the
nosy list as he should be able to confirm on OpenBSD/amd64.

Lowering this to deferred blocker as it need not hold up -rc1 so long as
we get it in before -rc2.

--
keywords: +needs review
nosy: +henry.precheur
priority: release blocker -> deferred blocker
versions: +Python 3.0
Added file: http://bugs.python.org/file11413/configure-readline-libs-64bit.patch

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3704] cookielib doesn't handle URLs with / in parameters

2008-09-06 Thread Senthil

Senthil <[EMAIL PROTECTED]> added the comment:

The patch and tests look fine to me, Gregory. I verified it against the
trunk. Should not we have it for py3k as well?

--
nosy: +orsenthil

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3783] dbm.sqlite proof of concept

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

sq_dict review:

have sqlite quote/escape self._mtn before using it with a python %s
substitution.  or pass it into the sql query function as a positional ?
parameter like you do for keys and values.  (avoid sql injection)

raise a TypeError rather than a ValueError when you don't like the key
or value type.

also, to test the type, isinstance(val, str) is better than using type(val).

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3704] cookielib doesn't handle URLs with / in parameters

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

yep it applies to all releases.  anyways, it won't make 2.6/3.0 but it
can be put into 2.5.3/2.6.1/3.0.1.

--
versions: +Python 3.0

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue874900] threading module can deadlock after fork

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

I backported the last bit from r66275 to release25-maint in r66279.

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1204] readline configuration for shared libs w/o curses dependencies

2008-09-06 Thread Henry Precheur

Henry Precheur <[EMAIL PROTECTED]> added the comment:

According to config.log the readline functions are correctly detected. I
tested the patch with Python 2.5 & 2.6 and both work with the test I
posted on issue 3645.

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3783] dbm.sqlite proof of concept

2008-09-06 Thread Josiah Carlson

Josiah Carlson <[EMAIL PROTECTED]> added the comment:

I tried passing the db name as a parameter with '?', it doesn't always 
work.  Also, there shouldn't be any SQL injection issues here unless 
someone designed their system wrong (if a third party is allowed to pass 
the name of a db table into the open/create function, then they can do 
much worse than mangle or hide data in a sqlite database).

With regards to isinstance being better than type; it's only better if 
you want to support subclasses.  When writing the module, I had no 
interest in supporting subclasses (though supporting both str and buffer 
in 2.x, and bytes and memoryview in 3.x seems reasonable).

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3764] asyncore differences between 2.x and 3.x

2008-09-06 Thread Josiah Carlson

Josiah Carlson <[EMAIL PROTECTED]> added the comment:

Fixed in 66281.

--
resolution:  -> fixed
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3764] asyncore differences between 2.x and 3.x

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

please undo this, this broke asyncore in trunk.  handle_close_event 
doesn't exist in 2.6.

--
nosy: +gregory.p.smith
priority:  -> release blocker
resolution: fixed -> 
status: closed -> open

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3764] asyncore differences between 2.x and 3.x

2008-09-06 Thread Gregory P. Smith

Changes by Gregory P. Smith <[EMAIL PROTECTED]>:


--
keywords: +easy
type:  -> behavior
versions: +Python 2.6 -Python 3.0

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue3764] asyncore differences between 2.x and 3.x

2008-09-06 Thread Josiah Carlson

Josiah Carlson <[EMAIL PROTECTED]> added the comment:

I reverted the change I made to 2.6, see 66282.

The handle_close_event() method also doesn't exist in 3.0, which is why 
it (and the reference) were removed in revision 64883.  Giampaolo needs 
to update his Python 3.0 checkout.

Closing as invalid.

--
resolution:  -> invalid
status: open -> closed

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1204] readline configuration for shared libs w/o curses dependencies

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

fixed in trunk r66283 (followed by rerunning autoconf to generate a new
configure script in r66284).

--
keywords:  -needs review
versions:  -Python 2.6

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1204] readline configuration for shared libs w/o curses dependencies

2008-09-06 Thread Gregory P. Smith

Gregory P. Smith <[EMAIL PROTECTED]> added the comment:

merged into py3k branch in r66285.

backported to release25-maint in r66288 and r66289.

--
resolution:  -> accepted
status: open -> closed
versions:  -Python 3.0

___
Python tracker <[EMAIL PROTECTED]>

___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com