Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Fixed in r66223.
--
resolution: -> fixed
status: open -> closed
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs
New submission from Antoine Pitrou <[EMAIL PROTECTED]>:
I'm a bit puzzled that both str and bytes are accepted by os.write() in
py3k:
>>> os.write(1, "foo\n")
foo
4
>>> os.write(1, b"foo\n")
foo
4
--
components: Interpreter Core
mes
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Ok, with this patch the test passes under py3k.
Apart from the trivial typo (_Thread__stopped -> _stopped), I had to
change print("...") to os.write(1, b"...\n") in the tests as otherwise
subprocess wouldn't
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Benjamin, if you don't change the test, the deadlock problem is still
solved, it's just that the third test fails because the subprocess
stdout is empty instead of containing the desired value. It is *not*
because the subproce
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Instead of os.write(), it is actually sufficient to sys.stdout.flush()
at the end of the subprocess. Patch attached.
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.
Changes by Antoine Pitrou <[EMAIL PROTECTED]>:
Added file: http://bugs.python.org/file11379/forkthread2.patch
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Why wouldn't w.message simply be None?
--
nosy: +pitrou
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
The patch for _pickle has been committed in r66227.
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Numbers for the current py3k branch (without encode-leak2.patch):
test_distutils leaked [141, 142] references, sum=283
test_docxmlrpc leaked [-7, -85] references, sum=-92
test_logging leaked [0, 219] references, sum=219
test_poplib lea
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
As for the multiprocessing problem, it has been fixed recently on trunk.
Can you give it a try?
--
nosy: +pitrou
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
FWIW, applying encode-leak2.patch removes the leak in test_unicode.
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Is it really a compile error or just a warning?
--
nosy: +pitrou
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
It would be more efficient to base keys() on iterkeys() than the
reverse, IMO.
Other than that, why not open a branch or at least upload full-fledged
patch files? :)
--
nosy: +pitrou
___
Changes by Antoine Pitrou <[EMAIL PROTECTED]>:
--
type: -> feature request
versions: +Python 2.7, Python 3.1 -Python 2.5
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Alan, do you have an opinion on this?
--
nosy: +alanmcintyre
versions: +Python 2.7, Python 3.1 -Python 2.6, Python 3.0
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Just checked that the latest patch works on Windows as well.
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Le vendredi 05 septembre 2008 à 13:08 +, Amaury Forgeot d'Arc a
écrit :
> Antoine, it seem that with encode-leak2.patch, the error path after
> PyErr_WarnEx() leaks the value of "v".
Hmm, you are right.
>
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Amaury, your patch is much clearer indeed and it fixes the leak.
--
keywords: -needs review
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Alan, do you have commit access? Otherwise the patch needs approval from
another core developer.
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Current status:
test_distutils leaked [141, 142] references, sum=283
test_logging leaked [0, -219] references, sum=-219
test_smtplib leaked [0, 87] references, sum=87
The distutils leak should be investigated, but the overall situat
Changes by Antoine Pitrou <[EMAIL PROTECTED]>:
--
keywords: +needs review
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue3535>
___
_
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Fixed in r66235, r66236.
--
resolution: -> fixed
status: open -> closed
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
> test_distutils will be difficult; the leak is around the "import xx" in
> Lib/distutils/tests/test_build_ext.py.
>
> And Python/import.c says:
> /* To prevent initializing an extension module more than once
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
> It's not only the name, but a copy of the whole module dict just after
> import (that's why reload(sys) takes you back the
> sys.setdefaultencoding() function).
Ow.
> Actually I found a (hackish) way to cle
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Fixed in r66240, r66241. Thanks!
--
resolution: -> fixed
status: open -> closed
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs
New submission from Antoine Pitrou <[EMAIL PROTECTED]>:
Currently (in py3k), the attributes "unused_data" and "unconsumed_tail"
on zlib decompressor objects are bytearrays. This can wreak havoc in the
read() method of ZipInfo objects, because one of those bytearrays i
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
We must definitely clean up other uses of bytearray in the extension
modules - see #3790 for an example.
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
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.
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"
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 -Pyth
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Tests pass here as well, under Windows and Linux.
--
nosy: +pitrou
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
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 PROT
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Amaury beat me to the punch :-o
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue3797>
___
_
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]>
<http://bugs
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]>
<http://bugs.pytho
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
> app
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 &
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Committed in r66274, r66275. Thanks!
--
resolution: -> fixed
status: open -> closed
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.p
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Adding a simple unit test would be nice.
--
nosy: +pitrou
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
This isn't the right place to post setuptools patches, as setuptools is
not part of the standard Python distribution. There is a setuptools bug
tracker at http://bugs.python.org/setuptools/
You can probably also use the distutils-
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Fair enough :)
--
nosy: +pitrou
resolution: -> wont fix
status: open -> closed
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.py
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Hi,
This looks impressive. You should really work from the current SVN
trunk, not from the 2.5 sources, as there were some additions to the re
module (mainly, a bytecode verifier contributed by Google).
Also, if it can be split into s
Changes by Antoine Pitrou <[EMAIL PROTECTED]>:
--
nosy: +teoliphant
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue3827>
___
__
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
The patch is ok to me.
--
nosy: +pitrou
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Le jeudi 11 septembre 2008 à 12:46 +, Skip Montanaro a écrit :
> Gerhard> What's all this ORDER BY in both your implementations about?
> Gerhard> The dbm "spec" says nothing about keys being ordered
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
> My code regularily calculates the sha1 sum of 10.000 files and because
> in another reuse of the code had to deal with files too big to fit in
> memory I set a limit of 256Mb.
Why don't you use a sensible buffer siz
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Andrew, as for memory reallocation issues, you may take a look at #3526
where someone has similar problems on SunOS.
If nobody objects, I will close the present bug as invalid.
___
Python tracker &
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
By the way, this isn't caused by the present issue, but you'll notice
that in the latest trunk, some tests in find_recursion_limit.py fail
with an AttributeError instead of RuntimeError. This is likely caused by
a PyDic
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Le jeudi 11 septembre 2008 à 16:01 +0200, Anthon van der Neut a écrit :
> The thing however was resolved by reading multiple smaller chunks indeed
> 1Mb if the filesize exceeds 1Mb (in the latter case the original read()
> is
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Le jeudi 11 septembre 2008 à 13:48 +, Skip Montanaro a écrit :
> Actually, I think Python guarantees (for dicts at least - other mappings
> should probably follow suit) that if you call keys() then call values()
> wit
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
If they aren't part of a public API I think it's ok to fix them in
2.6/3.0. It is a bug fix, not a feature change.
--
nosy: +pitrou
___
Python tracker <[EMAIL PROTECTED]>
&
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
I might add that calling keys() then values() is suboptimal, because it
will issue two SQL queries while calling items() will issue just one.
___
Python tracker <[EMAIL PROTECTED]>
<http://
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Thorben, is the problem still there if you use fork() rather than
launching a separate thread for the server?
The implementation of the recv() method is straightforward and I don't
see anything that could cause a huge latency
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
You can use setsockopt() to set the TCP_NODELAY flag and see if that
improves things; sending thousands of 4-bytes packets isn't exactly the
expected utilization of TCP.
As I said, socket.recv() is just a thin wrapper above the s
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
> now thats interesting:
> adding the line "sock.setsockopt(SOL_TCP, TCP_NODELAY, 1) " decreased
> the delay by half. It still is extremely high but it's a start.
Did you do it on both the client and server so
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
> Well, sure, but heaven only knows what an application programmer will do...
If the docs clearly explain that there is no guarantee, we don't need
heaven.
I would find it strange to potentially ruin performance just for a
g
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
> Benchmarks to prove or disprove performance changes?
Agreed, benchmarks should be run.
> Subclasses to
> offer different order by semantics (see the version I uploaded for an
> example)?
If you like, but "
New submission from Antoine Pitrou <[EMAIL PROTECTED]>:
find_recursion_limit.py in trunk is broken: it fails with an
AttributeError while a RuntimeError is expected. This has appeared due
to the recent changes in recursion limit handling, but the problem is
deeper. As I explained on
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
I've opened #3850 for the find_recursion_limit problem.
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Here is a patch.
--
keywords: +needs review, patch
Added file: http://bugs.python.org/file11480/find_recursion_limit.patch
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
It's not my code, it's the interpreter's code which uses
PyDict_GetItem() all over the place, and the aim of
find_recursion_limit.py is precisely to test the function call paths
i
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
But it still means pickling a function/method defined in a builtin
extension module can give wrong results, doesn't it deserve being fixed?
--
nosy: +pitrou
___
Python tracker <[E
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
> I expect this is why nobody has ever complained about it: unless you're
> looking at the strings embedded in the pickle GLOBAL opcode, it's
> unlikely to have a visible consequence.
Well, it may have a conseq
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
> Yes, obviously. Although adding it to the client socket did make no
> difference after I had already done so for the server. Still
> communication is too slow by orders of magnitude. (Sorry for pointing
> this out aga
Changes by Antoine Pitrou <[EMAIL PROTECTED]>:
--
resolution: -> invalid
status: open -> closed
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs
Changes by Antoine Pitrou <[EMAIL PROTECTED]>:
--
components: +Installation
priority: -> critical
type: -> behavior
versions: +Python 2.6
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
> On my Macbook, it segfaults; perhaps that docstring applied only
> to MacOS 9?
Well, I just tried under Windows and the interpreter neither segfaults
nor prints a MemoryError, it aborts silently. I guess the comment is
either
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
By the way, the patch must be pretty incomplete, since there are almost
no changes to _sre.c. Am I missing something?
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
See also #3825.
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue2636>
___
___
Python
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Bug fixed and module comments updated in r66457.
--
resolution: -> fixed
status: open -> closed
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs
Changes by Antoine Pitrou <[EMAIL PROTECTED]>:
--
resolution: -> rejected
status: open -> closed
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
OK, thanks for the report anyway :)
--
nosy: +pitrou
resolution: -> invalid
status: open -> closed
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Here is a patch. I've covered all direct uses of os.write() in the
standard library, but perhaps there are indirect uses. Please review.
--
keywords: +needs review, patch
Added file: http://bugs.python.org/file11498/os
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Do the numbers vary if you read the whole file at once and then unpickle
the resulting bytes string?
Large parts of the IO library are written in Python in 3.0, which might
explain the discrepancy.
--
nosy: +
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Gregory had patches for a freelist of long objects in #2013.
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Thanks, committed in r66469.
--
resolution: -> fixed
status: open -> closed
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
The test would be better in test_memoryview rather than in test_builtin.
--
nosy: +pitrou
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
> I disagree. The test I added is really about compile, and its failure
> was really just a side effect of the buffer bug.
Well, I won't fight over it, but it's really meant to check an aspect of
memoryview behaviour -
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Looks like a duplicate of #2384. Do you confirm?
--
nosy: +pitrou
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Changes by Antoine Pitrou <[EMAIL PROTECTED]>:
--
resolution: -> duplicate
status: open -> closed
superseder: -> [Py3k] line number is wrong after encoding declaration
___
Python tracker <[EMAIL PROTECTED]>
<http://b
Changes by Antoine Pitrou <[EMAIL PROTECTED]>:
--
nosy: +haypo
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.python.org/issue2384>
___
___
Python
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
#3973 is a duplicate.
--
nosy: +pitrou
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Another solution would be to separate the dict items by key type, try to
sort each items list with separate fallback on onsorted. Then merge the
whole thing, ordered by key type name.
--
nosy: +
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
The rest of the patch is fine with me (I assume you've run all the unit
tests :-)).
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Very interesting, but it will have to wait for 2.7/3.1. 2.6 and 3.0 are
in the final phases of the release process.
--
nosy: +pitrou
priority: -> normal
versions: +Python 3.1 -P
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
+1 as well. Lib/pty.py had a line like that ("while buf != ''") and I
wondered why no exception was thrown with -bb while the variable was a
bytes object.
--
nosy: +pitrou
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Have you run benchmarks of both versions? It seems the benefit of the
original version is that it's faster, thanks to hardcoding critical methods.
--
nosy: +pitrou
___
Python trac
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
> You should also support bytearray() in ntpath:
>isinstance(path, (bytes, bytearray))
The most generic way of allowing all bytes-alike objects is to write:
path = bytes(path)
It raises a TypeError if `path` can't e
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Le vendredi 03 octobre 2008 à 11:43 +, STINNER Victor a écrit :
> STINNER Victor <[EMAIL PROTECTED]> added the comment:
>
> > The most generic way of allowing all bytes-alike objects is to write:
> >
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
I think it's reasonable to only enable multiprocessing if the adequate
command-line option has been set. It's how `make` already works (next
time you compile Python, try `make -jN` where N is your number of CPU
cores).
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
This is not specific to generators, this is due to the fact that a lot
of recursion checks have been added all over the place. When an internal
function designed to ignore exceptions (for example
PyErr_GivenExceptionMatches()) encounter
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
Someone should try implementing Martin's suggestion one day :)
--
nosy: +pitrou
versions: +Python 3.1 -Python 2.5, Python 2.6
___
Python tracker <[EMAIL PROTECTED]>
<ht
New submission from Antoine Pitrou <[EMAIL PROTECTED]>:
Issue #4074 suggests to me that maybe pybench should have some gc and/or
memory management tests. Marc-Andre, what do you think?
--
components: Demos and Tools
messages: 74599
nosy: lemburg, pitrou
priority: normal
severity:
Antoine Pitrou <[EMAIL PROTECTED]> added the comment:
> Note that pybench disables GC per default for exactly the reasons
> causing #4074 :-)
I know, I was thinking to enable the GC only in the GC-specific test of
course. The idea is to have a test stressing the GC heavily, such as
Antoine Pitrou added the comment:
When the following snippet is taken:
if (_PyString_Resize(&rv,
(bin_data -
(unsigned char *)PyString_AS_STRING(rv))) < 0) {
PyBuffer_Release(&pascii);
P
Antoine Pitrou added the comment:
The a2b_hqx() patch was committed in r77528 (trunk) and r77529 (py3k). Thanks
again!
--
___
Python tracker
<http://bugs.python.org/issue7
Changes by Antoine Pitrou :
Removed file:
http://bugs.python.org/file15910/issue7703_binascii_a2b_hqx_v3.diff
___
Python tracker
<http://bugs.python.org/issue7
Antoine Pitrou added the comment:
Ok, I've merged the ctypes fix to 2.6. As for 3.1, it doesn't seem to need the
fix.
--
___
Python tracker
<http://bugs.python.
Antoine Pitrou added the comment:
The patch was committed in r77543 (py3k), thank you!
--
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.o
Antoine Pitrou added the comment:
I think it would be better to test with some of the real world examples given
in this issue: str.split, and a functools.partial object.
--
___
Python tracker
<http://bugs.python.org/issue3
4401 - 4500 of 16792 matches
Mail list logo