[issue12841] Incorrect tarfile.py extraction

2011-08-29 Thread Lars Gustäbel
Lars Gustäbel added the comment: Yes, it should be fixed in all affected branches. -- ___ Python tracker ___ ___ Python-bugs-list mai

[issue12841] Incorrect tarfile.py extraction

2011-08-29 Thread STINNER Victor
STINNER Victor added the comment: The patch looks ok. Can you push it Lars? -- ___ Python tracker ___ ___ Python-bugs-list mailing li

[issue12850] [PATCH] stm.atomic

2011-08-29 Thread Armin Rigo
New submission from Armin Rigo : Here is (attached) a minimal patch to the core trunk CPython to allow extension modules to take over control of acquiring and releasing the GIL, as proposed here: http://mail.python.org/pipermail/python-dev/2011-August/113248.html With this patch, it is possib

[issue12850] [PATCH] stm.atomic

2011-08-29 Thread Nadeem Vawda
Changes by Nadeem Vawda : -- nosy: +nadeem.vawda ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue12754] Add alternative random number generators

2011-08-29 Thread douglas bagnall
douglas bagnall added the comment: I am no kind of crypto expert, but from what I read, there are no known attacks on chacha8 or salsa20/12 better than brute-forcing the key, and distinguishing the stream from random or deducing state would be considered an attack. There's a summary of the E

[issue12850] [PATCH] stm.atomic

2011-08-29 Thread Armin Rigo
Armin Rigo added the comment: NB. I know that my stmmodule.c contains a gcc-ism: it uses a __thread global variable. I plan to fix this in future versions :-) -- ___ Python tracker __

[issue12851] ctypes: getbuffer() never provides strides

2011-08-29 Thread Stefan Krah
New submission from Stefan Krah : PyCData_NewGetBuffer() must provide strides information if requested, e.g. in response to a PyBUF_FULL_RO request. -- assignee: skrah components: Extension Modules messages: 143135 nosy: skrah priority: normal severity: normal stage: needs patch status:

[issue12850] [PATCH] stm.atomic

2011-08-29 Thread Nick Coghlan
Nick Coghlan added the comment: Rather than exposing the function pointers directly to the linker, I'd be happier with a function based API, with the pointer storage then being made static inside ceval.c. /* Each function returns the old func, or NULL on failure */ _PyEval_GIL_func _PyEval_re

[issue12850] [PATCH] stm.atomic

2011-08-29 Thread Armin Rigo
Armin Rigo added the comment: I suppose I'm fine either way, but do you have a reason for not exposing the variables to the linker? Some Windows-ism were such exposed variables are slower to access than static ones, maybe? The point is that they are kind of "internal use only" anyway, so de

[issue12742] Add support for CESU-8 encoding

2011-08-29 Thread Adal Chiriliuc
Adal Chiriliuc added the comment: It's an internal web API at the place I work for. To be able to use it from Python in some form, I did an workaround in which I just stripped everything outside BMP: # replace characters outside BMP with 'REPLACEMENT CHARACTER' (U+FFFD) def cesu8_to_utf8(text

[issue6715] xz compressor support

2011-08-29 Thread Barry A. Warsaw
Changes by Barry A. Warsaw : -- nosy: +barry ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue12742] Add support for CESU-8 encoding

2011-08-29 Thread Ezio Melotti
Ezio Melotti added the comment: I'm going to reject this. If people need it, they can always implement it using the codecs module. -- resolution: -> rejected stage: -> committed/rejected status: open -> closed ___ Python tracker

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread Remi Pointel
New submission from Remi Pointel : Hi, During the regress tests on OpenBSD, test_posix.test_fdlistdir() segfault. Details: $ ./python ./Tools/scripts/run_tests.py test_posix /home/remi/dev/cpython_test/python -W default -bb -E -m test -r -w -j 0 -u all,-largefile,-network,-urlfetch,-audio,-gu

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: Does it always segfault? Try: ./python -c 'import os; print(os.fdlistdir(os.open("/tmp", os.O_RDONLY)))' with various values for /tmp. >From what I can see, the code for fdlistdir is basically the same as >os.listdir(). If possible, try os.listdir() as well.

[issue12850] [PATCH] stm.atomic

2011-08-29 Thread Barry A. Warsaw
Changes by Barry A. Warsaw : -- nosy: +barry ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread Remi Pointel
Remi Pointel added the comment: Hi, thanks for your response. Yes it always segfault: $ ./python -c 'import os; print(os.fdlistdir(os.open("/tmp", os.O_RDONLY)))' zsh: segmentation fault (core dumped) ./python -c 'import os; print(os.fdlistdir(os.open("/tmp", os.O_RDONLY)))' $ ./python -c

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread STINNER Victor
STINNER Victor added the comment: It looks like a kernel bug !? Are you able to write a C script reproducing the problem? If not, I can try to write it. -- nosy: +haypo ___ Python tracker

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: > It looks like a kernel bug !? That's what I thought given that it appears to be working on all the other platforms. -- ___ Python tracker _

[issue12736] Request for python casemapping functions to use full not simple casemaps per Unicode's recommendation

2011-08-29 Thread Jean-Michel Fauth
Jean-Michel Fauth added the comment: Œ, œ or even & are historically ligatures or "ligatured forms". In the French typography, they are "single plain letters" and they belong the group of the 42 letters used in the French typography. Typographically speaking, using "oe" instead of "œ" is conside

[issue12736] Request for python casemapping functions to use full not simple casemaps per Unicode's recommendation

2011-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Œ, œ or even & are historically ligatures or "ligatured forms". > In the French typography, they are "single plain letters" and > they belong the group of the 42 letters used in the French > typography. > Typographically speaking, using "oe" instead of "œ" is

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread Remi Pointel
Remi Pointel added the comment: Hi, I tested with this program in C: #include #include #include #include int main(void) { DIR *d; struct dirent *dp; int dfd; if ((d = fdopendir((dfd = open("/tmp", O_RDONLY == NULL) { fprintf(stderr, "Cannot open /tmp directory

[issue12736] Request for python casemapping functions to use full not simple casemaps per Unicode's recommendation

2011-08-29 Thread Tom Christiansen
Tom Christiansen added the comment: Antoine Pitrou wrote on Mon, 29 Aug 2011 13:21:06 -: > It's not only "typographically speaking", it's really a spelling error, > even in hand-written text :-) Sure, and so too is omitting an accent mark or diaeresis. But—alas!—you’ll never convince

[issue8323] buffer objects are picklable but result is not unpicklable

2011-08-29 Thread sbt
sbt added the comment: Buffer objects *are* picklable with protocol 2 (but not with earlier protocols). Unfortunately, the result is not unpicklable. This is not a problem with multiprocessing. (buffer seems to inherit __reduce__ and __reduce_ex__ from object.) Python 2.7.1+ (r271:86832,

[issue9253] argparse: optional subparsers

2011-08-29 Thread Éric Araujo
Changes by Éric Araujo : -- stage: test needed -> needs patch versions: +Python 3.3 -Python 3.2 ___ Python tracker ___ ___ Python-bugs-

[issue3871] cross and native build of python for mingw32 with packaging

2011-08-29 Thread Éric Araujo
Éric Araujo added the comment: > if you recall there was some discussion that it was acceptable to use > distutils but *only* for python 2.N There was discussion, yes, but it was not decided to change our decision on the freeze: msg121097 > just as an aside: have all python 3.N packaging scrip

[issue12801] C realpath not used by os.path.realpath

2011-08-29 Thread jan matejek
Changes by jan matejek : -- nosy: +matejcik ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue3871] cross and native build of python for mingw32 with packaging

2011-08-29 Thread Zooko O'Whielacronx
Changes by Zooko O'Whielacronx : -- nosy: -zooko ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue11913] sdist refuses README.rst

2011-08-29 Thread Éric Araujo
Éric Araujo added the comment: distribute is not a project of python-dev, please use their bug tracker. For distutils, I explained why we can’t change it and proposed a doc change; nobody commented on that. For distutils2, I’m waiting for a reply from Tarek to this question: why don’t we inc

[issue2636] Adding a new regex module (compatible with re)

2011-08-29 Thread Éric Araujo
Changes by Éric Araujo : -- components: +Library (Lib) title: Regexp 2.7 (modifications to current re 2.2.2) -> Adding a new regex module (compatible with re) versions: +Python 3.3 ___ Python tracker __

[issue12801] C realpath not used by os.path.realpath

2011-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: Well, if we use two different paths based on the libc version, it might not be a good idea, since behaviour can be different in some cases. It would be nice to know if some modern platforms have a non-compliant realpath(). --

[issue10946] bdist doesn’t pass --skip-build on to subcommands

2011-08-29 Thread Éric Araujo
Éric Araujo added the comment: The fix was actually very simple. I have committed it to my 3.2 repo and will push later. -- stage: test needed -> commit review Added file: http://bugs.python.org/file23061/fix-bdist-skip-build.diff ___ Python tracke

[issue10886] Unhelpful backtrace for multiprocessing.Queue

2011-08-29 Thread sbt
sbt added the comment: mp_queue_pickle_in_main_thread.patch (against the default branch) fixes the problem by doing the pickling in Queue.put(). It is version of a patch for Issue 8037 (although I believe the behaviour complained about in Issue 8037 is not an actual bug). The patch also has

[issue12836] ctypes.cast() creates circular reference in original object

2011-08-29 Thread Vinay Sajip
Vinay Sajip added the comment: I can confirm that the same behaviour occur in Python 3.3, and this appears to be by design. There's a specific line in the cast() function in in Modules/_ctypes.c: rc = PyDict_SetItem(result->b_objects, index, src); This adds the source object to the _objects

[issue12785] list_distinfo_file is wrong

2011-08-29 Thread Éric Araujo
Éric Araujo added the comment: The tests using build_ext now pass \o/ I would love for someone with Windows and a 3.3 clone to test this patch (and if it does not fix, try with the two lines mentioned in msg142773 removed). -- ___ Python tracker

[issue12833] raw_input misbehaves when readline is imported

2011-08-29 Thread Éric Araujo
Éric Araujo added the comment: > Still, this behavior is surprising and undesirable. I would suggest > adding a note to the docs for the readline module +1. -- assignee: -> docs@python components: +Documentation -IO, Interpreter Core nosy: +docs@python stage: test needed -> needs patch

[issue8037] multiprocessing.Queue's put() not atomic thread wise

2011-08-29 Thread sbt
sbt added the comment: Modifying an object which is already on a traditional queue can also change what is received by the other thread (depending on timing). So Queue.Queue's put() is not "atomic" either. Therefore I do not believe this behaviour is a bug. However the solution proposed i

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: I'm not sure what the status of Python and OpenBSD support is but I just tried the latest stable version of OpenBSD (4.9) in VirtualBox and it won't compile fully. It segfaults while trying to run setup.py (I think). I see you're running OpenBSD 5.0. Does it

[issue8037] multiprocessing.Queue's put() not atomic thread wise

2011-08-29 Thread sbt
sbt added the comment: I meant Issue 6721 (Locks in python standard library should be sanitized on fork) not 6271. -- ___ Python tracker ___

[issue10886] Unhelpful backtrace for multiprocessing.Queue

2011-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: This shouldn't be a problem in Python 3.3, where the Connection classes are reimplemented in pure Python. -- nosy: +pitrou ___ Python tracker

[issue12853] global name 'r' is not defined in upload.py

2011-08-29 Thread Russell Owen
New submission from Russell Owen : When using distutils to upload code to PyPI I get the following message (but the upload is successful): {{{ Traceback (most recent call last): File "setup.py", line 60, in zip_safe = False, # icons (e.g. as used by RO.Wdg.GrayImageDispWdg) are not retri

[issue12801] C realpath not used by os.path.realpath

2011-08-29 Thread Charles-François Natali
Charles-François Natali added the comment: > Well, if we use two different paths based on the libc version, it might not > be a good idea, since behaviour can be different in some cases. Indeed. > It would be nice to know if some modern platforms have a non-compliant > realpath(). Alas, it

[issue12801] C realpath not used by os.path.realpath

2011-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Alas, it doesn't seem to hold for OpenBSD: > http://old.nabble.com/Make-realpath(3)-conform-to-SUSv4-td32031895.html > > A patch supporting NULL was committed two months ago, which means we > probably can't push this forward. > > I've been quite disappointed

[issue12801] C realpath not used by os.path.realpath

2011-08-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: > I've been quite disappointed by POSIX lately... POSIX the standard, or the implementers?? -- ___ Python tracker ___

[issue12853] global name 'r' is not defined in upload.py

2011-08-29 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- assignee: -> tarek components: +Distutils nosy: +eric.araujo, tarek stage: -> needs patch versions: +Python 3.2, Python 3.3 -Python 3.4 ___ Python tracker __

[issue11564] pickle not 64-bit ready

2011-08-29 Thread Nadeem Vawda
Nadeem Vawda added the comment: Tested the latest patch with -M11G. All tests pass. -- ___ Python tracker ___ ___ Python-bugs-list ma

[issue12801] C realpath not used by os.path.realpath

2011-08-29 Thread Charles-François Natali
Charles-François Natali added the comment: > POSIX the standard, or the implementers?? > Both :-) For those wondering why we can't use PATH_MAX (ignoring the buffer overallocation), here's why: https://www.securecoding.cert.org/confluence/display/cplusplus/FIO02-CPP.+Canonicalize+path+names+o

[issue12854] PyOS_Readline usage in tokenizer ignores sys.stdin/sys.stdout

2011-08-29 Thread Albert Zeyer
New submission from Albert Zeyer : In Parser/tokenizer.c, there is `PyOS_Readline(stdin, stdout, tok->prompt)`. This ignores any `sys.stdin` / `sys.stdout` overwrites. The usage should be like in Python/bltinmodule.c in builtin_raw_input. -- messages: 143168 nosy: Albert.Zeyer priority

[issue12769] String with NUL characters truncated by ctypes when assigning to a char array

2011-08-29 Thread Vinay Sajip
Vinay Sajip added the comment: This behaviour also occurs in 3.3, where this does appear to be a bug. In Modules/_ctypes/cfield.c, the setting code does a strlen(), which is in fact questioned in a comment. In function s_set(): size = strlen(data); /* XXX Why not Py_SIZE(value)? */ Why not,

[issue12769] String with NUL characters truncated by ctypes when assigning to a char array

2011-08-29 Thread Vinay Sajip
Vinay Sajip added the comment: Seems related: #8161 -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://

[issue9041] raised exception is misleading

2011-08-29 Thread Vinay Sajip
Vinay Sajip added the comment: While the patch might improve over the current situation, doesn't it potentially mask other errors which might be raised by PyFloat_AsDouble()? Why not just x = PyFloat_AsDouble(value); if (PyErr_Occurred()) return NULL; which would not mask any exception?

[issue12841] Incorrect tarfile.py extraction

2011-08-29 Thread Lars Gustäbel
Lars Gustäbel added the comment: Yes, I can do that as soon as I've managed to wrap my head around using Mercurial and the new way of developing Python. I have been away from Python programming for quite some time and haven't adapted my workflow yet. -- __

[issue6715] xz compressor support

2011-08-29 Thread Nadeem Vawda
Changes by Nadeem Vawda : -- hgrepos: +64 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org

[issue6715] xz compressor support

2011-08-29 Thread Nadeem Vawda
Changes by Nadeem Vawda : Added file: http://bugs.python.org/file23063/f3cf187208ea.diff ___ Python tracker ___ ___ Python-bugs-list mailing li

[issue6715] xz compressor support

2011-08-29 Thread Nadeem Vawda
Nadeem Vawda added the comment: Attached is a patch (f3cf187208ea.diff) containing my work so far on reimplementing the lzma module. So far I've just done the LZMACompressor and LZMADecompressor classes, but I'm hoping to implement LZMAFile this weekend. --

[issue6721] Locks in python standard library should be sanitized on fork

2011-08-29 Thread sbt
sbt added the comment: multiprocessing.util already has register_after_fork() which it uses for cleaning up certain things when a new process (launched by multiprocessing) is starting. This is very similar to the proposed atfork mechanism. Multiprocessing assumes that it is always safe to de

[issue12841] Incorrect tarfile.py extraction

2011-08-29 Thread STINNER Victor
STINNER Victor added the comment: You can get a lot of information on this guide: http://docs.python.org/devguide/setup.html#getting-set-up You can also ask on IRC (#python-dev on Freenode), or by email on the python-dev mailing list. It was really hard for me to switch from Subversion to Mer

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread STINNER Victor
STINNER Victor added the comment: > It looks like a kernel bug !? And you know what? fdopendir() function has been introducted in OpenBSD 5.0! -- ___ Python tracker ___ ___

[issue10886] Unhelpful backtrace for multiprocessing.Queue

2011-08-29 Thread sbt
sbt added the comment: > This shouldn't be a problem in Python 3.3, where the Connection classes > are reimplemented in pure Python. What should not be a problem? Changes to the implementation of Connection won't affect whether Queue.put() raises an error immediately if it gets an unpicklable

[issue12762] EnvironmentError_str contributes to unportable code

2011-08-29 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: I tend to agree that the errno is much less useful than the symbolic name. The former is useful and will be available as an attribute, but the latter should be used in the str. The change will probably break scads of doctests, but is probably worth it. :)

[issue10886] Unhelpful backtrace for multiprocessing.Queue

2011-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Changes to the implementation of Connection won't affect whether > Queue.put() raises an error immediately if it gets an unpicklable > argument. Ah, right. Then indeed it won't make a difference. -- ___ Python tra

[issue11564] pickle not 64-bit ready

2011-08-29 Thread Roundup Robot
Roundup Robot added the comment: New changeset babc90f3cbf4 by Antoine Pitrou in branch '3.2': Issue #11564: Avoid crashes when trying to pickle huge objects or containers http://hg.python.org/cpython/rev/babc90f3cbf4 New changeset 56242682a931 by Antoine Pitrou in branch 'default': Issue #1156

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread Charles-François Natali
Charles-François Natali added the comment: [Switching to process 21658, thread 0x20a519000] _readdir_unlocked (dirp=0xafb0e80, result=0x7f7d7ac0, skipdeleted=1) at /usr/src/lib/libc/gen/readdir.c:44 44 if (dirp->dd_loc >= dirp->dd_size) Looks like dirp points to an

[issue11564] pickle not 64-bit ready

2011-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: Should be fixed as far as possible (OverflowErrors will be raised instead of crashing). Making people actually 64-bit compliant is part of PEP 3154 (http://www.python.org/dev/peps/pep-3154/). -- resolution: -> fixed stage: patch review -> committed/r

[issue12852] test_posix.test_fdlistdir() segfault on OpenBSD

2011-08-29 Thread STINNER Victor
STINNER Victor added the comment: I think that the problem is that fdopendir() is not defined. If a function is not defined, C uses int as the result type. An int is not enough to store a 64-bit pointer. See in gdb output: dirp is 0x0afb0e80 whereas other pointers look like 0x20973fc30. You m

[issue12855] open() and codecs.open() treat form-feed differently

2011-08-29 Thread Matthew Boehm
New submission from Matthew Boehm : A file opened with codecs.open() splits on a form feed character (\x0c) while a file opened with open() does not. >>> with open("formfeed.txt", "w") as f: ... f.write("line \fone\nline two\n") ... >>> with open("formfeed.txt", "r") as f: ... s = f.read()

[issue12855] open() and codecs.open() treat form-feed differently

2011-08-29 Thread STINNER Victor
STINNER Victor added the comment: U+000C (Form feed) is considered as a line boundary in Unicode (unicode type), but no for a byte string (str type). Example: >>> u'line \x0cone\nline two\n'.splitlines(True) [u'line \x0c', u'one\n', u'line two\n'] >>> 'line \x0cone\nline two\n'.splitlines(Tru

[issue12589] test_long.test_nan_inf() failed on OpenBSD (powerpc)

2011-08-29 Thread STINNER Victor
STINNER Victor added the comment: > what information do you need to advance on this bug? It would be easier to debug if I had access to OpenBSD on a PowerPC host. -- ___ Python tracker ___

[issue12855] open() and codecs.open() treat form-feed differently

2011-08-29 Thread Matthew Boehm
Matthew Boehm added the comment: Thanks for explaining the reasoning. Perhaps I should add this to the python wiki (http://wiki.python.org/moin/Unicode) ? It would be nice if it fit in the docs somewhere, but I'm not sure where. I'm curious how (or if) 2to3 would handle this as well, but I'm

[issue12855] open() and codecs.open() treat form-feed differently

2011-08-29 Thread Matthew Boehm
Changes by Matthew Boehm : -- resolution: -> wont fix status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue12855] open() and codecs.open() treat form-feed differently

2011-08-29 Thread STINNER Victor
STINNER Victor added the comment: > It would be nice if it fit in the docs somewhere, > but I'm not sure where. See: http://docs.python.org/library/codecs.html#codecs.StreamReader.readline Can you suggest a patch for the documentation? Source code of this document: http://hg.python.org/cpython

[issue12855] open() and codecs.open() treat form-feed differently

2011-08-29 Thread Matthew Boehm
Matthew Boehm added the comment: I'll suggest a patch for the documentation when I get to my home computer in an hour or two. -- assignee: -> docs@python components: +Documentation -Interpreter Core nosy: +docs@python resolution: wont fix -> status: closed -> open __

[issue12847] crash with negative PUT in pickle

2011-08-29 Thread Roundup Robot
Roundup Robot added the comment: New changeset 0d9e4ce1c010 by Antoine Pitrou in branch '3.2': Issue #12847: Fix a crash with negative PUT and LONG_BINPUT arguments in http://hg.python.org/cpython/rev/0d9e4ce1c010 New changeset fb8d7a666bed by Antoine Pitrou in branch 'default': Issue #12847: F

[issue12847] crash with negative PUT in pickle

2011-08-29 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- resolution: -> fixed stage: -> committed/rejected status: open -> closed ___ Python tracker ___ ___ P

[issue12785] list_distinfo_file is wrong

2011-08-29 Thread Nadeem Vawda
Nadeem Vawda added the comment: I've tested the attached patch against 3.3 on Windows XP, and it seems to fix the test_database failures. There were some merge conflicts when I applied the patch (because some of the docstring and comment changes had already been committed in fixes from the other

[issue12856] tempfile PRNG reuse between parent and child process

2011-08-29 Thread Ferringb
Ferringb added the comment: Bleh; pardon, reuploading the patch. hg export aparently appends to the output file rather than overwriting it (last patch had duplicated content in it). -- Added file: http://bugs.python.org/file23067/unique-seed-per-process-tempfile.patch __

[issue12856] tempfile PRNG reuse between parent and child process

2011-08-29 Thread Ferringb
New submission from Ferringb : Roughly; tempfile's uniqueness is derived from a global random instance; while there are protections for thread access, a forked child process /will/ inherit that PRNG source, resulting in children/parent trying the same set of names. Mostly it's proving annoying

[issue12856] tempfile PRNG reuse between parent and child process

2011-08-29 Thread Ferringb
Changes by Ferringb : Removed file: http://bugs.python.org/file23066/unique-seed-per-process-tempfile.patch ___ Python tracker ___ ___ Python

[issue12855] open() and codecs.open() treat form-feed differently

2011-08-29 Thread Matthew Boehm
Matthew Boehm added the comment: I'm taking a look at the docs now. I'm considering adding a table/list of characters python treats as newlines, but it seems like this might fit better as a note in http://docs.python.org/library/stdtypes.html#str.splitlines or somewhere else in stdtypes. I'l

[issue12856] tempfile PRNG reuse between parent and child process

2011-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: Interesting, thank you. Two nits: - the test must be skipped where os.fork() isn't available (namely, under Windows) - I would do os.read(fd, 100) (or some other large value) rather than os.read(fd, 6), so that the test doesn't depend on the exact length of th

[issue12856] tempfile PRNG reuse between parent and child process

2011-08-29 Thread Ferringb
Ferringb added the comment: > the test must be skipped where os.fork() isn't available (namely, under > Windows) Done, although I still humbly suggest telling windows to bugger off ;) > I would do os.read(fd, 100) (or some other large value) rather than > os.read(fd, 6), so that the test doe

[issue12829] pyexpat segmentation fault caused by multiple calls to Parse()

2011-08-29 Thread David H. Gutteridge
David H. Gutteridge added the comment: Terry: I wasn't aware xml.parsers.expat is deprecated, though it clearly says so in the documentation, I now see... (I'd been using it because it features prominently in various examples in Python books, and it's lightweight.) I haven't tested with the

[issue12829] pyexpat segmentation fault caused by multiple calls to Parse()

2011-08-29 Thread David H. Gutteridge
David H. Gutteridge added the comment: Confirming that Python 3.2.1 crashes the same way on Mac OS X 10.6.8: Process: Python [9594] Path: /Library/Frameworks/Python.framework/Versions/3.2/Resources/Python.app/Contents/MacOS/Python Identifier: Python Version: ???

[issue12855] linebreak sequences should be better documented

2011-08-29 Thread Matthew Boehm
Matthew Boehm added the comment: I've attached a patch for python2.7 that adds a small not to library/stdtypes.html#str.splitlines explaining which sequences are treated as line breaks: """ Note: Python recognizes "\r", "\n", and "\r\n" as line boundaries for strings. In addition to these, U

[issue12829] pyexpat segmentation fault caused by multiple calls to Parse()

2011-08-29 Thread David H. Gutteridge
David H. Gutteridge added the comment: Further details: - The original test case I'd submitted crashed on the development branch of NetBSD as well as Mac OS X Snow Leopard, but not the most recent stable branch of NetBSD. I've found a separate test case that crashes on both branches of NetB

[issue12853] global name 'r' is not defined in upload.py

2011-08-29 Thread Anthony Kong
Changes by Anthony Kong : -- nosy: +Anthony.Kong ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue12857] Expose called function on frame object

2011-08-29 Thread Eric Snow
New submission from Eric Snow : This patch adds f_func to PyFrameObject and sets it for functions that get called (in PyFrame_New). For classes and modules it is set to None. The difference in performance was not noticable, as far as I could tell. However, I am willing to do more than just