[issue16004] Add `make touch` to 2.7 Makefile

2013-03-10 Thread Nick Coghlan
Nick Coghlan added the comment: Yep, that should be fine for 2.7. 3.3+ adds more due to the importlib bootstrapping. -- ___ Python tracker ___ __

[issue17393] stdlib import mistaken for local by import_fixer

2013-03-10 Thread Lennart Regebro
Lennart Regebro added the comment: Not really, but they are related. The fixer looks for a local module, and if it finds it it will assume the import is local. #13317 is caused by it not finding the module, since it's not built and hence assuming it's a global import. This bug, contrariwise,

[issue17395] Wait for live children in test_multiprocessing

2013-03-10 Thread Ezio Melotti
New submission from Ezio Melotti: While running test_multiprocessing I get: [...] test_wait_return (test.test_multiprocessing.WithManagerTestBarrier) ... ok Shared objects which still exist at manager shutdown: b6b802d4: refcount=1 b6b80ea4: refcount=1 b6b83264:

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

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

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

2013-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 406b47c64480 by Raymond Hettinger in branch 'default': Issue #15806: Add contextlib.ignored(). http://hg.python.org/cpython/rev/406b47c64480 -- nosy: +python-dev ___ Python tracker

[issue17351] Remove explicit "object" inheritance in Python 3 docs

2013-03-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: My rationale for supporting removal is this: People beginning with Py3, which is most beginners in the next decade, seeing (object), might think it necessary in certain cases or that it does something. The descriptor how-to is a) advanced and b) can have a not

[issue17390] display python version on idle title bar

2013-03-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: I agree. Sometimes when I have multiple IDLE windows open I have to scroll back to the top to make sure which one I am in. I suggest: Python x.y Shell for shell window I am not sure, for edit window: currently xxx.py -- /xxx.py I am not sure the redundancy is n

[issue15873] datetime: add ability to parse RFC 3339 dates and times

2013-03-10 Thread Alexander Belopolsky
Alexander Belopolsky added the comment: Éric> do you think there is a need to check python-ideas or python-dev before working on this? Yes, I think this is python-ideas material. IMHO, what should be added to datetime module in 3.4 is ability to construct date/time objects from their str() r

[issue17359] python modules.zip is not documented

2013-03-10 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo, ncoghlan versions: +Python 3.2 -Python 3.5 ___ Python tracker ___ ___ Python-bugs-list

[issue17351] Remove explicit "object" inheritance in Python 3 docs

2013-03-10 Thread Éric Araujo
Changes by Éric Araujo : -- Removed message: http://bugs.python.org/msg183924 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue17351] Remove explicit "object" inheritance in Python 3 docs

2013-03-10 Thread Éric Araujo
Changes by Éric Araujo : -- Removed message: http://bugs.python.org/msg183930 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue17351] Remove explicit "object" inheritance in Python 3 docs

2013-03-10 Thread Éric Araujo
Changes by Éric Araujo : -- Removed message: http://bugs.python.org/msg183923 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue17351] Remove explicit "object" inheritance in Python 3 docs

2013-03-10 Thread Éric Araujo
Éric Araujo added the comment: Disregard my comments, I reread only the start of the thread and missed the discussion about the descriptor tutorial. -- ___ Python tracker ___ __

[issue17390] display python version on idle title bar

2013-03-10 Thread Éric Araujo
Éric Araujo added the comment: Sounds like a good idea to me. Would you like to propose a patch? The devguide contains information to do that. Hint: sys.version is not meant to be parsed, there is sys.version_info for that (no regex needed! :) -- keywords: +easy nosy: +eric.araujo,

[issue17392] Python installer for Windows packages wrong zipfile.py

2013-03-10 Thread Éric Araujo
Éric Araujo added the comment: Could you explain what makes you say this? Installers are built from the source code repository, not assembled by human copy-pasting, so such an error seems highly unlikely to me. Please tell what Python versions you checked (i.e. versions from python.org or Ac

[issue763043] unable to specify another compiler

2013-03-10 Thread Éric Araujo
Éric Araujo added the comment: Starting with Python 2.3, environment variables like CC (familiar to people compiling C projects on unix) are respected. That’s what I think should be added to the distutils docs, maybe in the reference doc for build_ext, or in the narrative doc talking about ex

[issue13317] building with 2to3 generates wrong import paths because build_ext is run after build_py

2013-03-10 Thread Éric Araujo
Éric Araujo added the comment: For the record this is caused by #17393 -- ___ Python tracker ___ ___ Python-bugs-list mailing list Uns

[issue17393] stdlib import mistaken for local by import_fixer

2013-03-10 Thread Éric Araujo
Éric Araujo added the comment: This is the cause for #13317 -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bugs-list mailing

[issue17351] Remove explicit "object" inheritance in Python 3 docs

2013-03-10 Thread Éric Araujo
Éric Araujo added the comment: The changeset redirector seems broken, here’s the full link: http://hg.python.org/cpython/rev/5eca56b68840 FTR I am still in favor of removal regardless of the possible issues I noted in my previous comment. -- ___ Py

[issue17351] Remove explicit "object" inheritance in Python 3 docs

2013-03-10 Thread Éric Araujo
Éric Araujo added the comment: Note that removing the unnecessary '(object)' may make it worse for e.g. beginners going from 3.x to 2.x, and slightly complicate porting patches. Raymond approves the removal, yet added '(object)' in a 3.3 doc file in 5eca56b68840 -- nosy: +eric.araujo

[issue17365] Remove Python 2 code from test_print

2013-03-10 Thread Éric Araujo
Éric Araujo added the comment: The cosmetic changes to whitespace and parens seem like diff noise to me. -- nosy: +eric.araujo ___ Python tracker ___

[issue15873] datetime: add ability to parse RFC 3339 dates and times

2013-03-10 Thread Éric Araujo
Éric Araujo added the comment: John listed four modules with issues in the first message, and now we have proposals for two more modules. Could you work together to make a unified patch? Alexander, do you think there is a need to check python-ideas or python-dev before working on this? (I c

[issue11963] Remove human verification from test suite (test_parser and test_subprocess)

2013-03-10 Thread Ezio Melotti
Ezio Melotti added the comment: This should be fixed now. -- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker ___ ___

[issue11963] Remove human verification from test suite (test_parser and test_subprocess)

2013-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 222505a5aeac by Ezio Melotti in branch '3.2': #11963: remove human verification from test_parser and test_subprocess. http://hg.python.org/cpython/rev/222505a5aeac New changeset cc08036b37a4 by Ezio Melotti in branch '3.3': #11963: merge with 3.2. h

[issue17394] Add slicing support to collections.deque

2013-03-10 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.

[issue17394] Add slicing support to collections.deque

2013-03-10 Thread Raymond Hettinger
New submission from Raymond Hettinger: Once added, use it in threading.Condition(). -- assignee: rhettinger components: Library (Lib) messages: 183918 nosy: rhettinger priority: low severity: normal status: open title: Add slicing support to collections.deque versions: Python 3.4 __

[issue16389] re._compiled_typed's lru_cache causes significant degradation of the mako_v2 bench

2013-03-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: Serhiy, please go ahead an apply your patch. Be sure to restore the re cache tests that existed in Py3.2 as well. Thank you. -- assignee: rhettinger -> serhiy.storchaka priority: normal -> high stage: needs patch -> test needed ___

[issue16659] Pure Python implementation of random

2013-03-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: [Serhiy Storchaka] > I don't want to make a decision on the inclusion of this code. It was a tough call, but I don't want to add this code. You've a great job with it, but I don't think it is a worthwhile endeavor. * The algorithm was designed with C lev

[issue16278] os.rename documentation slightly inaccurate

2013-03-10 Thread Todd Rovito
Todd Rovito added the comment: Made some very minor changes to get patch to work on Windows. Had issues with line ending differences between Unix and Windows. I fixed it so line endings won't be an issue and tested patch on Windows, Linux, and OS X. Please feel free to supply feedback or co

[issue16651] Find out what stdlib modules lack a pure Python implementation

2013-03-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: I don't think itertools or collections.deque should go on this list. The other implementations already have these and a pure python versions miss the point of these being high performance tools. AFAICT, there is zero benefit to adding a bunch of extra cod

[issue16389] re._compiled_typed's lru_cache causes significant degradation of the mako_v2 bench

2013-03-10 Thread Nick Coghlan
Nick Coghlan added the comment: Raymond's plan sounds good to me. We may also want to tweak the 3.3 lru_cache docs to note the trade-offs involved in using it. Perhaps something like: "As a general purpose cache, lru_cache needs to be quite pessimistic in deriving non-conflicting keys from th

[issue16278] os.rename documentation slightly inaccurate

2013-03-10 Thread Todd Rovito
Todd Rovito added the comment: Thanks for the feedback Vitaliy Stepanov that helped alot with the version 3 patch. -- ___ Python tracker ___

[issue16278] os.rename documentation slightly inaccurate

2013-03-10 Thread Todd Rovito
Todd Rovito added the comment: V3 added which includes much shorter variable names and a cleanup of the patch. I still need to test on Windows. -- Added file: http://bugs.python.org/file29370/16278OSRenameDocsTestV3.patch ___ Python tracker

[issue17120] Mishandled _POSIX_C_SOURCE and _XOPEN_SOURCE in pyconfig.h

2013-03-10 Thread RAW
RAW added the comment: Any response? -- status: open -> languishing ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscri

[issue17391] _cursesmodule Fails to Build on GCC 2.95 (static)

2013-03-10 Thread Jeffrey Armstrong
Changes by Jeffrey Armstrong : -- components: +Extension Modules -Build ___ Python tracker ___ ___ Python-bugs-list mailing list Unsub

[issue17385] Use deque instead of list the threading.Condition waiter queue

2013-03-10 Thread Guido van Rossum
Guido van Rossum added the comment: Looks fine. I'd say that it would be great to add slicing to deque! There's one oddity in the code, but it was there before the patch -- the local variable name __waiters is pretty silly. It appears to be a micro-optimization to avoid using self._waiters mor

[issue16895] Batch file to mimic 'make' on Windows

2013-03-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: Thanks, clean and kill make sense for unattended build-bots. For interactive use, when 2 minutes rebuilding is a big deal, clean is a last resort. Let's just make sure we do not somehow suggest that it needs to be done routinely. Or to put it another way, do d

[issue11963] Remove human verification from test suite (test_parser and test_subprocess)

2013-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 3e14aafeca04 by Ezio Melotti in branch '2.7': #11963: fix Windows buildbots. http://hg.python.org/cpython/rev/3e14aafeca04 -- ___ Python tracker __

[issue17385] Use deque instead of list the threading.Condition waiter queue

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

[issue17385] Use deque instead of list the threading.Condition waiter queue

2013-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 0f86b51f8f8b by Raymond Hettinger in branch 'default': Issue #17385: Fix quadratic behavior in threading.Condition http://hg.python.org/cpython/rev/0f86b51f8f8b -- nosy: +python-dev ___ Python tracker

[issue16895] Batch file to mimic 'make' on Windows

2013-03-10 Thread Richard Oudkerk
Richard Oudkerk added the comment: > What does running 'kill-python before re-building python do? I have not > seen it mentioned in the in the devguide or pcbuild/readme. It kills any currently running python(_d).exe processes. This is because Windows does not allow program or library files t

[issue16895] Batch file to mimic 'make' on Windows

2013-03-10 Thread Zachary Ware
Zachary Ware added the comment: >Terry J. Reedy added the comment: > >One must run external.bat if one is to subsequently build from the vs >gui with *most* of the external dependencies. I think the command to >run it should be 'external', not 'ready'. 'External' means get the >external dependenc

[issue11963] Remove human verification from test suite (test_parser and test_subprocess)

2013-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset d25749c32bb4 by Ezio Melotti in branch '2.7': #11963: remove human verification from test_subprocess. http://hg.python.org/cpython/rev/d25749c32bb4 -- ___ Python tracker

[issue17374] Remove restriction against Semaphore having a negative value

2013-03-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: [Antoine] > multiprocessing.Semaphore should be kept compatible > with threading.Semaphore. I just looked at the C code implementing multiprocessing Semaphore. Removing the negative count restriction there looks straight-forward. I'll include it in the p

[issue17385] Use deque instead of list the threading.Condition waiter queue

2013-03-10 Thread Andrew Svetlov
Changes by Andrew Svetlov : -- nosy: +asvetlov ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue17373] Add inspect.Signature.from_callable()

2013-03-10 Thread Andrew Svetlov
Andrew Svetlov added the comment: Agree in general, but you need to update the docs also. -- nosy: +asvetlov ___ Python tracker ___ __

[issue17385] Use deque instead of list the threading.Condition waiter queue

2013-03-10 Thread Raymond Hettinger
Raymond Hettinger added the comment: Thanks Antoine. Since the calls are made without a lock, I'll go for a minimal patch and keep the existing fairness logic. Adding Guido to the nosy list since this is his code. FWIW, the heaviest load for condition variables likely arises with use of the

[issue17365] Remove Python 2 code from test_print

2013-03-10 Thread Andrew Svetlov
Andrew Svetlov added the comment: Agree with Terry. The patch LGTM except unicode literals part. -- nosy: +asvetlov ___ Python tracker ___ ___

[issue17351] Remove explicit "object" inheritance in Python 3 docs

2013-03-10 Thread Andrew Svetlov
Changes by Andrew Svetlov : -- nosy: +asvetlov ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue17330] Stop checking for directory cache invalidation in importlib

2013-03-10 Thread Andrew Svetlov
Changes by Andrew Svetlov : -- nosy: +asvetlov ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue17338] Add length_hint parameter to list, dict, set constructors to allow efficient presizing

2013-03-10 Thread Andrew Svetlov
Changes by Andrew Svetlov : -- nosy: +asvetlov ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue1076515] shutil.move clobbers read-only files.

2013-03-10 Thread R. David Murray
R. David Murray added the comment: Since I spent some time thinking about this, I want to leave some notes: The linux 'mv' command issues the following prompt: > mv t2/myfile t1 mv: try to overwrite ‘t1/myfile’, overriding mode (-)? So modern linux, at least, will not overwrit

[issue1076515] shutil.move clobbers read-only files.

2013-03-10 Thread Brett Cannon
Brett Cannon added the comment: Closing since everyone seems to agree that the current behaviour is fine and Tarek has not said anything since being assigned the bug. -- nosy: +brett.cannon resolution: -> rejected status: open -> closed ___ Python t

[issue17066] Fix test discovery for test_robotparser.py

2013-03-10 Thread Ezio Melotti
Ezio Melotti added the comment: Do you think doing something like: class BaseRobotTest: def setUp(self): lines = io.StringIO(robots_txt).readlines() self.parser = urllib.robotparser.RobotFileParser() parser.parse(lines) def test_good(self): for url in go

[issue17393] stdlib import mistaken for local by import_fixer

2013-03-10 Thread Lennart Regebro
Changes by Lennart Regebro : -- type: -> behavior ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.

[issue17393] stdlib import mistaken for local by import_fixer

2013-03-10 Thread Lennart Regebro
New submission from Lennart Regebro: If you have a local folder (without an __init__.py, hence just a normal folder) with the same name as a non local module, the import statements of that module will assumed to be local and transformed from for example ``import datetime`` to ``from . import d

[issue8318] Deprecation of multifile inappropriate or incomplete

2013-03-10 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- stage: needs patch -> committed/rejected ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubs

[issue8318] Deprecation of multifile inappropriate or incomplete

2013-03-10 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- resolution: -> out of date status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing l

[issue763043] unable to specify another compiler

2013-03-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: Is this still relevant, or should it be closed? I no 0 idea what either of you think should be changed in the docs and where, and I suspect the same would be true of any other non-disutils expert, so if a patch is needed, it should come from one you two (Matth

[issue17392] Python installer for Windows packages wrong zipfile.py

2013-03-10 Thread Simon Wagner
New submission from Simon Wagner: Wrong version of zipfile.py is packaged with the Windows installer for Python 3.2 and 3.3. It seems to be the version from 3.1. Other files might also be wrong, I did not check. -- components: Installation, Windows messages: 183892 nosy: Simon.Wagner p

[issue17016] _sre: avoid relying on pointer overflow

2013-03-10 Thread Nickolai Zeldovich
Nickolai Zeldovich added the comment: Sorry for the delay. Attached is an updated patch that should fix all of the issues mentioned in this bug report. -- Added file: http://bugs.python.org/file29368/pp-2.patch ___ Python tracker

[issue16895] Batch file to mimic 'make' on Windows

2013-03-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: One must run external.bat if one is to subsequently build from the vs gui with *most* of the external dependencies. I think the command to run it should be 'external', not 'ready'. 'External' means get the external dependencies and anyone who has run external.

[issue17317] Benchmark driver should calculate actual benchmark count in -h

2013-03-10 Thread Brett Cannon
Brett Cannon added the comment: The asterisk is added manually by a person, so by virtue of it being a weekend no one has gotten to it yet. As soon as it has been processed and I have time I will commit the patch. -- ___ Python tracker

[issue17317] Benchmark driver should calculate actual benchmark count in -h

2013-03-10 Thread Anuj Gupta
Anuj Gupta added the comment: I did it yesterday while studying the devguide and "how to get started" articles. Just did it again, and received an email with the subject "The Python Contributor Agreement Form (between Anuj Gupta and Python Software Foundation) is Signed and Filed!". Still no

[issue17317] Benchmark driver should calculate actual benchmark count in -h

2013-03-10 Thread Brett Cannon
Brett Cannon added the comment: How and when did you sign the CLA? It has not been registered yet that you have, else your username would have an asterisk next to it. As for Misc/ACKS, that's in Python itself and not the benchmark suite so this wouldn't get you in that file. To contribute mor

[issue16895] Batch file to mimic 'make' on Windows

2013-03-10 Thread Zachary Ware
Zachary Ware added the comment: > Richard Oudkerk added the comment: > > +1 Thank you :) > To use Tools/builbot/*.bat doesn't the current directory have to be the main > directory of the repository? Then I see no point in the "-C" argument: just > set the correct directory automatically. Tha

[issue17351] Remove explicit "object" inheritance in Python 3 docs

2013-03-10 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- title: Fixed python3 descriptor documentation example + removal of explicit "object" inheritance in docs -> Remove explicit "object" inheritance in Python 3 docs ___ Python tracker

[issue17351] Fixed python3 descriptor documentation example + removal of explicit "object" inheritance in docs

2013-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset bb7e01b5d362 by Raymond Hettinger in branch '3.3': Issue #17351: Modernize the pure Python property() example. http://hg.python.org/cpython/rev/bb7e01b5d362 -- ___ Python tracker

[issue17351] Fixed python3 descriptor documentation example + removal of explicit "object" inheritance in docs

2013-03-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 513c4aaf70d7 by Raymond Hettinger in branch '2.7': Issue #17351: Modernize the pure Python property() example. http://hg.python.org/cpython/rev/513c4aaf70d7 -- nosy: +python-dev ___ Python tracker

[issue17317] Benchmark driver should calculate actual benchmark count in -h

2013-03-10 Thread Anuj Gupta
Anuj Gupta added the comment: Improved wording of the comment -- Added file: http://bugs.python.org/file29367/benchmark_count.patch ___ Python tracker ___ ___

[issue17323] Disable [X refs, Y blocks] ouput in debug builds

2013-03-10 Thread Gregory P. Smith
Gregory P. Smith added the comment: If this is done, it should probably be on by default on all --with-pydebug buildbots. Otherwise I suspect nobody will _ever_ look at its output and we should just remove the feature all together. Being off in the main process on the build bots would still m

[issue3329] API for setting the memory allocator used by Python

2013-03-10 Thread Gregory P. Smith
Changes by Gregory P. Smith : -- nosy: +gregory.p.smith ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://m

[issue17317] Benchmark driver should calculate actual benchmark count in -h

2013-03-10 Thread Anuj Gupta
Anuj Gupta added the comment: I've already signed that. I was contemplating adding my name to the Misc/ACK file but I'd like to know if it's appropriate. Certainly gives one a confidence boost, but I'm not aware whether this fix qualifies me for it. I'd like to contribute a lot more code to Py

[issue17389] Optimize Event.wait()

2013-03-10 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.

[issue17251] LWPCookieJar load() set domain_specifed wrong

2013-03-10 Thread B. Kyven
B. Kyven added the comment: @Demian Brecht Um, I do realize the lack of popularity of this module, now. What I try to achieve is simple. store persistent cookies in a way, that's told to be standard in python ? Actually, I was trying to sync QtCookiesJar to CookieJar to make urllib2 works wit

[issue17317] Benchmark driver should calculate actual benchmark count in -h

2013-03-10 Thread Brett Cannon
Brett Cannon added the comment: Thanks for the patch, Anuj! The solution looks fine. While reviewing I discovered the test suite didn't work anymore and so I fixed that plus added a test to the name expansion to make sure it would always work properly. All of that is included in the patch I up

[issue16895] Batch file to mimic 'make' on Windows

2013-03-10 Thread Richard Oudkerk
Richard Oudkerk added the comment: +1 To use Tools/builbot/*.bat doesn't the current directory have to be the main directory of the repository? Then I see no point in the "-C" argument: just set the correct directory automatically. I think make.bat should also support creation of non-debug b

[issue17391] _cursesmodule Fails to Build on GCC 2.95 (static)

2013-03-10 Thread Jeffrey Armstrong
New submission from Jeffrey Armstrong: When compiling Modules/_cursesmodule.c as a static module with GCC 2.95.3, an error is encountered on line 2260 in PyCurses_GetWin. The error occurs because the PyCursesInitialised macro appears prior _Py_IDENTIFIER(read), which is actually a variable de

[issue17385] Use deque instead of list the threading.Condition waiter queue

2013-03-10 Thread Antoine Pitrou
Antoine Pitrou added the comment: That said, I seem to remember a discussion of Condition's fairness. Right now, waiters are notified in the order of wait() calls. This wouldn't be the case anymore if using a set instead of a list or deque. Also, I can't remember a situation where I made an int

[issue17385] Use deque instead of list the threading.Condition waiter queue

2013-03-10 Thread Antoine Pitrou
Antoine Pitrou added the comment: Actually, wait() calls self._waiters.remove() without holding the lock. But I think it could easily do so after taking the lock (since it takes it anyway before returning). Also, _waiters should better be a set, since wait() needs the associative behaviour wh

[issue17390] display python version on idle title bar

2013-03-10 Thread bagrat lazaryan
New submission from bagrat lazaryan: useful for those who routinely use different versions of python on idle. as it ships, idle displays "python shell" on its title bar. it would be useful to have there the version displayed as well. see http://bagratte.blogspot.it/2013/03/display-python-vers

[issue17389] Optimize Event.wait()

2013-03-10 Thread Antoine Pitrou
Antoine Pitrou added the comment: > How about the attached simpler patch? Looks better indeed! I had completely overlooked the possible race condition. -- ___ Python tracker ___

[issue17389] Optimize Event.wait()

2013-03-10 Thread Mark Dickinson
Mark Dickinson added the comment: How about the attached simpler patch? -- Added file: http://bugs.python.org/file29364/event_wait_metd.patch ___ Python tracker ___ _

[issue17389] Optimize Event.wait()

2013-03-10 Thread Mark Dickinson
Mark Dickinson added the comment: I think there's a race condition in the patched version: 'self._flag' could be set in between if 'if not signaled:' and the 'self._cond.acquire()', and in that case you'll end up waiting for an event that's already occurred. Do you need to recheck 'self._fla

[issue17389] Optimize Event.wait()

2013-03-10 Thread Mark Dickinson
Changes by Mark Dickinson : -- nosy: +mark.dickinson ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai