Antoine Pitrou added the comment:
Slightly cleaned up patch after Victor's comments in private.
--
Added file: http://bugs.python.org/file23381/find_max_char3.patch
___
Python tracker
<http://bugs.python.org/is
Antoine Pitrou added the comment:
Ok, updated patch.
--
Added file: http://bugs.python.org/file23382/find_max_char4.patch
___
Python tracker
<http://bugs.python.org/issue13
Antoine Pitrou added the comment:
> > Ok, updated patch.
>
> "ret = ~mask + 1;" looks wrong: (~0xFF80+1) gives 128, not 127.
That's on purpose, since the mask has just matched. If 0xFF80
matches, then the max char can't be 127, it has to be at least 1
Antoine Pitrou added the comment:
Thanks everyone for the reviews!
--
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Antoine Pitrou added the comment:
> How many moons before Python 2.7.3 though?
If you convince python-dev that's it's a critical bug (is it?) I suppose it
could happen soon.
--
___
Python tracker
<http://bugs.pytho
Antoine Pitrou added the comment:
> Actually, #9878 should supersede this bug: it proposes to generate a C
> module to avoid parsing Makefile and pyconfig.h, and your patch
> proposes to generate a Python module with the same goal.
Well, #9878 doesn't have a patch, but pe
Antoine Pitrou added the comment:
Yes, these are things I've been wondering about. The use-case for an
append-only StringIO is obviously overlapping with the use-case for using
''.join(). However, the implementation I'm proposing is better than ''.join()
w
Antoine Pitrou added the comment:
> > This new patch also fixes importlib.
>
> """
> path_tmp = path + '.tmp'
> with _io.FileIO(path_tmp, 'wb') as file:
> file.write(data)
>
Antoine Pitrou added the comment:
> find_max_char5.patch:
> - don't use adjusted ~mask+1: "precompute" the right max_char
> - rename findwidth.h to find_max_char.h
> - add some #undef
Thank you, I've committed this version.
--
resolution: -> fixed
s
Antoine Pitrou added the comment:
The patch looks good to me, thanks.
--
versions: +Python 2.7, Python 3.2
___
Python tracker
<http://bugs.python.org/issue13
Changes by Antoine Pitrou :
--
nosy: +georg.brandl
___
Python tracker
<http://bugs.python.org/issue13154>
___
___
Python-bugs-list mailing list
Unsubscribe:
Antoine Pitrou added the comment:
> Please double check the removal of _PyUnicode_XStrip.
I think it's ok. It is private, undocumented, and the only references
returned by Google Code Search are in Python itself.
I'll review the patch later, thank you.
--
title: Mo
Antoine Pitrou added the comment:
Thank you :)
--
___
Python tracker
<http://bugs.python.org/issue13159>
___
___
Python-bugs-list mailing list
Unsubscribe:
Antoine Pitrou added the comment:
> I think the >1 character sizes are overly complex in this patch, and
> still memchr isn't typically used for them. So I suggest to simplify
> the code and restrict it to 1-byte chars only.
I would rather propose to simplify the needle heuri
Changes by Antoine Pitrou :
--
nosy: +r.david.murray
___
Python tracker
<http://bugs.python.org/issue13163>
___
___
Python-bugs-list mailing list
Unsubscribe:
New submission from Antoine Pitrou :
The stringbench suite of micro-benchmarks, currently available through SVN at
http://svn.python.org/projects/sandbox/trunk/stringbench, would probably be a
reasonable addition to the Tools directory.
--
components: Demos and Tools
keywords: easy
Antoine Pitrou added the comment:
> > A Python solution would be more useful for other implementations
> > if enough of the sysconfig info is not CPython specific.
> That’s the point: the info currently parsed at runtime by sysconfig is
> specific to CPython (Makefile and pyco
Antoine Pitrou added the comment:
Ok, here is a new patch using O_EXCL.
Also, since import.c is quite different in 3.2, I'm not sure I will bother
backporting.
--
versions: -Python 3.2
Added file: http://bugs.python.org/file23396/importrename3.
Antoine Pitrou added the comment:
You broke compilation under Windows.
--
assignee: -> haypo
nosy: +pitrou
___
Python tracker
<http://bugs.python.org/issu
Antoine Pitrou added the comment:
As mentioned in
http://docs.python.org/dev/library/multiprocessing#multiprocessing.pool.AsyncResult.get
“If the remote call raised an exception then that exception will be reraised by
get().”
map() is just map_async() followed by a get() call on the result
Antoine Pitrou added the comment:
Crashes on the Windows buildbots:
f:\dd\vctools\crt_bld\self_x86\crt\src\strftime.c(832) : Assertion failed: (
"Invalid format directive" , 0 )
f:\dd\vctools\crt_bld\self_x86\crt\src\strftime.c(484) : Assertion failed: FALSE
--
assignee:
New submission from Antoine Pitrou :
This is, to say the least, annoying.
$ mkdir mypackage
$ touch mypackage/__init__.py
$ echo "from . import b" > mypackage/a.py
$ echo "from . import a" > mypackage/b.py
$ ./python -c "import mypackage.a"
Traceback (most
Changes by Antoine Pitrou :
--
nosy: +brett.cannon
___
Python tracker
<http://bugs.python.org/issue13187>
___
___
Python-bugs-list mailing list
Unsubscribe:
New submission from Antoine Pitrou :
In the following code, the original traceback attached to the exception thrown
into the generator is ignored:
def gen():
try:
yield
except:
raise
g = gen()
try:
1/0
except ZeroDivisionError as v:
g.throw(v)
But if you
New submission from Antoine Pitrou :
Not sure this is by design or not, but I wanted to report this issue (it's
rather hard to diagnose). Here the file descriptor limit is reached, and
"import" raises an ImportError while it would be more helpful to let the
original OS err
Antoine Pitrou added the comment:
> _Py_fopen() returns NULL without raising an exception if fopen() fails.
>
> Attached patch raises a OSError if fopen() if errno is different than
> ENOENT. I don't know if ENOENT is the right error number on Windows.
It seems so.
> S
New submission from Antoine Pitrou :
http://www.python.org/dev/buildbot/all/builders/x86%20XP-5%203.x/builds/3593/steps/test/logs/stdio
--
assignee: tarek
components: Distutils, Distutils2, Library (Lib), Tests
messages: 145643
nosy: alexis, eric.araujo, pitrou, tarek
priority: high
Antoine Pitrou added the comment:
> I don't think that fopen() can fails with ENOTDIR.
According to POSIX:
[ENOTDIR]
A component of the path prefix is not a directory, or the filename
argument contains at least one non- character and ends with one
or more trailing characters
Changes by Antoine Pitrou :
--
nosy: +loewis, nadeem.vawda
versions: +Python 3.3
___
Python tracker
<http://bugs.python.org/issue13194>
___
___
Python-bugs-list m
Antoine Pitrou added the comment:
> Are you suggesting raising the OSError (or something else) rather than
> an ImportError? If so, would it make sense to chain the exception
> instead. That way the existing code that expects ImportError
> continues to work
Does any existing
Antoine Pitrou added the comment:
Should be fixed now. Thanks for the reviews!
--
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Antoine Pitrou added the comment:
> Attached is a patch which adds dirfd= as a keyword argument.
Thanks. Although, on second thought, I'm not sure whether Amaury's idea
(allowing a custom opener) is not better... Thoughts?
--
___
P
Antoine Pitrou added the comment:
> I made the
> decision to raise a ValueError decision because __contains__ of both
> bytes and bytearray raise a ValueError when passed an integer not in
> range(0, 256).
That sounds reasonable. OverflowError would have been another choice, but I
Antoine Pitrou added the comment:
Doc/library/stdtypes.rst needs a "versionadded" tag for the additional
semantics.
Also, the patch doesn't compile fine on current default:
In file included from Objects/unicodeobject.c:487:0:
Objects/stringlib/find
Antoine Pitrou added the comment:
Thank you! There is a memory leak somewhere:
$ ./python -m test -R 3:2 test_generators
[1/1] test_generators
beginning 5 repetitions
12345
.
test_generators leaked [1945, 1945] references, sum=3890
1 test failed:
test_generators
Also, since the patch
Antoine Pitrou added the comment:
Actually, it is documented:
“Return the traceback associated with the exception as a new reference (...)”
http://docs.python.org/dev/c-api/exceptions.html#PyException_GetTraceback
Thanks for the patch, will apply
Changes by Antoine Pitrou :
--
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Antoine Pitrou added the comment:
Done! If someone wants to give life to the C approach, they are welcome :)
--
resolution: -> fixed
stage: -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Antoine Pitrou added the comment:
Similar test failure under x86 OpenIndiana:
==
ERROR: test_resources
(packaging.tests.test_command_install_data.InstallDataTestCase
Antoine Pitrou added the comment:
All the tests work fine with OpenSSL 1.0.0d under Mageia. Could you look into
Ubuntu-specific patches to OpenSSL? They have known to add disruptive changes
(we already have some Ubuntu-specific code in test_ssl).
Also, how about the system Python? Does it
Antoine Pitrou added the comment:
Actually, I think you may just have to fix skip_if_broken_ubuntu_ssl() in
test_ssl.py. Could you give it a try?
--
___
Python tracker
<http://bugs.python.org/issue13
Antoine Pitrou added the comment:
> Attached patch updates skip_if_broken_ubuntu_ssl(): OpenSSL in Ubuntu
> is still broken :-( OpenSSL package version is 1.0.0e-2ubuntu4 but in
> Python, ssl.OPENSSL_VERSION_INFO is still (0, 9, 8, 15, 15) !?
Are you sure? Did yo
Antoine Pitrou added the comment:
> AssertionError: Client protocol SSLv23 succeeded with server protocol SSLv3!
> AssertionError: Client protocol SSLv23 succeeded with server protocol TLSv1!
Hmm... I guess Ubuntu may have aliased SSLv23 to SSLv3. Can someone take
a look at Ubuntu patc
Antoine Pitrou added the comment:
Agreed that a strict parameter would be a good idea to implement this.
Since it's technically a new feature (and not that important), I think only 3.3
should receive it.
--
nosy: +pitrou
___
Python tracker
Antoine Pitrou added the comment:
> Apart from this, is there anything else that needs to be done before this
> change can be committed to the main repo?
Things look fine to me, apart from a couple of minor comments I've made on the
Antoine Pitrou added the comment:
Since the "name" is 7, it's certainly another file than the one opened in:
f = open("/proc/%s/cmdline" % self.pid)
It could be that you called open on the result of os.pipe(), or perhaps you
used a subprocess and didn'
Antoine Pitrou added the comment:
> If they don't hurt, why remove them?
Bogus constants don't hurt?
--
___
Python tracker
<http://bugs.pytho
Changes by Antoine Pitrou :
--
nosy: +brian.curtin, mhammond
___
Python tracker
<http://bugs.python.org/issue1602>
___
___
Python-bugs-list mailing list
Unsub
Antoine Pitrou added the comment:
> One could then continue processing, sending new transactions to the POP
> server and getting responses.
That's optimistic. You don't know how much data has been lost in readline().
Sure, again your test server, it happens to work :) But a
Changes by Antoine Pitrou :
--
nosy: +brian.curtin, pitrou, tim.golden
stage: -> patch review
versions: +Python 3.2, Python 3.3
___
Python tracker
<http://bugs.python.org/issu
Changes by Antoine Pitrou :
--
nosy: +haypo
___
Python tracker
<http://bugs.python.org/issue13234>
___
___
Python-bugs-list mailing list
Unsubscribe:
Antoine Pitrou added the comment:
Patch committed, thank you!
--
assignee: rhettinger ->
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python
Antoine Pitrou added the comment:
> According to issue 9203 the computed gotos should be enabled by default since
> 3.2.
> However, it is not visible from the interpreter.
>
> Python 3.2.2 (default, Sep 7 2011, 10:55:43)
> [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on
Antoine Pitrou added the comment:
> This looks like the system Python compiled by Apple. What about a
> hand-compiled Python?
Forget this. I get the same results here.
However, if you add a "#error" at the right place in ceval.c, you'll see that
computed gotos are enable
Antoine Pitrou added the comment:
You could replace "python -m test" with "make test", although it only does the
right thing in 3.3.
Otherwise, "python -m test -j3" would be friendlier to the reader I think :)
+1 on the principle, by the
Antoine Pitrou added the comment:
> New patch that adds a few more instructions for Windows/Mac OS. `make
> test` is UNIX-specific, so I left `./python -m test`.
> I also moved the section before the quick links, since it seems to me
> more interesting that those links (you don
Antoine Pitrou added the comment:
> Extract of my pyconfig.h
> -
> /* Define if you want to use computed gotos in ceval.c. */
> /* #undef USE_COMPUTED_GOTOS */
> -
Ok, now read ceval.c:
#ifdef HAVE
Antoine Pitrou added the comment:
> With the #error, I can confirm that computed gotos are enabled on OS X.
>
> About sysconfig, we may change the code to set None if the value is "undef".
> I don't know the impact.
Actually, I think sysconfig does the right thi
Antoine Pitrou added the comment:
> OTOH, __future__ imports (even jokes) should never be removed.
But their meaning can be altered?
(as part of another joke if you want :)
--
nosy: +pitrou
___
Python tracker
<http://bugs.python.org/issu
Antoine Pitrou added the comment:
Still happens on latest 2.7:
>>> from cStringIO import StringIO
>>> sio = StringIO(u"abc")
>>> sio.getvalue()
'a\x00b\x00c\x00'
--
nosy: +pitrou
resolution: fixed ->
stage: -> needs patch
sta
Antoine Pitrou added the comment:
And unsurprisingly so, since the fix was reverted in r56830 by Georg.
--
___
Python tracker
<http://bugs.python.org/issue1548
Antoine Pitrou added the comment:
Georg, is this patch ok to you?
--
assignee: georg.brandl ->
keywords: +patch
Added file: http://bugs.python.org/file23492/cio.patch
___
Python tracker
<http://bugs.python.org/issue1
New submission from Antoine Pitrou :
On 2.7, I get the following crashes in test_pydoc:
==
FAIL: test_apropos_with_bad_package (test.test_pydoc.PydocImportTest
Antoine Pitrou added the comment:
Hmm, it seems it's due to a 3rd party C extension:
$ ./python -c "import sqlalchemy.cprocessors"
python: Objects/object.c:65: _Py_AddToAllObjects: Assertion `(op->_ob_prev ==
((void *)0)) == (op->_ob_next == ((void *)0))' failed.
C
Changes by Antoine Pitrou :
--
resolution: -> invalid
status: open -> closed
___
Python tracker
<http://bugs.python.org/issue13242>
___
___
Python-bugs-
Antoine Pitrou added the comment:
Hum, in:
return_code = shellcmd.shell_call('ls -l {}', dirname)
listing = shellcmd.check_shell_output('ls -l {}', dirname)
...how do you know that dirname doesn't need some kind of escaping?
This is not only a security issue, bu
Antoine Pitrou added the comment:
> HTMLParser got a strict argument and it's causing more problems than it
> solves.
Well, HTML is a big can of worms while JSON is a rather clean format. We can
hope that adding a strict argument to json wouldn't cau
Antoine Pitrou added the comment:
> Yes, you have to be careful that "dirname" is legal in the shell, but
> that usually isn't a big problem in practice, because dirname came
> from a previous listdir call, or you otherwise know that it's valid to
> interpol
Antoine Pitrou added the comment:
> That's a fair point, but I think it actually *improves* the argument
> for better helper functions
Agreed :)
--
___
Python tracker
<http://bugs.python.
Antoine Pitrou added the comment:
Can't you use the normal algorithm for short names? I.e. KEYCER~1.PEM etc. Or
doesn't it exist anymore?
--
___
Python tracker
<http://bugs.python.o
Antoine Pitrou added the comment:
> If you think it's fine to change this behavior, then yes :)
Well, the "documented" behaviour makes no sense.
Either it should raise TypeError or convert. Since write() converts, it's
logical for the constructor to do so as well.
Antoine Pitrou added the comment:
Barry, perhaps you could try to know what in Ubuntu's OpenSSL build can lead to
such failures?
--
nosy: +barry
___
Python tracker
<http://bugs.python.org/is
New submission from Antoine Pitrou :
It seems there's no reason to document these functions which operate on
null-terminated unicode arrays.
--
assignee: docs@python
components: Documentation
messages: 146187
nosy: docs@python, ezio.melotti, georg.brandl, haypo, loewis, pitrou
pri
Antoine Pitrou added the comment:
Here is a patch. It adds SSLZeroReturnError, SSLWantReadError,
SSLWantWriteError, SSLSyscallError and SSLEOFError.
--
keywords: +patch
Added file: http://bugs.python.org/file23498/sslerrors.patch
___
Python tracker
Changes by Antoine Pitrou :
--
stage: needs patch -> patch review
___
Python tracker
<http://bugs.python.org/issue11183>
___
___
Python-bugs-list mai
Antoine Pitrou added the comment:
I'm not sure, but I think that would be for the case where you are spawning the
server yourself and the child process takes time to start up.
--
nosy: +neologix, pitrou
___
Python tracker
<http://bugs.py
Antoine Pitrou added the comment:
The patch looks good to me, thanks.
--
versions: +Python 3.3 -Python 3.1
___
Python tracker
<http://bugs.python.org/issue10
Antoine Pitrou added the comment:
Should be closed, no?
--
nosy: +pitrou
___
Python tracker
<http://bugs.python.org/issue13141>
___
___
Python-bugs-list mailin
Antoine Pitrou added the comment:
MoveFileTransacted is only available under Vista or later. You should be able
to use MoveFileEx for the same effect.
--
___
Python tracker
<http://bugs.python.org/issue8
Antoine Pitrou added the comment:
"The solution? Let's remember that metadata changes are atomic. Rename is such
a case."
This is from a MSDN blog, I would hope he knows what he's talking about.
http://blogs.msdn.com/b/adioltean/archive/2005/12/28/507866.aspx
(MoveFileE
Changes by Antoine Pitrou :
--
stage: -> patch review
type: performance -> behavior
versions: +Python 3.3
___
Python tracker
<http://bugs.python.org/
Antoine Pitrou added the comment:
Closing as outdated. There are no freelists anymore in the unicode
implementation.
--
resolution: -> out of date
stage: -> committed/rejected
status: open -> closed
___
Python tracker
<http://bug
Changes by Antoine Pitrou :
--
nosy: +pitrou
versions: +Python 3.2, Python 3.3 -Python 2.7
___
Python tracker
<http://bugs.python.org/issue10363>
___
___
Pytho
Antoine Pitrou added the comment:
I can't reproduce anymore. I believe this may have been due to the fact that
pydoc can try to import everything on sys.path, including third-party
libraries. I got bitten by that on another issue.
--
resolution: -> invalid
stage: nee
Antoine Pitrou added the comment:
> > "The solution? Let's remember that metadata changes are atomic. Rename is
> > such a case."
> >
>
> Hmmm.
> Is he referring to the "standard" rename? The blog doesn't evoke a
> specific functio
Changes by Antoine Pitrou :
--
nosy: +r.david.murray
versions: +Python 3.3
___
Python tracker
<http://bugs.python.org/issue13254>
___
___
Python-bugs-list mailin
Antoine Pitrou added the comment:
> *array*
> "fromstring" and "tostring" methods
I think these ones (and other well-known 2.x methods) should be kept to ease
porting to 3.x.
--
nosy: +pitrou
___
Python tracke
Antoine Pitrou added the comment:
I see that Sun/Oracle Java trusts MoveFileEx to do atomic renames:
290 // atomic case
291 if (atomicMove) {
292 try {
293 MoveFileEx(sourcePath, targetPath,
MOVEFILE_REPLACE_EXISTING);
294
Changes by Antoine Pitrou :
--
assignee: -> docs@python
components: +Documentation, Tests
nosy: +docs@python
stage: -> needs patch
versions: +Python 3.3
___
Python tracker
<http://bugs.python.org/i
Antoine Pitrou added the comment:
For packaging I'm not sure it's worth complicating backporting.
--
nosy: +eric.araujo, pitrou
___
Python tracker
<http://bugs.python.o
Antoine Pitrou added the comment:
Indeed. I didn't even remember we had that. There are tests, however, in
Lib/test/test_bytes.py.
This was added in issue #2415, by the way.
--
nosy: +pitrou
stage: -> needs patch
versions: -Python 3.1, Py
Antoine Pitrou added the comment:
Thanks for the patch. Is there a reason you don't use shutil.rmtree in
tearDown()?
I don't know if it's our business to convert forward slashes passed by the
user. Also, general support for extended paths is anoth
Antoine Pitrou added the comment:
CLOCK_MONOTONIC, CLOCK_PROCESS_CPUTIME_ID and CLOCK_THREAD_CPUTIME_ID are
optional according to POSIX, which only mandates CLOCK_REALTIME. You should
mention it in the docs.
You might also want to export clock_getres():
http://pubs.opengroup.org/onlinepubs
Antoine Pitrou added the comment:
> It looks like it's been this way for a long time too.
But tests have always passed here using OpenSSL 1.0.0.
> It's probably too difficult, and not really Python's responsibility,
> to determine whether SSL_OP_NO_SSLv2 is set.
Se
Antoine Pitrou added the comment:
I don't think submodules are a good idea. In practice, for example,
urllib.request.urlopen is more painful to use than good old urllib.urlopen.
If it's a matter of documentation, it can be split in several subchapters.
If it's a matter of or
Antoine Pitrou added the comment:
> I agree about urllib.request.urlopen, but os.sched.get_priority_max()
> is not longer than os.sched_get_priority_max().
Agreed. There are not many functions which could get this treatment,
though.
--
___
Antoine Pitrou added the comment:
Committed now.
--
resolution: -> fixed
stage: patch review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Antoine Pitrou added the comment:
For the record, both patches work fine here (Mageia 1, OpenSSL 1.0.0d).
--
___
Python tracker
<http://bugs.python.org/issue13
Changes by Antoine Pitrou :
--
nosy: +ezio.melotti, haypo
stage: -> patch review
versions: -Python 3.4
___
Python tracker
<http://bugs.python.org/issu
Antoine Pitrou added the comment:
I agree with Arkadiusz, this doesn't seem to match Python 2's exception
semantics, where you always specify the traceback explicitly if you want to.
--
___
Python tracker
<http://bugs.python.o
101 - 200 of 16792 matches
Mail list logo