[issue18975] timeit: Use thousands separators and print number of loops per second

2013-09-08 Thread Jakub Stasiak
Changes by Jakub Stasiak : Added file: http://bugs.python.org/file31684/timeit-v3-pep8.patch ___ Python tracker ___ ___ Python-bugs-list maili

[issue18975] timeit: Use thousands separators and print number of loops per second

2013-09-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: > So: > > 1 loops, best of 3: 34.6 usec per loop (28 870 loops/s) Looks fine to me (though having a decimal space at the right and not at the left looks a bit weird). -- ___ Python tracker

[issue18975] timeit: Use thousands separators and print number of loops per second

2013-09-08 Thread R. David Murray
R. David Murray added the comment: I do not find a space to be an acceptable separator, sorry. -- ___ Python tracker ___ ___ Python-bu

[issue18821] Add .lastitem attribute to takewhile instances

2013-09-08 Thread Oscar Benjamin
Oscar Benjamin added the comment: Thank you Claudiu very much for writing a patch; I was expecting to have to do that myself! Serhiy, you're right groupby is a better fit for this. It does mean a bit of reworking for the (more complicated) sum function I'm working on but I've just checked with t

[issue18981] Typo in the ctypes tests

2013-09-08 Thread Anoop Thomas Mathew
New submission from Anoop Thomas Mathew: Comment in the test_number.py in ctypes test hold a typo bug. Instead of superseeded, it should be superseded. Patch attached. -- assignee: docs@python components: Documentation, Tests files: ctypes_test_typo.patch keywords: patch messages: 19731

[issue14984] netrc module allows read of non-secured .netrc file

2013-09-08 Thread bruno Piguet
bruno Piguet added the comment: I missed the 3.3 window, may I re-propose the same minimal patch against 3.4.0a1 ? I'm not sure I follow any python standard lib coding style but the general idea is quite simple and easy to get. I chose to ignore the backward compatibility concern, since I agre

[issue18982] Add tests for CLI of the calendar module

2013-09-08 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: The proposed patch adds tests for command-line interface of the calendar module. It also makes calendar tests discoverable and makes some existing tests more strong. -- components: Tests files: test_calendar_cli.patch keywords: patch messages: 1973

[issue18973] Use argparse in the calendar module

2013-09-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Good point. See issue18982. -- dependencies: +Add tests for CLI of the calendar module ___ Python tracker ___

[issue18983] Specify time unit for timeit CLI

2013-09-08 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: Just an idea. Currently the timeit module in command line automatically choice most appropriate time unit for human readable output. But this makes the output less machine readable. I propose to add new option which specifies fixed time unit (usec, msec, s

[issue12704] Language Reference: Clarify behaviour of yield when generator is not resumed

2013-09-08 Thread Nikolaus Rath
Nikolaus Rath added the comment: I've attached an updated patch. I agree with Tim that the docs on the yield expression are already very good, so instead of extending the yield statement documentation I have shortened it to instead reduce the overlap that already exists. In the yield expressi

[issue18815] DOCUMENTATION: "mmap .close()" doesn't close the underlying file

2013-09-08 Thread Anoop Thomas Mathew
Anoop Thomas Mathew added the comment: Made it explicit that close() will close only the mmap, and file will not be closed. Patch attached. -- keywords: +patch nosy: +Anoop.Thomas.Mathew Added file: http://bugs.python.org/file31689/mmap_close_documentation.patch ___

[issue18984] Remove .stopped Event from Thread internals

2013-09-08 Thread Tim Peters
New submission from Tim Peters: As discussed in issue 18808, now that we're checking for a tstate lock, the Thread._stopped Event has become an "attractive nuisance". The attached patch removes it. This simplifies .join() and .is_alive(), and restores pre-18808 .join(timeout) endcase behavio

[issue18984] Remove .stopped Event from Thread internals

2013-09-08 Thread Tim Peters
Changes by Tim Peters : -- dependencies: +Thread.join returns before PyThreadState is destroyed ___ Python tracker ___ ___ Python-bugs

[issue18984] Remove .stopped Event from Thread internals

2013-09-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Hmm.. I'm getting the following failures: == FAIL: test_4_joining_across_fork_in_worker_thread (test.test_threading.ThreadJoinOnShutdown) ---

[issue18984] Remove .stopped Event from Thread internals

2013-09-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: Looks like it's mostly the tests trying to check an implementation detail that doesn't exist anymore :-) -- ___ Python tracker ___

[issue18984] Remove .stopped Event from Thread internals

2013-09-08 Thread Tim Peters
Tim Peters added the comment: I agree with your diagnosis. Unfortunately, I can't test the fork stuff. Well, OK, I actually think that's fortunate (for me ;-) ). If you can see a quick way to fix these, please do. I'm going to vanish for about 2 hours now. -- _

[issue18967] Find a less conflict prone approach to Misc/NEWS

2013-09-08 Thread Nick Coghlan
Nick Coghlan added the comment: No, way down in Tests. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https

[issue18984] Remove .stopped Event from Thread internals

2013-09-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: I think the fix is simply to remove the outdated tests. I've been running test_threading in a loop with the (attached) updated patch, and there hasn't been a single failure. -- type: -> resource usage Added file: http://bugs.python.org/file31691/remov

[issue12317] inspect.getabsfile() is not documented

2013-09-08 Thread Brett Cannon
Changes by Brett Cannon : -- dependencies: +Move to absolute file paths for module.__file__ ___ Python tracker ___ ___ Python-bugs-lis

[issue18903] IDLE file-completion is case-sensitive in Windows

2013-09-08 Thread Terry J. Reedy
Terry J. Reedy added the comment: The initial difficulty I am having is that the edit menu, help file, code, and behavior do not seem to match up, so this whole feature set needs more review. For one thing, the AutoCompleteWindow (ACW) often comes up empty initially. Sometimes it fills in a co

[issue12317] inspect.getabsfile() is not documented

2013-09-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: This shouldn't be a dependency. The function is already implemented, it just needs to be documented. -- dependencies: -Move to absolute file paths for module.__file__ nosy: +pitrou ___ Python tracker

[issue18983] Specify time unit for timeit CLI

2013-09-08 Thread Antoine Pitrou
Antoine Pitrou added the comment: If you want the output to be machine readable, better go the full way and add a --json option, IMO. -- nosy: +pitrou, tim.peters ___ Python tracker ___

[issue12317] inspect.getabsfile() is not documented

2013-09-08 Thread Brett Cannon
Brett Cannon added the comment: It technically doesn't need to be a dependency, but if __file__ goes absolute then the point of the function becomes moot and thus shouldn't get documented as it is then pointless (and honestly I don't trust any code that tries to guess at what the cwd was when

[issue18929] inspect.classify_class_attrs ignores metaclass

2013-09-08 Thread Ethan Furman
Ethan Furman added the comment: Antoine, to answer all your questions at once, and using an Enum as the example: --> dir(Color) ['__class__', '__doc__', '__members__', '__module__', 'blue', 'green', 'red'] --> Color.__members__ mappingproxy(OrderedDict([('red', ), ('green', ), ('blue', )])) -

[issue18943] argparse: default args in mutually exclusive groups

2013-09-08 Thread paul j3
paul j3 added the comment: This `argument_values` comes from `_get_values()`. Most of the time is derived from the `argument_strings`. But in a few cases it is set to `action.default`, specifically when the action is an optional postional with an empty `argument_strings`. test_argparse.Test

[issue18984] Remove .stopped Event from Thread internals

2013-09-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset aff959a3ba13 by Tim Peters in branch 'default': Issue 18984: Remove ._stopped Event from Thread internals. http://hg.python.org/cpython/rev/aff959a3ba13 -- nosy: +python-dev ___ Python tracker

[issue18808] Thread.join returns before PyThreadState is destroyed

2013-09-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset aff959a3ba13 by Tim Peters in branch 'default': Issue 18984: Remove ._stopped Event from Thread internals. http://hg.python.org/cpython/rev/aff959a3ba13 -- ___ Python tracker

[issue18984] Remove .stopped Event from Thread internals

2013-09-08 Thread Tim Peters
Tim Peters added the comment: Thanks, Antoine! I pushed this change, figuring that even if some buildbots are still unhappy about 18808, getting rid of the Event can't make them more unhappy, and may make them happier. -- resolution: -> fixed ___

[issue1565525] tracebacks eat up memory by holding references to locals and globals when they are not wanted

2013-09-08 Thread A.M. Kuchling
A.M. Kuchling added the comment: Revised version of the patch: catches RuntimeError instead of skipping the first frame; adds versionadded tag; adds entry to NEWS and whatsnew files. -- Added file: http://bugs.python.org/file31692/clear-tb-frames-2.txt _

[issue18984] Remove .stopped Event from Thread internals

2013-09-08 Thread Tim Peters
Changes by Tim Peters : -- Removed message: http://bugs.python.org/msg197342 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue18984] Remove .stopped Event from Thread internals

2013-09-08 Thread Tim Peters
Tim Peters added the comment: New changeset aff959a3ba13 by Tim Peters in branch 'default': Issue 18984: Remove ._stopped Event from Thread internals. http://hg.python.org/cpython/rev/aff959a3ba13 -- ___ Python tracker

[issue18903] IDLE file-completion is case-sensitive in Windows

2013-09-08 Thread Westley Martínez
Westley Martínez added the comment: My example was totally abstract and untested. Sorry for any confusion. After doing some research, I find that this issue is complicated further: http://support.microsoft.com/kb/100625 I think we can assume that running into a situation where there are identi

[issue18800] Document Fraction's numerator and denominator properties

2013-09-08 Thread Madison May
Madison May added the comment: Simple and to the point. Sounds good to me... -- ___ Python tracker ___ ___ Python-bugs-list mailing l

[issue18983] Specify time unit for timeit CLI

2013-09-08 Thread Jakub Stasiak
Jakub Stasiak added the comment: My 2 cents - I'd split timeit.main function into processing part and argument parsing + data printing part so that you could use Python to call the first one to get the actual results (timings, numbers of loops etc.) and then present the data to the outside wor

[issue18752] Make chain.from_iterable an alias for a new chain_iterable.

2013-09-08 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pyt

[issue18929] inspect.classify_class_attrs ignores metaclass

2013-09-08 Thread Ethan Furman
Ethan Furman added the comment: This is a more useful help() -- patch attached. == Help on class Color in module __main__: class Color(enum.Enum) | Method resolution order: | Color | enum.Enum | buil

[issue1565525] tracebacks eat up memory by holding references to locals and globals when they are not wanted

2013-09-08 Thread STINNER Victor
STINNER Victor added the comment: I would prefer a clear_frames() method on the traceback object rather than a function. -- ___ Python tracker ___ _

[issue18980] Docs: enum - ReST format

2013-09-08 Thread Berker Peksag
Changes by Berker Peksag : -- nosy: +ethan.furman ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue18752] Make chain.from_iterable an alias for a new chain_iterable.

2013-09-08 Thread Raymond Hettinger
Raymond Hettinger added the comment: I'll work on improving the docs to make this classmethod more discoverable in docs, but the API is going to stay the same. -- resolution: -> rejected ___ Python tracker __

[issue14984] netrc module allows read of non-secured .netrc file

2013-09-08 Thread bruno Piguet
Changes by bruno Piguet : -- versions: +Python 3.2 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail

[issue14984] netrc module allows read of non-secured .netrc file

2013-09-08 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +giampaolo.rodola ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://

[issue18752] Make chain.from_iterable an alias for a new chain_iterable.

2013-09-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset fa1fa88b685b by Raymond Hettinger in branch 'default': Issue 18752: Make chain.from_iterable() more visible in the documentation. http://hg.python.org/cpython/rev/fa1fa88b685b -- nosy: +python-dev ___ Py

[issue18943] argparse: default args in mutually exclusive groups

2013-09-08 Thread paul j3
paul j3 added the comment: At the very least the `is not action.default` needs to be changed. Else where in argparse `is` is only used with `None` or constant like `SUPPRESS`. So using it with a user defined parameter is definitely not a good idea. Possible variations on how `is` behaves acr

[issue18980] Docs: enum - ReST format

2013-09-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset 0e05b07a6f84 by Ethan Furman in branch 'default': Close #18980: Enum doc fixes. Patch from Elazar Gershuni. http://hg.python.org/cpython/rev/0e05b07a6f84 -- nosy: +python-dev resolution: -> fixed stage: -> committed/rejected status: open

[issue18301] In itertools.chain.from_iterable() there is no cls argument

2013-09-08 Thread Roundup Robot
Roundup Robot added the comment: New changeset 29fa1f418796 by Raymond Hettinger in branch '3.3': Issue 18301: The classmethod decorator didn't fit well with the rough-equivalent example code. http://hg.python.org/cpython/rev/29fa1f418796 -- nosy: +python-dev _

[issue18301] In itertools.chain.from_iterable() there is no cls argument

2013-09-08 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- resolution: -> fixed status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing lis

<    1   2