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

2013-09-04 Thread Berker Peksag
Changes by Berker Peksag : -- nosy: +pje versions: -Python 2.6, Python 3.1, Python 3.2 ___ Python tracker ___ ___ Python-bugs-list ma

[issue18882] Add threading.main_thread() function

2013-09-04 Thread Andrew Svetlov
Andrew Svetlov added the comment: I did not received review email, sorry. Docstring is added. BTW 'threading' module has almost no docstrings, that's why I've added only docs at first. Do you think docstrings should be added to all public functions? Thanks. -- _

[issue18882] Add threading.main_thread() function

2013-09-04 Thread Antoine Pitrou
Antoine Pitrou added the comment: > BTW 'threading' module has almost no docstrings, that's why I've > added only docs at first. > Do you think docstrings should be added to all public functions? Well, probably, although that's another issue :) -- __

[issue16201] socket.gethostbyname incorrectly parses ip

2013-09-04 Thread Antoine Pitrou
Antoine Pitrou added the comment: Perhaps you could add tests for the broadcast special cases? -- ___ Python tracker ___ ___ Python-bu

[issue16201] socket.gethostbyname incorrectly parses ip

2013-09-04 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- versions: -Python 3.1, Python 3.2, Python 3.5 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue18849] Failure to try another name for tempfile when directory with chosen name exists on windows

2013-09-04 Thread Vlad Shcherbina
Changes by Vlad Shcherbina : Added file: http://bugs.python.org/file31579/temp_dir_exists_retry_test_33_34.patch ___ Python tracker ___ ___ P

[issue18849] Failure to try another name for tempfile when directory with chosen name exists on windows

2013-09-04 Thread Vlad Shcherbina
Changes by Vlad Shcherbina : Added file: http://bugs.python.org/file31580/temp_dir_exists_retry_test_27.patch ___ Python tracker ___ ___ Pytho

[issue16037] httplib: header parsing is not delimited

2013-09-04 Thread Jyrki Pulliainen
Jyrki Pulliainen added the comment: Reworded TooMuch to TooMany and made a patch for 2.6 too (2.7 didn't apply cleanly there) -- Added file: http://bugs.python.org/file31581/issue16037_py26.patch ___ Python tracker

[issue16037] httplib: header parsing is not delimited

2013-09-04 Thread Jyrki Pulliainen
Changes by Jyrki Pulliainen : Added file: http://bugs.python.org/file31582/issue16037_py27_v2.patch ___ Python tracker ___ ___ Python-bugs-lis

[issue16037] httplib: header parsing is not delimited

2013-09-04 Thread Jyrki Pulliainen
Changes by Jyrki Pulliainen : Added file: http://bugs.python.org/file31583/issue16037_py32_v2.patch ___ Python tracker ___ ___ Python-bugs-lis

[issue18849] Failure to try another name for tempfile when directory with chosen name exists on windows

2013-09-04 Thread Vlad Shcherbina
Vlad Shcherbina added the comment: 1. I agree that consistency between 2.7 and 3.* have some value, but maybe it's better to take less permissive approach in 3.* instead and only retry when exception is PermissionError _and_ errno is EACCES? 2. Currently it's being reraised unless platform.nam

[issue18919] Unify audio modules tests

2013-09-04 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: Three audio modules, aifc, sunau and wave, have similar interfaces and poor tests. The proposed patch introduces new file Lib/test/audiotests.py with common audio tests. New testing exposes some bugs and discrepancy between different audio modules. For ex

[issue18919] Unify audio modules tests

2013-09-04 Thread Claudiu.Popa
Claudiu.Popa added the comment: I love this idea! I was thinking while working on sunau/aifc/wave patches that we can do more than this, unify the entire audio modules, getting rid of Aifc_write/read and Wave_write/read was in fact my first desire. One way that I thought about was to provide an

[issue18901] sunau.getparams should return a namedtuple

2013-09-04 Thread Roundup Robot
Roundup Robot added the comment: New changeset 61ca4732399b by Serhiy Storchaka in branch 'default': Issues #18901, #18919: Fix a typo in the _sunau_params name. http://hg.python.org/cpython/rev/61ca4732399b -- ___ Python tracker

[issue18919] Unify audio modules tests

2013-09-04 Thread Roundup Robot
Roundup Robot added the comment: New changeset 61ca4732399b by Serhiy Storchaka in branch 'default': Issues #18901, #18919: Fix a typo in the _sunau_params name. http://hg.python.org/cpython/rev/61ca4732399b -- nosy: +python-dev ___ Python tracker

[issue18919] Unify audio modules tests

2013-09-04 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- dependencies: +Add support of the 'with' statement to sunau.open. ___ Python tracker ___ ___ Python-b

[issue18917] python won't display greek characters in apache under windows

2013-09-04 Thread Nick
Nick added the comment: Turns out adding "SetEnv PYTHONIOENCODING utf-8" to the end of apache's httpd.conf file fixed the problem for me. -- ___ Python tracker ___ _

[issue18615] sndhdr.whathdr could return a namedtuple

2013-09-04 Thread Claudiu.Popa
Changes by Claudiu.Popa : -- nosy: +serhiy.storchaka ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://ma

[issue18920] argparse module version action

2013-09-04 Thread Wolfgang Maier
New submission from Wolfgang Maier: Hi, I just noticed that version output generated via the **'version' action** of the **argparse** module is routed to stderr. I'd expect regular output to go to stdout instead. The current behavior also seems inconsistent to me because --help prints to stdout.

[issue18849] Failure to try another name for tempfile when directory with chosen name exists on windows

2013-09-04 Thread Eli Bendersky
Eli Bendersky added the comment: Re (1) let's leave it as it is, now. I don't think it really matters. I left some comments in Rietveld. -- ___ Python tracker ___ __

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

2013-09-04 Thread Eli Bendersky
Eli Bendersky added the comment: Why guess... did you try it in the code? Trying has another goal - it would be nice to have a short code sample here demonstrating what's happening. The paragraph you're quoting seems obscure to me, with or without the fix. -- nosy: +eli.bendersky ___

[issue18615] sndhdr.whathdr could return a namedtuple

2013-09-04 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- nosy: +r.david.murray stage: -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue18920] argparse module version action

2013-09-04 Thread Eli Bendersky
Eli Bendersky added the comment: Yes, it seems like an oversight to me. Printing --version to stdout is more customary (Python itself does it, and most other tools do too). A question comes up about backwards compatibility. I would definitely not change it in 2.x - it's just not worth it. As f

[issue18898] Apply the setobject optimizations to dictionaries

2013-09-04 Thread Eli Bendersky
Eli Bendersky added the comment: I'm still interested in seeing benchmarks that show where this actually improves things and by how much. Also, whether any regressions occur and how serious they are. -- nosy: +eli.bendersky ___ Python tracker

[issue18920] argparse module version action

2013-09-04 Thread Ezio Melotti
Ezio Melotti added the comment: Only on 3.4. Python prints the version on stdout since 3.4 -- before it used stderr: 3.3$ ./python -V 2> /dev/null 3.3$ ./python -V > /dev/null Python 3.3.2+ 3.4$ ./python -V 2> /dev/null Python 3.4.0a1+ 3.4$ ./python -V > /dev/null This might also explain why ar

[issue18920] argparse module version action

2013-09-04 Thread Eli Bendersky
Eli Bendersky added the comment: On Wed, Sep 4, 2013 at 6:26 AM, Ezio Melotti wrote: > > Ezio Melotti added the comment: > > Only on 3.4. > Python prints the version on stdout since 3.4 -- before it used stderr: > 3.3$ ./python -V 2> /dev/null > 3.3$ ./python -V > /dev/null > Python 3.3.2+ > >

[issue18920] argparse module version action

2013-09-04 Thread Eli Bendersky
Eli Bendersky added the comment: The Python executable change is from #18338 -- ___ Python tracker ___ ___ Python-bugs-list mailing li

[issue18898] Apply the setobject optimizations to dictionaries

2013-09-04 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +serhiy.storchaka ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://

[issue18693] help() not helpful with enum

2013-09-04 Thread Ethan Furman
Ethan Furman added the comment: Found it! It was a combination of __objclass__ not being defined on the enum mmebers, and the metatype not being searched in the __mro__ by inspect. Thanks, Ronald, for the necessary clues. Patch attached. I'm not sure if I have the method wowser showing up i

[issue16938] pydoc confused by __dir__

2013-09-04 Thread Ethan Furman
Ethan Furman added the comment: Issue18693 has a patch to `inspect` so that classify_class_attrs will also look in the metaclass. If that is accepted I think PyDoc is okay as is. -- ___ Python tracker ___

[issue8311] wave module sets data subchunk size incorrectly when writing wav file

2013-09-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It's because you write an array of integers while writeframes() expects a bytes object. Here is a test. -- keywords: +patch stage: test needed -> needs patch versions: +Python 2.7, Python 3.3, Python 3.4 -Python 2.6 Added file: http://bugs.python.org

[issue18920] argparse module version action

2013-09-04 Thread Eli Bendersky
Eli Bendersky added the comment: Patch attached -- keywords: +patch stage: needs patch -> patch review Added file: http://bugs.python.org/file31587/issue18920.1.patch ___ Python tracker

[issue18693] help() not helpful with enum

2013-09-04 Thread Eli Bendersky
Eli Bendersky added the comment: Great, Ethan. I'd say the inspect fix has to be reviewed and committed separately. Maybe #16938 is the right place to post the patch for it. Once that's in, we can review/commit the enum parts. -- ___ Python tracker

[issue18920] argparse module version action

2013-09-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: You misplace Misc/NEWS entry in wrong section -- "What's New in Python 3.4.0 Alpha 1". I think this change (as change of issue18338) worths the mentioning in Doc/whatsnew/3.4.rst. Did you run all test suite? This change can affect other tests. --

[issue18920] argparse module version action

2013-09-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > This might also explain why argparse uses stderr (other modules/scripts in > the stdlib might do the same too). Lib/trace.py, Tools/pynche/Main.py, and Tools/i18n/pygettext.py write to the stdout. Lib/smtpd.py and Tools/i18n/msgfmt.py write to the stderr.

[issue18921] In imaplib, cached capabilities may be out of date after login

2013-09-04 Thread Steven Murdoch
New submission from Steven Murdoch: When an IMAP server is behind a proxy, the proxy's capabilities may differ from that of the actual IMAP server. However, in Python imaplib, the client will ignore any updates to available capabilities in the response to the LOGIN command (see rfc3501, sectio

[issue18909] Segfaults on win-amd64 due to corrupt pointer to Tkapp_Interp

2013-09-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Indeed, for less surprise we should use PyInt_FromSsize_t() on Python 2.7. -- ___ Python tracker ___ _

[issue18693] help() not helpful with enum

2013-09-04 Thread Ethan Furman
Ethan Furman added the comment: help() won't really be fixed with the inspect patch. If no objections within a few hours I'll open a new issue for it. -- ___ Python tracker ___

[issue18808] Thread.join returns before PyThreadState is destroyed

2013-09-04 Thread Antoine Pitrou
Antoine Pitrou added the comment: > What I still don't understand: the new lock is an internal > implementation detail. How would it gain a weakref with a callback? > Users aren't going to mess with this lock, and if you want to stop > Python maintainers from giving it a weakref with a callbac

[issue11245] Implementation of IMAP IDLE in imaplib?

2013-09-04 Thread R. David Murray
Changes by R. David Murray : -- dependencies: +In imaplib, cached capabilities may be out of date after login ___ Python tracker ___ _

[issue18921] In imaplib, cached capabilities may be out of date after login

2013-09-04 Thread R. David Murray
R. David Murray added the comment: I agree that this would be a good idea, but it is not a bug in the current implementation. The only place imaplib itself uses the cached capabilities is *before* login, in the starttls method, and there it refreshes it after starttls succeeds. Although it i

[issue18922] Output versions of scripts to stdout

2013-09-04 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: The Lib/smtpd.py and Tools/i18n/msgfmt.py scripts write their version strings to stderr. It should be changed to stdout for consistency with most common practice. See also issue18338 and issue18920. -- components: Demos and Tools, Library (Lib) key

[issue18876] Problems with files opened in append mode with io module

2013-09-04 Thread Erik Bray
Changes by Erik Bray : Added file: http://bugs.python.org/file31588/issue_18876_patch_2.diff ___ Python tracker ___ ___ Python-bugs-list maili

[issue16853] add a Selector to the select module

2013-09-04 Thread Roundup Robot
Roundup Robot added the comment: New changeset e4d45315c38c by Charles-François Natali in branch 'default': Issue #16853: Add new selectors module. http://hg.python.org/cpython/rev/e4d45315c38c -- nosy: +python-dev ___ Python tracker

[issue16038] ftplib: unlimited readline() from connection

2013-09-04 Thread Giampaolo Rodola'
Giampaolo Rodola' added the comment: I'm attaching a slightly different patch including new tests and which uses a 'maxline' class attribute (as opposed to a global var). Christian if that's OK with you I will wait a while and then make a commit for all Python versions. -- Added file:

[issue16826] Don't check for PYTHONCASEOK if interpreter started with -E

2013-09-04 Thread Meador Inge
Meador Inge added the comment: Reopening to rework test cases. -- resolution: fixed -> stage: committed/rejected -> needs patch status: closed -> open ___ Python tracker ___ ___

[issue18922] Output versions of scripts to stdout

2013-09-04 Thread Berker Peksag
Changes by Berker Peksag : -- nosy: +berker.peksag ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail

[issue7511] msvc9compiler.py: ValueError when trying to compile with VC Express

2013-09-04 Thread Li Wah Teng
Li Wah Teng added the comment: About the "'KEY_BASE' is not defined" error in Steve Dower's diff, I was able to fix it by adding the following line before the KEY_BASE variable is referenced: KEY_BASE = r"Software\Microsoft\\" With this, I was finally able to use the patched msvccompiler9.py

[issue16853] add a Selector to the select module

2013-09-04 Thread STINNER Victor
STINNER Victor added the comment: > New changeset e4d45315c38c by Charles-François Natali in branch 'default': > Issue #16853: Add new selectors module. > http://hg.python.org/cpython/rev/e4d45315c38c Great! Congrats Charles-François for the new module! I tried to implement such module once but

[issue16853] add a Selector to the select module

2013-09-04 Thread Guido van Rossum
Guido van Rossum added the comment: Agreed, this was a great feat of implementation and API design. Is there anything left to do or can we close this issue? (I looked at the Proactor code in Tulip again and I think it is not quite as easy to isolate it, so I'm not requesting that Proactors be

[issue16853] add a Selector to the select module

2013-09-04 Thread Roundup Robot
Roundup Robot added the comment: New changeset 6b14ebe0f7ac by Victor Stinner in branch 'default': Issue #16853: Mention the new selectors module in What's New in Python 3.4 http://hg.python.org/cpython/rev/6b14ebe0f7ac -- ___ Python tracker

[issue16853] add a Selector to the select module

2013-09-04 Thread STINNER Victor
STINNER Victor added the comment: > Is there anything left to do or can we close this issue? It would be nice to mention the new selectors module in the documentation of the select module. -- ___ Python tracker _

[issue16853] add a Selector to the select module

2013-09-04 Thread Antoine Pitrou
Antoine Pitrou added the comment: > > Is there anything left to do or can we close this issue? > > It would be nice to mention the new selectors module in the documentation of > the select module. Feel free to make documentation commits :) They don't necessarily have to pass a review stage. -

[issue16853] add a Selector to the select module

2013-09-04 Thread Roundup Robot
Roundup Robot added the comment: New changeset 142ff216e4b4 by Victor Stinner in branch 'default': Issue #16853: Mention the new selectors module in the select module http://hg.python.org/cpython/rev/142ff216e4b4 -- ___ Python tracker

[issue18923] Use the new selectors module in the subprocess module

2013-09-04 Thread STINNER Victor
New submission from STINNER Victor: Python 3.4 has a new selectors module (issue #16853). It would be nice to use it instead of select.poll or select.select in the subprocess module. -- messages: 196936 nosy: haypo priority: normal severity: normal status: open title: Use the new select

[issue18923] Use the new selectors module in the subprocess module

2013-09-04 Thread STINNER Victor
STINNER Victor added the comment: Other modules using select.select() or select.poll() for more than 1 file descriptor: - asyncore - multiprocessing.connection - multiprocessing.forkserver -- ___ Python tracker _

[issue16853] add a Selector to the select module

2013-09-04 Thread STINNER Victor
STINNER Victor added the comment: > Feel free to make documentation commits :) Ok, done. I also created the issue #18923: "Use the new selectors module in the subprocess module". -- ___ Python tracker __

[issue18823] Idle: use pipes instead of sockets to talk with user subprocess

2013-09-04 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

[issue16853] add a Selector to the select module

2013-09-04 Thread Antoine Pitrou
Antoine Pitrou added the comment: I feel this can be closed then :) Thanks, Charles-François! -- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker ___

[issue16853] add a Selector to the select module

2013-09-04 Thread Charles-François Natali
Charles-François Natali added the comment: > Is there anything left to do or can we close this issue? I usually wait until the test is run on the buildbots to check I didn't break anything: apparently that's OK, so we can close. > It would be nice to mention the new selectors module in the doc

[issue18856] Added test coverage for calendar print functions

2013-09-04 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti stage: -> patch review versions: +Python 2.7, Python 3.3 ___ Python tracker ___ ___

[issue18857] urlencode of a None value uses the string 'None'

2013-09-04 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

[issue18859] README.valgrind should mention --with-valgrind

2013-09-04 Thread Ezio Melotti
Changes by Ezio Melotti : -- type: -> enhancement ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail

[issue18853] Got ResourceWarning unclosed file when running Lib/shlex.py demo

2013-09-04 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

[issue18829] csv produces confusing error message when passed a non-string delimiter

2013-09-04 Thread Ezio Melotti
Ezio Melotti added the comment: IMHO the error should say """TypeError: "delimiter" must be an 1-character string, not bytes""". We could also have two separate errors for "wrong type" and "right type, wrong length" (this would be a ValueError though). -- nosy: +ezio.melotti _

[issue18922] Output versions of scripts to stdout

2013-09-04 Thread Nicola Palumbo
Nicola Palumbo added the comment: Now The Lib/smtpd.py and Tools/i18n/msgfmt.py scripts write their version strings to stdout, and not to sderr. Applying the patch the stdout can be redirect /python.exe Lib/smtpd.py --version >> /dev/null Without the patch: /python.exe Lib/smtpd.py --version >

[issue16853] add a Selector to the select module

2013-09-04 Thread Giampaolo Rodola'
Giampaolo Rodola' added the comment: > Is there anything left to do or can we close this issue? Add support for select.devpoll on Solaris. -- ___ Python tracker ___

[issue18876] Problems with files opened in append mode with io module

2013-09-04 Thread Roundup Robot
Roundup Robot added the comment: New changeset 33bd39b67cc1 by Antoine Pitrou in branch '3.3': Issue #18876: The FileIO.mode attribute now better reflects the actual mode under which the file was opened. http://hg.python.org/cpython/rev/33bd39b67cc1 New changeset b5530669ef70 by Antoine Pitrou

[issue18045] get_python_version is not import in bdist_rpm.py

2013-09-04 Thread Lukas Wunner
Lukas Wunner added the comment: The attached patch adds just the missing import statement (which already exists in all 3.x versions) and changes nothing else. -- nosy: +l Added file: http://bugs.python.org/file31591/issue18045-py27.diff ___ Python tr

[issue18924] Enum members are easily replaced

2013-09-04 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: On Sep 04, 2013, at 07:47 PM, Ethan Furman wrote: >I'm pretty sure we don't want that. Agreed, although a "we're all consenting adults" argument could be made. -- ___ Python tracker

[issue18924] Enum members are easily replaced

2013-09-04 Thread Ethan Furman
Ethan Furman added the comment: I'm not suggesting we try to make it impossible, just tougher (akin to what we did with the name and value attributes on an Enum member -- at Guido's behest, no less ;). -- ___ Python tracker

[issue18924] Enum members are easily replaced

2013-09-04 Thread Eli Bendersky
Eli Bendersky added the comment: Time for your friendly devil's advocate... We're using and loving this language: >>> class Foo: ... bar = 2 ... >>> f = Foo() >>> f.bar 2 >>> f.bar = 42 >>> f.bar 42 >>> So let's stop trying to make enums even more alien. This is a non-issue in Python. [B

[issue18924] Enum members are easily replaced

2013-09-04 Thread Ethan Furman
New submission from Ethan Furman: Python 3.4.0a1+ (default:33727fbb4668+, Aug 31 2013, 12:34:55) [GCC 4.7.3] on linux Type "help", "copyright", "credits" or "license" for more information. --> import enum --> class Test(enum.Enum): ... this = 'that' ... --> Test.this --> Test.this = 9 --> Te

[issue18924] Enum members are easily replaced

2013-09-04 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: On Sep 04, 2013, at 08:18 PM, Eli Bendersky wrote: >[Barry, how come your name in the tracker is linked to your website? me >wants...] Go to "Your Details" in the left sidebar and enter a "Homepage". -- ___ Python

[issue18924] Enum members are easily replaced

2013-09-04 Thread Eli Bendersky
Eli Bendersky added the comment: "You do not have permission to edit user" - in a red banner, no less. Blasphemy. -- ___ Python tracker ___ __

[issue18808] Thread.join returns before PyThreadState is destroyed

2013-09-04 Thread Tim Peters
Tim Peters added the comment: Oh, I'm not opposed, I'm just complaining ;-) It would be much nicer to have an approach that worked for all thread users, not just threading.Thread users. For example, a user can easily (well, plausibly) get into the same kinds of troubles here by calling _thre

[issue16853] add a Selector to the select module

2013-09-04 Thread Giampaolo Rodola'
Giampaolo Rodola' added the comment: I have realized just now that at least epoll() and kqueue() selectors could take advantage and define their own modify() method (there was even a TODO I totally missed). Anyway, from now on I'm gonna file separate issues. -- __

[issue18925] select.poll.modify is not documented

2013-09-04 Thread Giampaolo Rodola'
New submission from Giampaolo Rodola': It was introduced in Python 2.6: http://bugs.python.org/issue1657 Will commit a patch soon. -- assignee: docs@python components: Documentation messages: 196953 nosy: docs@python, giampaolo.rodola priority: normal severity: normal status: open title:

[issue13153] IDLE crashes when pasting non-BMP unicode char on Py3

2013-09-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This bug can be reproduced on Linux too. Just copy and paste illegal UTF-8 sequence. I.e. b'\xed\xb2\x80' or b'\xc0\x80'. My patch works with first example but failed with second. When change the error handler in fromTclStringAndSize() to "replace" it works

[issue18924] Enum members are easily replaced

2013-09-04 Thread Ethan Furman
Ethan Furman added the comment: Eli Bendersky added the comment: > > So let's stop trying to make enums even more alien. This is a non-issue in > Python. Enumerations are supposed to be constant. Since this is Python there is actually very little that cannot be changed, but we can make objec

[issue18924] Enum members are easily replaced

2013-09-04 Thread Eli Bendersky
Eli Bendersky added the comment: On Wed, Sep 4, 2013 at 1:57 PM, Ethan Furman wrote: > > Ethan Furman added the comment: > > Eli Bendersky added the comment: > > > > So let's stop trying to make enums even more alien. This is a non-issue > in Python. > > Enumerations are supposed to be constant

[issue18879] tempfile.NamedTemporaryFile can close the file too early, if not assigning to a variable

2013-09-04 Thread jort bloem
jort bloem added the comment: I am only new to Python, but... Having looked at the code, I am surprised that the _TemporaryFileWrapper is not a subclass of "file". Surely that would be the "python" way, and would solve this problem, too? __getattr__ would no longer be needed. The opening of th

[issue18922] Output versions of scripts to stdout

2013-09-04 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- stage: needs patch -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscri

[issue18876] Problems with files opened in append mode with io module

2013-09-04 Thread Antoine Pitrou
Antoine Pitrou added the comment: I have committed your patch. Thank you! -- ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue18876] Problems with files opened in append mode with io module

2013-09-04 Thread Roundup Robot
Roundup Robot added the comment: New changeset fc2b88a27fa1 by Antoine Pitrou in branch '2.7': Issue #18876: The FileIO.mode attribute now better reflects the actual mode under which the file was opened. http://hg.python.org/cpython/rev/fc2b88a27fa1 -- _

[issue18924] Enum members are easily replaced

2013-09-04 Thread Ethan Furman
Ethan Furman added the comment: Yes, as a matter of fact: --> Test.this --> Test.this = 'other' --> Test.this 'other' --> Test('that') --> list(Test) [] As you can see, the Test Enum becomes inconsistent if this is allowed. -- ___ Python tracker

[issue18927] Lock.acquire() docs incorrect about negative timeout

2013-09-04 Thread Tim Peters
New submission from Tim Peters: Here from the 3.3.2 docs for threading.Lock: """ acquire(blocking=True, timeout=-1) Acquire a lock, blocking or non-blocking. ... When invoked with the floating-point timeout argument set to a positive value, block for at most the number of seconds specified b

[issue18924] Enum members are easily replaced

2013-09-04 Thread Eric Snow
Eric Snow added the comment: I'm also -1, though I do appreciate the "indicating intent" argument. What's the risk that someone will accidentally overwrite an enum item? Also, is there other enum functionality that relies on the continued existence of the initial enum items? If not then I'm

[issue18925] select.poll.modify is not documented

2013-09-04 Thread STINNER Victor
STINNER Victor added the comment: For your information, epoll.closed and kqueue.closed were not documented. I documented them recently in Python 3.4 doc. -- nosy: +haypo ___ Python tracker

[issue18926] plistlib - str converted to bool

2013-09-04 Thread Ray
Ray added the comment: Disregard, I think. I'm not sure why, but my current app seems to be doing the converting. >>> import plistlib >>> pl = {'My key': 'False'} >>> plist = plistlib.writePlistToString(pl) >>> plist '\nhttp://www.apple.com/DTDs/PropertyList-1.0.dtd";>\n\n\n\tMy key\n\tFalse\

[issue18808] Thread.join returns before PyThreadState is destroyed

2013-09-04 Thread Tim Peters
Tim Peters added the comment: Oops! The docs are wrong - a negative timeout actually raises: ValueError: timeout value must be strictly positive unless the timeout is exactly -1. All the more reason to ensure that a negative waittime isn't passed. I opened a different issue about the doc gl

[issue18926] plistlib - str converted to bool

2013-09-04 Thread Raymond Piller
New submission from Raymond Piller: A plist with: My key False will parse to a dict as: {'My key': False} Expected: {'My key': 'False'} If bool(False) is needed, the plist should say: My key -- messages: 196959 nosy: VertigoRay priority: normal severity: normal status: open title: pl

[issue18909] Segfaults on win-amd64 due to corrupt pointer to Tkapp_Interp

2013-09-04 Thread Roundup Robot
Roundup Robot added the comment: New changeset f01e06d26b41 by Victor Stinner in branch '3.3': Issue #18909: Fix _tkinter.tkapp.interpaddr() on Windows 64-bit, don't cast http://hg.python.org/cpython/rev/f01e06d26b41 New changeset ac27d979078a by Victor Stinner in branch 'default': (Merge 3.3) I

[issue18909] Segfaults on win-amd64 due to corrupt pointer to Tkapp_Interp

2013-09-04 Thread STINNER Victor
STINNER Victor added the comment: > New changeset 1a65bb15dedf by Victor Stinner in branch '2.7': > Issue #18909: Fix _tkinter.tkapp.interpaddr() on Windows 64-bit, don't cast > http://hg.python.org/cpython/rev/1a65bb15dedf I prefer to use a function taking a void* instead of hoping that Py_ssiz

[issue18909] Segfaults on win-amd64 due to corrupt pointer to Tkapp_Interp

2013-09-04 Thread Christoph Gohlke
Christoph Gohlke added the comment: @haypo: Thanks for fixing this so fast! Your changes work for me on win-amd64-py2.7 and py3.3. I am aware of two 3rd party C extensions that use the value of interpaddr(): https://github.com/python-imaging/Pillow/blob/master/_imagingtk.c#L40 https://github.

[issue18928] Remove misleading documentation for random.shuffle

2013-09-04 Thread David Benbennick
New submission from David Benbennick: Since Python 2.1 [1], when random.shuffle was added, the documentation has said: """Note that for even rather small len(x), the total number of permutations of x is larger than the period of most random number generators; this implies that most permutation

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

2013-09-04 Thread Nikolaus Rath
Nikolaus Rath added the comment: On 09/04/2013 06:03 AM, Eli Bendersky wrote: > Why guess... did you try it in the code? I don't follow... why guess what? And try what in code? > it would be nice to have a short code sample here demonstrating what's > happening. The paragraph you're quoting se

[issue18874] Add a new tracemalloc module to trace memory allocations

2013-09-04 Thread Alexander Belopolsky
Changes by Alexander Belopolsky : -- nosy: +belopolsky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://

[issue18929] inspect.classify_class_attrs ignores metaclass

2013-09-04 Thread Ethan Furman
New submission from Ethan Furman: Part of the solution for Issue18693 is to have `inspect.classify_class_attrs()` properly consider the metaclass (or type) of the class when searching for the origination point of class attributes. The fix is changing line 325: -for base in (cls,) + mr

[issue18929] inspect.classify_class_attrs ignores metaclass

2013-09-04 Thread Ethan Furman
Changes by Ethan Furman : Added file: http://bugs.python.org/file31594/local_fix.stoneleaf.01 ___ Python tracker ___ ___ Python-bugs-list mail

  1   2   >