[issue11477] Bug in code dispatching based on internal slots

2011-03-15 Thread Nick Coghlan
Changes by Nick Coghlan : Removed file: http://bugs.python.org/file21220/2f5db44c98f2.diff ___ Python tracker <http://bugs.python.org/issue11477> ___ ___ Python-bug

[issue11477] Bug in code dispatching based on internal slots

2011-03-15 Thread Nick Coghlan
Nick Coghlan added the comment: I think the roundup/Hg integration may be getting confused by the merges of the cpython main line of development with my sandbox. -- ___ Python tracker <http://bugs.python.org/issue11

[issue11477] Bug in code dispatching based on internal slots

2011-03-15 Thread Nick Coghlan
Nick Coghlan added the comment: MvL says the review creation script should be able to cope with the rdiff output within the next day or so. -- ___ Python tracker <http://bugs.python.org/issue11

[issue8754] ImportError: quote bad module name in message

2011-03-15 Thread Nick Coghlan
Changes by Nick Coghlan : -- nosy: +ncoghlan ___ Python tracker <http://bugs.python.org/issue8754> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue1559549] ImportError needs attributes for module and file name

2011-03-15 Thread Nick Coghlan
Changes by Nick Coghlan : -- nosy: +ncoghlan ___ Python tracker <http://bugs.python.org/issue1559549> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue11559] Increase test coverage in dis module

2011-03-15 Thread Nick Coghlan
Changes by Nick Coghlan : -- nosy: +ncoghlan ___ Python tracker <http://bugs.python.org/issue11559> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue9263] Try to print repr() when an C-level assert fails (in the garbage collector, beyond?)

2011-03-15 Thread Nick Coghlan
Nick Coghlan added the comment: I'd suggest calling Py_FatalError rather than calling abort() directly in _PyObject_AssertFailed, but otherwise this looks like a nice improvement over standard C asserts for state invariants that may be broken by buggy C extensions. For the tests, t

[issue11549] Rewrite peephole to work on AST

2011-03-15 Thread Nick Coghlan
Changes by Nick Coghlan : -- nosy: +brett.cannon ___ Python tracker <http://bugs.python.org/issue11549> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue11561] "coverage" of Python regrtest cannot see initial import of libs

2011-03-15 Thread Nick Coghlan
Changes by Nick Coghlan : -- nosy: +brett.cannon, ncoghlan ___ Python tracker <http://bugs.python.org/issue11561> ___ ___ Python-bugs-list mailing list Unsub

[issue11477] Bug in code dispatching based on internal slots

2011-03-15 Thread Nick Coghlan
Nick Coghlan added the comment: We know, I left it there to help MvL debug the issues in the diff generator. The version I created with the rdiff extension is correct though, and Martin fixed the Reitveld integration to handle the extra lines at the start of the diff. I wouldn't act

[issue11549] Rewrite peephole to work on AST

2011-03-15 Thread Nick Coghlan
Nick Coghlan added the comment: The review links didn't come up automatically because 336137a359ae isn't a hg.python.org/cpython revision ID. -- ___ Python tracker <http://bugs.python.o

[issue11549] Rewrite peephole to work on AST

2011-03-15 Thread Nick Coghlan
Nick Coghlan added the comment: No need, since you manually created a review on appspot. The local Reitveld links are just a convenience that can avoid the need to manually create a review instance. -- ___ Python tracker <http://bugs.python.

[issue11562] += on list inside a tuple raises TypeError but succeeds anyway

2011-03-16 Thread Nick Coghlan
Nick Coghlan added the comment: As Daniel noted, this behaviour is in accordance with the language definition. It's obscure and surprising behaviour, but it isn't wrong. -- nosy: +ncoghlan resolution: -> invalid stage: test needed -> committed/rejected status

[issue11320] Usage of API method Py_SetPath causes errors in Py_Initialize() (Posix ony))

2011-03-16 Thread Nick Coghlan
Nick Coghlan added the comment: Note that this will be fixed for 3.3, as siteconfig will be updated to use static data (generated during the build process) rather than relying on build artifacts being available at runtime. However, virtualenv (et al) will still need to provide the relevant

[issue11560] Expand test coverage in shutil

2011-03-16 Thread Nick Coghlan
Changes by Nick Coghlan : -- assignee: -> ncoghlan nosy: +ncoghlan ___ Python tracker <http://bugs.python.org/issue11560> ___ ___ Python-bugs-list mai

[issue11572] bring Lib/copy.py to 100% coverage

2011-03-16 Thread Nick Coghlan
Changes by Nick Coghlan : -- assignee: -> ncoghlan nosy: +ncoghlan ___ Python tracker <http://bugs.python.org/issue11572> ___ ___ Python-bugs-list mai

[issue11572] bring Lib/copy.py to 100% coverage

2011-03-16 Thread Nick Coghlan
Nick Coghlan added the comment: Alexander: the coverage problem in this case has to do with it incorrectly handling an "else:" clause on a loop (it doesn't adjust the expected target for an empty sequence to be the body of the else clause) Benjamin: the pragma question is

[issue11548] Passing format= to unpack_archive fails

2011-03-16 Thread Nick Coghlan
Changes by Nick Coghlan : -- assignee: -> ncoghlan nosy: +ncoghlan ___ Python tracker <http://bugs.python.org/issue11548> ___ ___ Python-bugs-list mai

[issue11577] testcase for exception binhex.Error

2011-03-16 Thread Nick Coghlan
Changes by Nick Coghlan : -- nosy: +ncoghlan ___ Python tracker <http://bugs.python.org/issue11577> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue11577] testcase for exception binhex.Error

2011-03-16 Thread Nick Coghlan
Nick Coghlan added the comment: unittest provides a utility to help with testing that correct exceptions are raised: http://docs.python.org/dev/library/unittest#unittest.TestCase.assertRaises -- ___ Python tracker <http://bugs.python.

[issue11549] Rewrite peephole to work on AST

2011-03-16 Thread Nick Coghlan
Nick Coghlan added the comment: I've been focusing on softer targets during the sprints - I'll dig into this once I'm back home and using my desktop machine again. -- ___ Python tracker <http://bugs.pyt

[issue11477] Bug in code dispatching based on internal slots

2011-03-16 Thread Nick Coghlan
Nick Coghlan added the comment: The draft code is now only on the "respect_LHS_precedence" branch of my sandbox repository. -- ___ Python tracker <http://bugs.python.o

[issue11477] Bug in code dispatching based on internal slots

2011-03-16 Thread Nick Coghlan
Nick Coghlan added the comment: Well, there and in the named diff file on here, of course. -- ___ Python tracker <http://bugs.python.org/issue11477> ___ ___ Pytho

[issue11505] string.py increased test coverage

2011-03-17 Thread Nick Coghlan
Nick Coghlan added the comment: Reopening to double check with Jerome's patch. -- resolution: fixed -> stage: committed/rejected -> commit review status: closed -> open ___ Python tracker <http://bugs.pyth

[issue11577] testcase for exception binhex.Error

2011-03-17 Thread Nick Coghlan
Nick Coghlan added the comment: This is fixed on default as well, I just stuffed the merge so the history looks odd and the integration script didn't pick it up. You can see the additional changes I made in the linked changeset: - try/except with a flag to clean up implicitly created

[issue11572] bring Lib/copy.py to 100% coverage

2011-03-19 Thread Nick Coghlan
Nick Coghlan added the comment: Regarding "__reduce__", other readers will have the same question Éric did, so that point should definitely go in a comment after the "__reduce_ex__" check. -- ___ Python tracker <http://bug

[issue10977] Concrete object C API needs abstract path for subclasses of builtin types

2011-03-20 Thread Nick Coghlan
Nick Coghlan added the comment: It's largely a backwards compatibility hack, but the concrete methods also have an optimised fast path that the generic methods lack. So (for example), PyList_SetItem would now mean "this is *probably* a list, so check for that and use the fast p

[issue11627] segfault raising an arbitrary object as an exception

2011-03-22 Thread Nick Coghlan
Nick Coghlan added the comment: Note that this test code: def raise_(): raise MyException self.assertRaises(TypeError, raise_) can be simplified to: with self.assertRaises(TypeError): raise MyException in all currently maintained branches

[issue11647] function decorated with a context manager can only be invoked once

2011-03-22 Thread Nick Coghlan
Nick Coghlan added the comment: On Wed, Mar 23, 2011 at 12:04 PM, Antoine Pitrou wrote: > Clearly there is a problem in the API or its implementation, as in a function > decorated with a context manager can only be invoked once! This isn't good... The problem stems from a fundam

[issue9523] Improve dbm modules

2011-03-23 Thread Nick Coghlan
Changes by Nick Coghlan : -- nosy: +ncoghlan ___ Python tracker <http://bugs.python.org/issue9523> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue11647] function decorated with a context manager can only be invoked once

2011-03-23 Thread Nick Coghlan
Nick Coghlan added the comment: > The former sounds like fixing the bug, the latter like removing > functionality. So yes, I prefer the former... The reason I'm reluctant is that it makes for a fundamental change in behaviour between the use of an @contextmanager definition a

[issue11455] issue a warning when populating a CPython type dict with non-string keys

2011-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: Thomas, I know you've been working on this post-Pycon. Could you please take a look at Daniel's patch and/or publish your own. -- assignee: -> twouters nosy: +ncoghlan, twouters ___ Python t

[issue11477] Bug in code dispatching based on internal slots

2011-03-24 Thread Nick Coghlan
Changes by Nick Coghlan : Added file: http://bugs.python.org/file21383/8bd713a823b5.diff ___ Python tracker <http://bugs.python.org/issue11477> ___ ___ Python-bugs-list m

[issue11477] Bug in code dispatching based on internal slots

2011-03-24 Thread Nick Coghlan
Nick Coghlan added the comment: Martin and I are still experimenting with this issue as a test case for the remote repository diff calculator, so apologies for the noise as we add and remove patch files. -- ___ Python tracker <h

[issue11682] PEP 380 reference implementation for 3.3

2011-03-25 Thread Nick Coghlan
New submission from Nick Coghlan : Creating an issue to track efforts to forward port the PEP 380 reference implementation to Python 3.3. -- hgrepos: 11 messages: 132213 nosy: ncoghlan priority: normal severity: normal status: open title: PEP 380 reference implementation for 3.3

[issue7284] argparse - display version in usage by default

2011-03-26 Thread Nick Coghlan
Nick Coghlan added the comment: On Sat, Mar 26, 2011 at 9:14 PM, anatoly techtonik wrote: > A pity that before argparse replaced optparse, there was no research > made to gather the output from various console tools to see how > argparse really saves people from reinventing their

[issue11690] Add "communication" FAQ to devguide

2011-03-26 Thread Nick Coghlan
New submission from Nick Coghlan : It would be good to supplement the "here's the list of mailing lists" (etc) section in the devguide [1] with a more task oriented communications FAQ of the form "If you are asking about topic A, then ask in forums X, Y or Z". (wher

[issue11681] -b option undocumented

2011-03-27 Thread Nick Coghlan
Nick Coghlan added the comment: Even "from __future__ import unicode_literals" doesn't make it do anything. Perhaps Christian merged it by mistake in [5341b30b1812]? -- nosy: +ncoghlan ___ Python tracker <http://bugs.pyt

[issue11549] Rewrite peephole to work on AST

2011-03-27 Thread Nick Coghlan
Nick Coghlan added the comment: Finally got around to reviewing this (just a visual scan at this stage) - thanks for the effort. These are mostly "big picture" type comments, so I'm keeping them here rather than burying them amongst all the details in the code review tool.

[issue11549] Rewrite peephole to work on AST

2011-03-27 Thread Nick Coghlan
Nick Coghlan added the comment: I think the biggest thing to take out of my review is that I strongly encourage deferring the changes for 5(b) and 5(c). I like the basic idea of using a template-based approach to try to get rid of a lot of the boilerplate code currently needed for AST

[issue11549] Rewrite peephole to work on AST

2011-03-27 Thread Nick Coghlan
Nick Coghlan added the comment: OK, I missed the fact that the new optimisation pass isn't run under PyCF_ONLY_AST. However, as Eugene picked up, my concern is actually with the collapsing of Str/Num/Bytes/Ellipsis into the new Lit node, and the changes to the way None/True/Fals

[issue11610] Improving property to accept abstract methods

2011-03-28 Thread Nick Coghlan
Changes by Nick Coghlan : -- nosy: +ncoghlan ___ Python tracker <http://bugs.python.org/issue11610> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue11704] functools.partial doesn't create bound methods

2011-03-28 Thread Nick Coghlan
Nick Coghlan added the comment: True, this could be documented better - flagging as a docs bug. (It is mentioned at the bottom of http://docs.python.org/library/functools.html#partial-objects, but that could be referenced better from the main documentation of the function higher up in the

[issue11647] function decorated with a context manager can only be invoked once

2011-03-29 Thread Nick Coghlan
Nick Coghlan added the comment: Part of the problem is that there was a specific reason we didn't go with lazy initialisation of the internal generator: lazy initialisation means there can be an arbitrary delay between creation of the context manager and the creation of the under

[issue11549] Rewrite peephole to work on AST

2011-03-29 Thread Nick Coghlan
Nick Coghlan added the comment: Eugene: I suggest raising the question on python-dev. The answer potentially affects the PEP 380 patch as well (which adds a new attribute to the "Yield" node). Anatoly: If you just want to get a feel for the kind of AST various pieces of code pro

[issue11710] Landing pages in docs for standard library packages

2011-03-29 Thread Nick Coghlan
New submission from Nick Coghlan : http://docs.python.org/py3k/urllib errors out rather than returning an index page for the modules that are part of the urllib package. This index page could also link to the HOWTO at http://docs.python.org/py3k/howto/urllib2.html The following packages have

[issue11647] function decorated with a context manager can only be invoked once

2011-03-29 Thread Nick Coghlan
Nick Coghlan added the comment: Because I don't want to conflate the two APIs. ContextDecorator can be used with *any* context manager, and some of those may already be using their copy semantics for something else. If anyone ever writes the __with__ PEP, then ContextDecorator._recreat

[issue11677] make test has horrendous performance on an ecryptfs

2011-03-29 Thread Nick Coghlan
Nick Coghlan added the comment: If support for a top level temporary directory is added, test.support should acquire alternatives to the tempfile module tools to make it easy for tests that create their own temporary files to respect that naming scheme. In particular

[issue11677] make test has horrendous performance on an ecryptfs

2011-03-29 Thread Nick Coghlan
Nick Coghlan added the comment: To control where mkdtemp() puts files, you could just use the "dir" argument (and you can use tempfile.gettempdir() beforehand if you want that location to be inside the normal temp directory) -- ___ Pyth

[issue4657] Doctest gets line numbers wrongs with <> in name

2011-03-31 Thread Nick Coghlan
Nick Coghlan added the comment: Note that this appears to have been fixed already in the 3.x series (I haven't investigated the differences to see what makes this a 2.x only problem) -- versions: +Python 2.7 ___ Python tracker

[issue11715] Building Python on multiarch Debian and Ubuntu

2011-04-01 Thread Nick Coghlan
Nick Coghlan added the comment: 2.5: -1 2.6: -0 3.1: +0 As I see it, a large part of the "security fixes only" rule is for the benefit of folks auditing those security fixes, as it means there's very little noise in the branch to confuse the matter. --

[issue11710] Landing pages in docs for standard library packages

2011-04-01 Thread Nick Coghlan
Nick Coghlan added the comment: That link goes to a 404 error page for me. -- ___ Python tracker <http://bugs.python.org/issue11710> ___ ___ Python-bugs-list m

[issue11710] Landing pages in docs for standard library packages

2011-04-01 Thread Nick Coghlan
Nick Coghlan added the comment: Oh, I see the confusion - yeah, the missing "library" in the URL in my first post was just a typo. It was actually present in my test URLs (otherwise the 4 packages with landing pages wouldn't have worked). The problem in 2.7 is smaller, since

[issue7443] test.support.unlink issue on Windows platform

2011-04-01 Thread Nick Coghlan
Nick Coghlan added the comment: I'll throw in my 2 cents as to a possible way forward: - fix test.support.unlink in all current maintenance branches (2.7, 3.1, 3.2, default) - expose the feature to users as "shutil.rmfile" for 3.3 -- ___

[issue11707] Create C version of functools.cmp_to_key()

2011-04-02 Thread Nick Coghlan
Changes by Nick Coghlan : -- nosy: +ncoghlan ___ Python tracker <http://bugs.python.org/issue11707> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue10977] Concrete object C API needs abstract path for subclasses of builtin types

2011-04-05 Thread Nick Coghlan
Nick Coghlan added the comment: I may have found another use case for this functionality. Currently, the Python code in heapq.py accepts arbitrary sequences (that are sufficiently compatible with the Sequence ABC), but the C code in _heapq only permits use of a concrete list. The two

[issue10977] Concrete object C API needs abstract path for subclasses of builtin types

2011-04-05 Thread Nick Coghlan
Nick Coghlan added the comment: I added a few commments on Daniel's draft patch. However, I'm getting nervous about the performance impact of all these extra pointer comparisons. We should probably hold off on this until more of the macro benchmark suite runs on Py3k so we can get

[issue10977] Concrete object C API needs abstract path for subclasses of builtin types

2011-04-06 Thread Nick Coghlan
Nick Coghlan added the comment: "should" is a wonderful word when it comes to external APIs. We currently have a couple of problems: 1. The concrete APIs will fail noisily if given an instance of something that isn't a list, but may fail *silently* if given a subclass that

[issue10977] Concrete object C API needs abstract path for subclasses of builtin types

2011-04-06 Thread Nick Coghlan
Nick Coghlan added the comment: 1. It's an external API. We *don't control* most of the potentially broken code, so saying "just fix the call sites" effectively solves nothing and leaves classes like OrderedDict at risk of subtle silent corruption whenever they are pas

[issue10977] Concrete object C API needs abstract path for subclasses of builtin types

2011-04-06 Thread Nick Coghlan
Nick Coghlan added the comment: Having convinced myself that Raymond's original suggestion can't be implemented safely, I have an alternative (arguably even more radical) proposal: Deprecate the public concrete API functions that modify object state. Put an underscore in front o

[issue10977] Concrete object C API needs abstract path for subclasses of builtin types

2011-04-06 Thread Nick Coghlan
Nick Coghlan added the comment: Changing the affected components. Antoine and Benjamin are right, this needs to be handled as a documentation and education problem. Raymond's suggestion can too easily trigger infinite recursion and mine would block legitimate use cases in 3rd party

[issue10977] Concrete object C API needs abstract path for subclasses of builtin types

2011-04-06 Thread Nick Coghlan
Nick Coghlan added the comment: I thought about a warning, but the problem is that a subclass using the concrete API as part of its *implementation* of the associated slot or method is actually perfectly correct usage. I'm not sure this is enough to give up on the idea of OrderedDict be

[issue11794] Backport new logging docs to 2.7

2011-04-07 Thread Nick Coghlan
New submission from Nick Coghlan : Vinay did some great work on the logging documentation for 3.2 (http://docs.python.org/py3k/library/logging). However, a lot of people will currently miss it, since they land on the existing 2.7 documentation (http://docs.python.org/library/logging) instead

[issue11795] Better core dev guidelines for committing submitted patches

2011-04-07 Thread Nick Coghlan
New submission from Nick Coghlan : Based on a core-mentoring thread, a couple more points for: http://docs.python.org/devguide/committing.html#handling-other-s-code Attribution: - add to Misc/ACKS if they aren't already there (and didn't add themselves in their patch) - mention &quo

[issue11803] Memory leak in sub-interpreters

2011-04-08 Thread Nick Coghlan
Nick Coghlan added the comment: As a first guess, I would suspect that this is just badly fragmenting the heap and we aren't freeing up any arenas to pass back to the OS. -- ___ Python tracker <http://bugs.python.org/is

[issue9904] Cosmetic issues that may warrant a fix in symtable.h/c

2011-04-09 Thread Nick Coghlan
Nick Coghlan added the comment: +1 for clarifying the comments. Adding comments for the apparently unused fields (as per my last tracker comment) would be good, too. -- ___ Python tracker <http://bugs.python.org/issue9

[issue11816] Add functions to return disassembly as string

2011-04-10 Thread Nick Coghlan
Nick Coghlan added the comment: I really like the idea of adding some lower level infrastructure to dis to make it generator based, making the disassembly more amenable to programmatic manipulation. Consider if, for each line disassemble() currently prints, we had an underlying iterator

[issue11816] Refactor the dis module to provide better building blocks for bytecode analysis

2011-04-10 Thread Nick Coghlan
Nick Coghlan added the comment: Changed issue title to cover ideas like get_opinfo(). -- title: Add functions to return disassembly as string -> Refactor the dis module to provide better building blocks for bytecode analysis ___ Python trac

[issue11816] Refactor the dis module to provide better building blocks for bytecode analysis

2011-04-10 Thread Nick Coghlan
Nick Coghlan added the comment: Oops, I forgot to edit my comment to match the OpInfo definition I used in the proof-of-concept: OpInfo = collections.namedtuple("OpInfo", "opindex opcode opname oparg details starts_line

[issue11816] Refactor the dis module to provide better building blocks for bytecode analysis

2011-04-10 Thread Nick Coghlan
Nick Coghlan added the comment: If we decide our long term goal is the use of the opcode stream for programmatic access, then yes. -- ___ Python tracker <http://bugs.python.org/issue11

[issue9325] Add an option to pdb/trace/profile to run library module as a script

2011-04-15 Thread Nick Coghlan
Nick Coghlan added the comment: Good point about the extra parameter just pushing the problem one layer up the stack rather than completely solving the problem. However, on further reflection, I've realised that I really don't like having runpy import the threading module aut

[issue1294232] Error in metaclass search order

2011-04-19 Thread Nick Coghlan
Nick Coghlan added the comment: Yep, the leading underscore and the fact you added it to a block of code that is skipped when Py_LIMITED_API is defined makes it OK to include the prototype in object.h. However, I would suggest _PyType_CalculateMetaclass as the name - CalculateWinner is a

[issue1294232] Error in metaclass search order

2011-04-19 Thread Nick Coghlan
Nick Coghlan added the comment: Removed 2.7 from the affected versions - with neither __build_class__ nor __prepare__ in 2.x, there's no alternate metaclass calculation to go wrong. This should definitely be fixed for the final 3.1 release and for 3.2 though. An updated patch against cu

[issue1294232] Error in metaclass search order

2011-04-19 Thread Nick Coghlan
Nick Coghlan added the comment: Sorry, my last review wasn't right and the patch is incorrect as it stands. After digging a little deeper, there is still a case that isn't covered correctly in __build_class__. Specifically, the case where the most derived class has a declared meta

[issue1294232] Error in metaclass search order

2011-04-19 Thread Nick Coghlan
Nick Coghlan added the comment: This last point sounds like an error in PEP 3115 rather than an error in the implementation - as the exception says, the metaclass of a derived class must be the same as or a subclass of the metaclasses of all of its bases. Since that rule applies recursively

[issue1294232] Error in metaclass search order

2011-04-21 Thread Nick Coghlan
Nick Coghlan added the comment: I think PEP 3115 is OK - the error about all metaclasses inheriting from type was a mistake on my part (I thought the ability to create non-type metaclasses went away along with old-style classes, but I was simply wrong on that point). That got me curious as

[issue1294232] Error in metaclass search order

2011-04-21 Thread Nick Coghlan
Nick Coghlan added the comment: As near as I can tell, the only visible behavioural change with Daniel's patch (updated as per my last comment) will be that the two error cases noted above (i.e. when an explicit metaclass or the first parent type's metaclass is not the most derived

[issue1294232] Error in metaclass search order

2011-04-21 Thread Nick Coghlan
Nick Coghlan added the comment: Commenting on the latest patch here, since the Rietveld integration isn't coping with the "hg extdiff" output (I would guess that the revision numbers in the pathnames are confusing the script that attempts to determine the base revision). Asid

[issue9228] Make changes in the PATH and PATHEXT on installation

2011-04-21 Thread Nick Coghlan
Nick Coghlan added the comment: That's not correct - we've merely pointed out that it isn't as easy as most people seem to think. For the POSIX world, there is a version management scheme based on symlinks in /usr/bin (or /usr/local/bin) and it is easy to add and

[issue3561] Windows installer should add Python and Scripts directories to the PATH environment variable

2011-04-24 Thread Nick Coghlan
Nick Coghlan added the comment: Reopening this issue since #9228 was closed as a duplicate of this one. Given the significant level of user demand for this behaviour, it should NOT be closed again until a PEP has been written and either accepted or rejected. If such a PEP is not written and

[issue9228] Make changes in the PATH and PATHEXT on installation

2011-04-24 Thread Nick Coghlan
Nick Coghlan added the comment: If it is being requested every few months, then we should reconsider rejecting it. I have now reopened #3561 instead of this one. -- ___ Python tracker <http://bugs.python.org/issue9

[issue3561] Windows installer should add Python and Scripts directories to the PATH environment variable

2011-04-24 Thread Nick Coghlan
Nick Coghlan added the comment: Now, another factor to consider is that Windows 7 makes manipulating the system PATH even more difficult to do correctly (e.g. see http://www.symantec.com/connect/forums/wise-7-win-7-problems-updating-environment-variable-current-user). I believe ActiveState

[issue10914] Python sub-interpreter test

2011-04-24 Thread Nick Coghlan
Nick Coghlan added the comment: Sounds good. I still have that embedded pickle module issue to deal with, and this should let me actually add a test for it along with the fix. -- ___ Python tracker <http://bugs.python.org/issue10

[issue10912] PyObject_RichCompare differs in behaviour from PyObject_RichCompareBool ; difference not noted in documentation

2011-04-27 Thread Nick Coghlan
Nick Coghlan added the comment: Reopening, as a 2.7 backport of this would be a nice thing to have. -- assignee: rhettinger -> status: closed -> open versions: +Python 2.7 ___ Python tracker <http://bugs.python.org/i

[issue11682] PEP 380 reference implementation for 3.3

2011-04-27 Thread Nick Coghlan
Nick Coghlan added the comment: It's because it isn't a true Mercurial clone-and-update - it's a patch queue, which the review generation code doesn't know how to interpret. -- ___ Python tracker <http://bug

[issue11944] Function call with * and generator hide exception raised by generator.

2011-04-27 Thread Nick Coghlan
Nick Coghlan added the comment: It's not just hiding the real error, it's also saying something that isn't true. If you remove the deliberate error from the generator definition, it is clear that generators are perfectly acceptable as *arg inputs: >>> def g(): yie

[issue11945] Adopt and document consistent semantics for handling NaN values in containers

2011-04-27 Thread Nick Coghlan
New submission from Nick Coghlan : The question of the way Python handles NaN came up again on python-dev recently. The current semantics have been assessed as a reasonable compromise, but a poorly explained and inconsistently implemented one. Based on a suggestion from Terry Reedy [1] I

[issue11945] Adopt and document consistent semantics for handling NaN values in containers

2011-04-27 Thread Nick Coghlan
Nick Coghlan added the comment: Actually, based on the NumPy precedent [1], array.array should be fine as is. Since it uses raw C floats and doubles internally, rather than Python objects, there is no clear concept of "object identity" to use to enforce reflexivity.

[issue11945] Adopt and document consistent semantics for handling NaN values in containers

2011-04-28 Thread Nick Coghlan
Nick Coghlan added the comment: The status quo works. Proposals to change it on theoretical grounds have a significantly higher bar to meet than proposals to simply document it clearly. -- ___ Python tracker <http://bugs.python.org/issue11

[issue11945] Adopt and document consistent semantics for handling NaN values in containers

2011-04-28 Thread Nick Coghlan
Nick Coghlan added the comment: By "works" I merely meant that you can currently achieve both of the following: 1. Write fully conformant implementations of IEEE754 floating point types, including the non-reflexive NaN comparisons (keeping in mind that, as a value-based specificat

[issue11945] Adopt and document consistent semantics for handling NaN values in containers

2011-04-28 Thread Nick Coghlan
Nick Coghlan added the comment: After further discussion on python-dev, it is clear that this identity checking behaviour handles more than just NaNs - it also allows containers to cope more gracefully with objects like NumPy arrays that make use of rich comparisons to return something other

[issue11945] Adopt and document consistent semantics for handling NaN values in containers

2011-04-28 Thread Nick Coghlan
Nick Coghlan added the comment: Scratch the first half of that last comment - Guido pointed out that false positives rear their ugly head almost immediately if you try to store rich comparison objects in other containers. -- ___ Python tracker

[issue11887] unittest fails on comparing str with bytes if python has the -bb option

2011-05-02 Thread Nick Coghlan
Nick Coghlan added the comment: Rather than fiddling with the warnings filters, wouldn't it be easier to just catch BytesWarning and return False in that case? -- nosy: +ncoghlan ___ Python tracker <http://bugs.python.org/is

[issue11978] Report correct coverage.py data for tests that invoke subprocesses

2011-05-02 Thread Nick Coghlan
New submission from Nick Coghlan : http://nedbatchelder.com/code/coverage/subprocess.html describes how to instruct a test suite that spawns subprocesses to correctly report coverage data for code covered only in those subprocesses. regrtest currently doesn't do this, so modules tha

[issue11887] unittest fails on comparing str with bytes if python has the -bb option

2011-05-02 Thread Nick Coghlan
Nick Coghlan added the comment: I'm OK with that - I'd actually suggest explicitly *emitting* a warning when the error is suppressed under -bb, as Ezio is right that even tests should be keeping their bytes/str separation straight. I don't like completely suppressing warning

[issue11873] test_regexp() of test_compileall fails occassionally

2011-05-04 Thread Nick Coghlan
Nick Coghlan added the comment: A quick eyeball of the test doesn't reveal anything obvious: - if the subprocess is failing, it is doing so in such a way that it is still returning a 0 error code and isn't writing anything to stdout (as those assertions are before the check that th

[issue11873] test_regexp() of test_compileall fails occassionally

2011-05-04 Thread Nick Coghlan
Nick Coghlan added the comment: Hmm, I probably should have revised the first half of my comment after I had the thought about "simple regex" + "random directory name" being potentially problematic. I don't think that theory really

[issue10775] assertRaises as a context manager should accept a 'msg' keyword argument.

2011-05-05 Thread Nick Coghlan
Changes by Nick Coghlan : -- nosy: -ncoghlan ___ Python tracker <http://bugs.python.org/issue10775> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue11690] Devguide: Add "communication" FAQ

2011-05-05 Thread Nick Coghlan
Changes by Nick Coghlan : -- assignee: docs@python -> ncoghlan ___ Python tracker <http://bugs.python.org/issue11690> ___ ___ Python-bugs-list mailing list Un

[issue11647] function decorated with a context manager can only be invoked once

2011-05-05 Thread Nick Coghlan
Changes by Nick Coghlan : -- assignee: -> ncoghlan versions: +Python 3.2, Python 3.3 ___ Python tracker <http://bugs.python.org/issue11647> ___ ___ Python-

<    2   3   4   5   6   7   8   9   10   11   >