[issue15819] Unable to build Python out-of-tree when source tree is readonly.

2012-08-29 Thread Trent Nelson
Changes by Trent Nelson : -- stage: needs patch -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15819] Unable to build Python out-of-tree when source tree is readonly.

2012-08-29 Thread Trent Nelson
New submission from Trent Nelson: This is somewhat related to Issue #9860. You can't currently build Python out-of-tree when the source directory is readonly. This is because there are a few Parser/pgen/AST/python_asdl.py steps that try and write to $(srcdir). The attached patch fixes this.

[issue15798] subprocess.Popen() fails if 0, 1 or 2 descriptor is closed

2012-08-29 Thread Ross Lagerwall
Ross Lagerwall added the comment: I sent a review through on rietveld; I'm attaching a patch with the changes so that it compiles and passes the tests. -- Added file: http://bugs.python.org/file27053/issue15798_v2.patch ___ Python tracker

[issue15765] test_getcwd_long_pathnames (in test_posix) kills NetBSD

2012-08-29 Thread Trent Nelson
Changes by Trent Nelson : -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail

[issue15818] multiprocessing documentation of Process.exitcode

2012-08-29 Thread Josh Kupershmidt
New submission from Josh Kupershmidt: [I tried to send this as an email to d...@python.org yesterday, but it seems to have gotten eaten, as I don't see the message in the archives.] Hi all, The documentation for the multiprocessing module claims: | Note that the start(), join(), is_alive() an

[issue13405] Add DTrace probes

2012-08-29 Thread Jesús Cea Avión
Jesús Cea Avión added the comment: OpenIndiana custom buildbots, 32 and 64 bits, SUCCESFULL: 2.7 branch: 32 bits: http://buildbot.python.org/all/builders/x86%20OpenIndiana%20custom/builds/6 64 bits: http://buildbot.python.org/all/builders/AMD64%20OpenIndiana%20custom/builds/8 3.3 branch: 32

[issue15808] Possibility of setting custom key bindings for "Additional help sources" menu items

2012-08-29 Thread Ned Deily
Changes by Ned Deily : Added file: http://bugs.python.org/file27052/issue15808_idle_doc_paths.patch ___ Python tracker ___ ___ Python-bugs-lis

[issue15808] Possibility of setting custom key bindings for "Additional help sources" menu items

2012-08-29 Thread Ned Deily
Changes by Ned Deily : Removed file: http://bugs.python.org/file27051/issue15808_idle_doc_paths.patch ___ Python tracker ___ ___ Python-bugs-l

[issue15808] Possibility of setting custom key bindings for "Additional help sources" menu items

2012-08-29 Thread Ned Deily
Ned Deily added the comment: Here's a patch to update the doc paths to include current ones for Debian/Ubuntu and Fedora. The patch will have to be tweaked a bit for 3.2/2.7 to change sys.base_prefix to sys.prefix. -- keywords: +patch stage: needs patch -> patch review Added file: htt

[issue15814] memoryview: equality-hash invariant

2012-08-29 Thread Nick Coghlan
Nick Coghlan added the comment: My perspective is that hashing a memoryview only makes sense when the memoryview is read-only and "m == m.tobytes()" (i.e. it's a C contiguous 1D view of bytes, either because that's what the original object exported as a buffer or because the view has been cast

[issue15805] Add stdout redirection tool to contextlib

2012-08-29 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : -- nosy: +belopolsky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://m

[issue15814] memoryview: equality-hash invariant

2012-08-29 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : -- nosy: +belopolsky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://m

[issue15817] Misc/gdbinit: Expose command documentation to gdb help

2012-08-29 Thread Alexander Belopolsky
New submission from Alexander Belopolsky: Currently "help user-defined" lists commands defined in Misc/gdbinit without explanations (gdb) help user-defined User-defined commands. The commands in this class are those defined by the user. Use the "define" command to define a command. List of co

[issue15781] test_threaded_import fails with -j4

2012-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: Looks fixed! -- resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed ___ Python tracker ___ _

[issue15800] Closing of sys.std* files in gzip test.

2012-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: A simple fix indeed, thank you. -- resolution: -> fixed stage: -> committed/rejected status: open -> closed ___ Python tracker ___ ___

[issue15800] Closing of sys.std* files in gzip test.

2012-08-29 Thread Roundup Robot
Roundup Robot added the comment: New changeset 0b5ba5f610a9 by Antoine Pitrou in branch '3.2': Issue #15800: fix the closing of input / output files when gzip is used as a script. http://hg.python.org/cpython/rev/0b5ba5f610a9 New changeset be505d22dde8 by Antoine Pitrou in branch 'default': Iss

[issue15815] Add numerator to ZeroDivisionError messages

2012-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: > In case the value of the numerator helps find out why the denominator > is 0. The example given by Mike Graham on python-ideas, Verbose > traceback formatting was > > def f(a): > x = a * 4 > y = a - 4 > return x / y Well, in this case y == 0 iff a

[issue15815] Add numerator to ZeroDivisionError messages

2012-08-29 Thread Terry J. Reedy
Terry J. Reedy added the comment: In case the value of the numerator helps find out why the denominator is 0. The example given by Mike Graham on python-ideas, Verbose traceback formatting was def f(a): x = a * 4 y = a - 4 return x / y -- __

[issue15815] Add numerator to ZeroDivisionError messages

2012-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: What would be the point? Usually you should find out why the denominator is zero, not what the numerator's value is. -- nosy: +pitrou ___ Python tracker __

[issue15814] memoryview: equality-hash invariant

2012-08-29 Thread Martin v . Löwis
Martin v. Löwis added the comment: Am 29.08.12 22:04, schrieb Stefan Krah: > In the memoryview-hash thread on python-dev [1] this objection was > addressed by demanding from exporters that they all use: > > hash(x) == hash(x.tobytes()) > > Since the previous equality concept was also based on

[issue15814] memoryview: equality-hash invariant

2012-08-29 Thread Stefan Krah
Stefan Krah added the comment: And since memory_richcompare() and any potentially compatible hash function are quite tricky to implement by now, perhaps the generally useful parts could be exposed as PyBuffer_RichCompareBool() and PyBuffer_Hash(). --

[issue15814] memoryview: equality-hash invariant

2012-08-29 Thread Stefan Krah
Stefan Krah added the comment: Martin v. L??wis wrote: > In general, since memoryview(obj)==obj, it would be necessary that > hash(memoryview(obj))==hash(obj). However, since memoryview cannot > know what hashing algorithm obj uses, it cannot compute the hash > value with the same algorithm. In

[issue15808] Possibility of setting custom key bindings for "Additional help sources" menu items

2012-08-29 Thread Ned Deily
Ned Deily added the comment: Actually, IDLE does have code to look for an on-disk copy of the html-formatted Python documentation set but the paths are platform-specific and, in the Linux case, are out-of-date for some distributions at least. For Linux platforms it looks for `index.html` in e

[issue14803] Add feature to allow code execution prior to __main__ invocation

2012-08-29 Thread Andrew Svetlov
Changes by Andrew Svetlov : -- nosy: +asvetlov ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue15816] pydoc.py uses a hack that depends on implementation details and breaks help() when __builtin__.__import__ is overwritten.

2012-08-29 Thread R. David Murray
R. David Murray added the comment: Replacing __import__ is not supported. That said, this is fixed in 3.3. -- nosy: +r.david.murray resolution: -> out of date stage: -> committed/rejected status: open -> closed type: -> behavior versions: +Python 3.3 -Python 2.7, Python 3.1, Python 3

[issue15816] pydoc.py uses a hack that depends on implementation details and breaks help() when __builtin__.__import__ is overwritten.

2012-08-29 Thread David Kreuter
New submission from David Kreuter: help("compile") # this works import __builtin__ real_import = __import__ __builtin__.__import__ = lambda *a: real_import(*a) help("compile") # this fails The line responsible for this is in pydoc.py around line 300: ... elif exc is ImportError and extract_tb(tb

[issue15814] memoryview: equality-hash invariant

2012-08-29 Thread Martin v . Löwis
Martin v. Löwis added the comment: Am 29.08.12 21:06, schrieb Antoine Pitrou: >> So what specific hash algorithm do you propose? > > The current algorithm works well in conjunction with bytes objects. That's about the only type if works for. >> My claim is that any hash definition for memoryvie

[issue15815] Add numerator to ZeroDivisionError messages

2012-08-29 Thread Terry J. Reedy
New submission from Terry J. Reedy: I propose that we add 'of ' to all ZeroDivisionError messagesso it is less necessary to use a debugger to add print statements to recover the information currently tossed away. (I also propose to change denominator from 'zero' to '0', '0.0', '0+0j', as a

[issue15814] memoryview: equality-hash invariant

2012-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: > Am 29.08.12 20:01, schrieb Antoine Pitrou: > >> I think the proper solution is to make memoryview objects unhashable. > > > > Disagreed. If memoryviews are to be bytes-like objects they should be > > hashable (at least when readonly). > > So what specific hash

[issue15814] memoryview: equality-hash invariant

2012-08-29 Thread Martin v . Löwis
Martin v. Löwis added the comment: Am 29.08.12 20:01, schrieb Antoine Pitrou: >> I think the proper solution is to make memoryview objects unhashable. > > Disagreed. If memoryviews are to be bytes-like objects they should be > hashable (at least when readonly). So what specific hash algorithm do

[issue15800] Closing of sys.std* files in gzip test.

2012-08-29 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I can not imagine how it can be tested. Correction does not affect the current behavior. -- ___ Python tracker ___ __

[issue13769] json.dump(ensure_ascii=False) return str instead of unicode

2012-08-29 Thread Petri Lehtinen
Petri Lehtinen added the comment: Attached an updated patch, which is more explicit on what ensure_ascii actually does. -- Added file: http://bugs.python.org/file27049/issue13769_v2.patch ___ Python tracker __

[issue15798] subprocess.Popen() fails if 0, 1 or 2 descriptor is closed

2012-08-29 Thread Gregory P. Smith
Gregory P. Smith added the comment: Here's my initial fix. If fcntl(errpipe_write, F_DUPFD, 3) is widely available this could be shrunk a bit to avoid the for loop potentially calling dup a few times and tracking the wasted fds to close later. Otherwise if it isn't I'd rather not bother with

[issue15814] memoryview: equality-hash invariant

2012-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: > I think the proper solution is to make memoryview objects unhashable. Disagreed. If memoryviews are to be bytes-like objects they should be hashable (at least when readonly). > Any other approach will have flaws of some kind. Not more so than equality betwee

[issue15814] memoryview: equality-hash invariant

2012-08-29 Thread Martin v . Löwis
Martin v. Löwis added the comment: I think the proper solution is to make memoryview objects unhashable. Any other approach will have flaws of some kind. -- ___ Python tracker _

[issue15798] subprocess.Popen() fails if 0, 1 or 2 descriptor is closed

2012-08-29 Thread Gregory P. Smith
Gregory P. Smith added the comment: F_DUPFD_CLOEXEC appears exclusive to modern Linux kernels. Any idea how wide spread support for plain F_DUPFD is? If that is "everywhere" the code I've just whipped up could lose a lot of loops... -- ___ Python

[issue15573] Support unknown formats in memoryview comparisons

2012-08-29 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis : -- resolution: -> fixed ___ Python tracker ___ ___ Python-bugs-list mailing list Uns

[issue15798] subprocess.Popen() fails if 0, 1 or 2 descriptor is closed

2012-08-29 Thread Aleksey Filippov
Aleksey Filippov added the comment: It may be implemented simplier. fcntl(fd, F_DUPFD_CLOEXEC, min_fd_number) will allocate new fd at least min_fd_number. So, it is not necessary to do a lot of dup() calls. -- ___ Python tracker

[issue15805] Add stdout redirection tool to contextlib

2012-08-29 Thread Brett Cannon
Brett Cannon added the comment: So Alex's point is valid: the examples in the unittest.mock.patch docs shows how to do this (http://docs.python.org/dev/py3k/library/unittest.mock.html#patch). So this could be simplified to: def redirect_stdout(replacement=None): return unittest.mock.patch('

[issue15573] Support unknown formats in memoryview comparisons

2012-08-29 Thread Stefan Krah
Stefan Krah added the comment: I agree that this isn't a blocker due to the limited use of memoryview hashing. Tracking this in #15814. -- status: open -> closed ___ Python tracker _

[issue15814] memoryview: equality-hash invariant

2012-08-29 Thread Stefan Krah
New submission from Stefan Krah: The new PEP-3118 equality definition from #15573 that is based on element-wise comparisons breaks the equality-hash invariant: >>> from _testbuffer import ndarray >>> x = ndarray([1,2,3], shape=[3], format='f') >>> y = ndarray([1,2,3], shape=[3], format='B') >>>

[issue11776] Constructor signatures missing in types module documentation

2012-08-29 Thread Mike Hoy
Mike Hoy added the comment: This should be all the requested changes. I've gone over the table entries (at least the first one, CodeType, with bitdancer on IRC). I've removed the descriptive language from below the table and added it to the table. Leaving the text below the table to deal with

[issue15811] ElementTree.write() raises TypeError when xml_declaration = True and encoding is a unicode string

2012-08-29 Thread David Buxton
David Buxton added the comment: Only a problem because I am using unicode_literals and it didn't occur to me to use `str('utf-8')` to get a native string on both 2+3. Much the best solution, thank you. But that is still a little smelly - I think what I want ideally is for ElementTree to accep

[issue15811] ElementTree.write() raises TypeError when xml_declaration = True and encoding is a unicode string

2012-08-29 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: Why is it a problem? Encoding must be a text string: encoding='utf-8' works with both Python 2 and 3. Or if you used "from __future__ import unicode_literals", str('utf-8') works as well. -- nosy: +amaury.forgeotdarc ___

[issue15573] Support unknown formats in memoryview comparisons

2012-08-29 Thread Martin v . Löwis
Martin v. Löwis added the comment: 1. I STRONGLY request to take hashing out of this issue. The only further action that this issue can have is complete reversal of the patch, starting over. Now that the issue has been resolved, a NEW issue arises, namely that hashing is inconsistent with equa

[issue15798] subprocess.Popen() fails if 0, 1 or 2 descriptor is closed

2012-08-29 Thread Gregory P. Smith
Gregory P. Smith added the comment: Yes, something along the lines of that patch is what I was thinking. BTW, this is only necessary for the errpipe_write fd. errpipe_read is for the parent process. I'm going to do it within _create_pipe so that the optimal _posixsubprocess.cloexec_pipe pip

[issue15811] ElementTree.write() raises TypeError when xml_declaration = True and encoding is a unicode string

2012-08-29 Thread Eli Bendersky
Eli Bendersky added the comment: Thanks for the patch, David. Alas, due to personal reasons I will not be able to work on core Python in the next 2-3 months. I may throw in a review here and there, but that's not a promise ;-) -- ___ Python tracker

[issue15811] ElementTree.write() raises TypeError when xml_declaration = True and encoding is a unicode string

2012-08-29 Thread David Buxton
David Buxton added the comment: A patch against the current default branch to add tests for the xml_declaration keyword argument. This passes when applied to the 2.7 branch too. This does NOT test whether one can use both bytes/unicode for the encoding argument. It just uses the native string

[issue15813] Python function decorator scope losing variable

2012-08-29 Thread R. David Murray
R. David Murray added the comment: When you assign a value to param1 it becomes a local variable, thus the error. You should ask for help on your scoping questions from the python-tutor list or the general python-list. -- nosy: +r.david.murray resolution: -> invalid stage: -> commit

[issue15813] Python function decorator scope losing variable

2012-08-29 Thread V.E.O
New submission from V.E.O: I just learned python @ decorator, it's cool, but soon I found my modified code coming out weird problems. def with_wrapper(param1): def dummy_wrapper(fn): print param1 param1 = 'new' fn(param1) return dummy_wrapper def dummy(): @w

[issue15591] when building the extensions, stdout is lost when stdout is redirected

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

[issue15573] Support unknown formats in memoryview comparisons

2012-08-29 Thread Stefan Krah
Stefan Krah added the comment: I'm trying to think of an optimization for the native types. It should be possible to cast any native type element to unsigned char and use the truncated value for the bytes hash. Well, for double probably it's required to go from double -> int64_t -> unsigned cha

[issue9860] Building python outside of source directory fails

2012-08-29 Thread Trent Nelson
Changes by Trent Nelson : -- nosy: +trent ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org

[issue15812] inspect.getframeinfo() cannot show first line

2012-08-29 Thread Richard Oudkerk
New submission from Richard Oudkerk: When inspect.getframeinfo() tries to collect lines of context it never shows the first line (unless context is as big as the number of lines in the file). The relevant code is start = lineno - 1 - context//2 try: lines, lnum = fi

[issue15803] Incorrect docstring on ConfigParser.items()

2012-08-29 Thread Nathan Trapuzzano
Nathan Trapuzzano added the comment: Looks like the file has about an equal number of single- and double-spaces after periods. -- ___ Python tracker ___

[issue15809] IDLE console uses incorrect encoding.

2012-08-29 Thread Martin v . Löwis
Martin v. Löwis added the comment: The problem is that IDLE passes an UTF-8 encoded source string to compile, and compile, in the absence of a source encoding, uses the PEP 263 default source encoding, i.e. Latin-1. As the consequence, the variable s has the value u'\\xd0\\xa0\\xd1\\x83\\xd1\

[issue15803] Incorrect docstring on ConfigParser.items()

2012-08-29 Thread Chris Jerdonek
Chris Jerdonek added the comment: > If the double space is used elsewhere in the same document, You can see one above the change in the patch file. -- ___ Python tracker ___ ___

[issue15803] Incorrect docstring on ConfigParser.items()

2012-08-29 Thread Ezio Melotti
Ezio Melotti added the comment: While I like to have two spaces after the period, this convenction is not enforced, and it usually depends on the style used in the file. If the double space is used elsewhere in the same document, then it should be preserved, otherwise using a single space is OK

[issue15810] assertSequenceEqual should be fired when comparing sequence subclasses

2012-08-29 Thread Ezio Melotti
Ezio Melotti added the comment: The assertSequenceEqual docs[0] say: """ This method is not called directly by assertEqual(), but it’s used to implement assertListEqual() and assertTupleEqual(). """ The asserEqual docs[1] say: """ In addition, if first and second are the exact same type and one

[issue15803] Incorrect docstring on ConfigParser.items()

2012-08-29 Thread Chris Jerdonek
Chris Jerdonek added the comment: This is a nit, but there should be two spaces after the period: +each option in the section. Otherwise, return a list of tuples with -- nosy: +cjerdonek ___ Python tracker

[issue15803] Incorrect docstring on ConfigParser.items()

2012-08-29 Thread R. David Murray
Changes by R. David Murray : -- stage: -> patch review type: enhancement -> behavior ___ Python tracker ___ ___ Python-bugs-list mail

[issue15803] Incorrect docstring on ConfigParser.items()

2012-08-29 Thread R. David Murray
Changes by R. David Murray : -- nosy: +lukasz.langa ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail

[issue15810] assertSequenceEqual should be fired when comparing sequence subclasses

2012-08-29 Thread R. David Murray
R. David Murray added the comment: That sounds like a bug. -- title: assertSequenceEqual should be fired when comparing sequences -> assertSequenceEqual should be fired when comparing sequence subclasses ___ Python tracker

[issue15810] assertSequenceEqual should be fired when comparing sequences

2012-08-29 Thread Florent Xicluna
Florent Xicluna added the comment: you're probably right. I will continue to use assertSequenceEqual for my use cases. Actually, what confused me is that these assertions are True: class T(tuple): pass class L(list): pass assertEqual(T('ab'), tuple('ab')) assertEqual(L('ab'), list('ab')) And

[issue15710] logging module crashes in Python 2.7.3 for handler.setLevel(long)

2012-08-29 Thread Roundup Robot
Roundup Robot added the comment: New changeset 8ba6d8fc9740 by Vinay Sajip in branch '2.7': Closes #15710: accept long in _checkLevel. http://hg.python.org/cpython/rev/8ba6d8fc9740 -- nosy: +python-dev resolution: invalid -> fixed stage: -> committed/rejected status: open -> closed ___

[issue15807] Bogus versionchanged note in logging.handlers.MemoryHandler doc

2012-08-29 Thread Roundup Robot
Roundup Robot added the comment: New changeset 48f54b6bf0ef by Vinay Sajip in branch '2.7': Closes #15807: Removed incorrect directive from help. http://hg.python.org/cpython/rev/48f54b6bf0ef -- nosy: +python-dev resolution: -> fixed stage: needs patch -> committed/rejected status: open

[issue15811] ElementTree.write() raises TypeError when xml_declaration = True and encoding is a unicode string

2012-08-29 Thread Florent Xicluna
Changes by Florent Xicluna : -- components: +Library (Lib) nosy: +eli.bendersky, flox ___ Python tracker ___ ___ Python-bugs-list mail

[issue15765] test_getcwd_long_pathnames (in test_posix) kills NetBSD

2012-08-29 Thread Roundup Robot
Roundup Robot added the comment: New changeset bfa5d0ddfbeb by Trent Nelson in branch '2.7': Issue #15765: Fix quirky NetBSD getcwd() behaviour. http://hg.python.org/cpython/rev/bfa5d0ddfbeb -- nosy: +python-dev ___ Python tracker

[issue9185] os.getcwd causes infinite loop on solaris

2012-08-29 Thread Roundup Robot
Roundup Robot added the comment: New changeset bfa5d0ddfbeb by Trent Nelson in branch '2.7': Issue #15765: Fix quirky NetBSD getcwd() behaviour. http://hg.python.org/cpython/rev/bfa5d0ddfbeb -- nosy: +python-dev ___ Python tracker

[issue15810] assertSequenceEqual should be fired when comparing sequences

2012-08-29 Thread R. David Murray
R. David Murray added the comment: I think it works as it should (you shouldn't be asserting that a sequence and a tuple are equal, after all). Once you fix your test, you'll get the pretty print if there are still differences. -- nosy: +michael.foord, r.david.murray

[issue15811] ElementTree.write() raises TypeError when xml_declaration = True and encoding is a unicode string

2012-08-29 Thread David Buxton
New submission from David Buxton: The problem is an inconsistency between the ElementTree.write() method on Python 2 and 3 when xml_declaration is True. For Python 2.7 the encoding argument MUST NOT be a unicode string. For Python 3.2 the encoding argument MUST be a unicode string. On Python

[issue15810] assertSequenceEqual should be fired when comparing sequences

2012-08-29 Thread Florent Xicluna
New submission from Florent Xicluna: When writing unittest, I noticed that I need to uses assertSequenceEqual explicitly when comparing sequences of different kinds. If I only use the plain assertEqual, it does not generate pretty diffs. On second thought, I think it could be fixed in unittest

[issue15809] IDLE console uses incorrect encoding.

2012-08-29 Thread alex hartwig
alex hartwig added the comment: Text is correct. See attachment. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscri

[issue15809] IDLE console uses incorrect encoding.

2012-08-29 Thread Andrew Svetlov
Changes by Andrew Svetlov : -- title: Строки из IDLE поступают в неверной кодировке. -> IDLE console uses incorrect encoding. ___ Python tracker ___

[issue15809] Строки из IDLE поступают в неверной кодировке.

2012-08-29 Thread Ezio Melotti
Ezio Melotti added the comment: Looks like your IDLE is set to use latin-1, but s.encode('latin1') should have failed with an UnicodeEncodeError. Are you sure you copied the snippet correctly? The default source encoding refers to the .py files you open with IDLE, and doesn't affect the encod

[issue15809] Строки из IDLE поступают в неверной кодировке.

2012-08-29 Thread alex hartwig
New submission from alex hartwig: Это из IDLE: Python 2.7.2+ (default, Oct 4 2011, 20:03:08) [GCC 4.6.1] on linux2 Type "copyright", "credits" or "license()" for more information. >>> import sys >>> import locale >>> sys.getdefaultencoding() 'ascii' >>> locale.getpreferredencoding() 'UTF-8' >>>

[issue15513] Correct __sizeof__ support for pickle

2012-08-29 Thread Aaron Iles
Changes by Aaron Iles : -- nosy: +aliles ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org

[issue15695] Correct __sizeof__ support for StgDict

2012-08-29 Thread Aaron Iles
Changes by Aaron Iles : -- nosy: +aliles ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org

[issue15696] Correct __sizeof__ support for mmap

2012-08-29 Thread Aaron Iles
Changes by Aaron Iles : -- nosy: +aliles ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org

[issue15436] __sizeof__ is not documented

2012-08-29 Thread Aaron Iles
Changes by Aaron Iles : -- nosy: +aliles ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org

[issue15490] Correct __sizeof__ support for StringIO

2012-08-29 Thread Aaron Iles
Changes by Aaron Iles : -- nosy: +aliles ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org

[issue15510] textwrap.wrap('') returns empty list

2012-08-29 Thread Chris Jerdonek
Chris Jerdonek added the comment: Attaching an updated patch that improves the organization of the new test cases (test ordering, test names, and test comments, etc). -- Added file: http://bugs.python.org/file27043/issue-15510-4.patch ___ Python trac

[issue13266] Add inspect.unwrap(f) to easily unravel "__wrapped__" chains

2012-08-29 Thread Aaron Iles
Changes by Aaron Iles : -- nosy: +aliles ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org

[issue15806] Add context manager for the "try: ... except: pass" pattern

2012-08-29 Thread Jesús Cea Avión
Changes by Jesús Cea Avión : -- nosy: +jcea ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue15475] Correct __sizeof__ support for itertools

2012-08-29 Thread Aaron Iles
Changes by Aaron Iles : -- nosy: +aliles ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org

[issue15800] Closing of sys.std* files in gzip test.

2012-08-29 Thread Jesús Cea Avión
Jesús Cea Avión added the comment: Test? -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue15784] OSError.__str__() should distinguish between errno and winerror

2012-08-29 Thread Richard Oudkerk
Richard Oudkerk added the comment: The changeset is 2e587b9bae35. Georg, could you copy it to your release branch please. -- ___ Python tracker ___ _

[issue15808] Possibility of setting custom key bindings for "Additional help sources" menu items

2012-08-29 Thread Rostyslav Dzinko
Changes by Rostyslav Dzinko : -- versions: -3rd party ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://m

[issue15808] Possibility of setting custom key bindings for "Additional help sources" menu items

2012-08-29 Thread Rostyslav Dzinko
New submission from Rostyslav Dzinko: There's a possibility to add additional help sources in IDLE via Options -> Configure IDLE... -> General -> Additional Help Sources Use case: > If someone wants to download certain version of Python documentation in HTML > and specify local "index.htm

[issue15806] Add context manager for the "try: ... except: pass" pattern

2012-08-29 Thread Eric V. Smith
Eric V. Smith added the comment: While the classmethod version has some appeal, it doesn't extend well to handling multiple exception types. I'm -0 on this, in any event. I think the original code is more clear. Why force people to learn (or recognize) a second idiom for something so simple?

[issue15806] Add context manager for the "try: ... except: pass" pattern

2012-08-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: If this is desirable then I think it would be better as a classmethod of Exception: with KeyError.trap(): do_something() -- nosy: +pitrou ___ Python tracker _

[issue15802] Nonsensical test for mailbox

2012-08-29 Thread Chris Jerdonek
Chris Jerdonek added the comment: > In other words, (int(groups[0]), int(groups[1])) >= (int(previous_groups[0]), > int(previous_groups[1])). Why not use a single self.assertGreaterEqual() on the pairs (with an appropriate change in the message)? It currently hand-codes the lexicographic comp

[issue13405] Add DTrace probes

2012-08-29 Thread Robert Kern
Changes by Robert Kern : -- nosy: -robert.kern ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyt

[issue13405] Add DTrace probes

2012-08-29 Thread Ronald Oussoren
Ronald Oussoren added the comment: It's rather annoying that dtrace doesn't honor the PATH variable, and when you run the strings command on /usr/lib/libdtrace.dylib you'll see that it hardcodes the use of gcc (not even cpp or clang). I've filed radar 12196604 in Apple's tracker, although it i

[issue15807] Bogus versionchanged note in logging.handlers.MemoryHandler doc

2012-08-29 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +vinay.sajip stage: -> needs patch versions: -Python 2.6 ___ Python tracker ___ ___ Python-bugs-l

[issue15807] Bogus versionchanged note in logging.handlers.MemoryHandler doc

2012-08-29 Thread Gunnlaugur Thor Briem
New submission from Gunnlaugur Thor Briem: In logging.handlers.MemoryHandler documentation: “Changed in version 2.6: credentials was added.” There's no `credentials` anywhere nearby, and at first glance I can't see anything new in `MemoryHandler` when this was introduced. Presumably the `.. v

[issue15751] Support subinterpreters in the GIL state API

2012-08-29 Thread Graham Dumpleton
Graham Dumpleton added the comment: If PyGILState_STATE is a struct, what happens if someone naively does: PyGILState_Release(PyGILState_UNLOCKED) I know they shouldn't, but I actually do this in mod_wsgi in one spot as it is otherwise a pain to carry around the state when I know for sure if w

[issue15806] Add context manager for the "try: ... except: pass" pattern

2012-08-29 Thread Ezio Melotti
Ezio Melotti added the comment: > As with many context managers, a key benefit here is > in the priming effect for readers. The "focus" is mostly on what it's being executed rather than what it's being ignored though. "Do this operation and ignore these exceptions if they occur" vs. "Ignore t

[issue15806] Add context manager for the "try: ... except: pass" pattern

2012-08-29 Thread Nick Coghlan
Nick Coghlan added the comment: (Note: I'm not yet convinced this is a good idea. I'm definitely considering it, though) As with many context managers, a key benefit here is in the priming effect for readers. In this code: try: # Whatever except (A, B, C): pass the read

[issue13405] Add DTrace probes

2012-08-29 Thread Samuel John
Samuel John added the comment: dtrace ignores PATH and CC and CPP. I tried that already :/ Of course I could just install the command line tools. But still it's a shame since all the tools are already there. -- ___ Python tracker

  1   2   >