[issue26177] tkinter: Canvas().keys returns empty strings.

2016-01-21 Thread Terry J. Reedy
Terry J. Reedy added the comment: Bug came from https://stackoverflow.com/questions/34911069/tk-canvas-options-keys-list-empy. Bryan Oakley answered that tk.Canvas().configure().keys() does work, making sorted(x.configure.keys()) a replacement for x.keys that should work for all widgets. --

[issue26177] tkinter: Canvas().keys returns empty strings.

2016-01-21 Thread Terry J. Reedy
New submission from Terry J. Reedy: tkinter wraps tk widgets as option-value mappings with subscripting and .keys(). The latter does not work for Canvas (subscripting does). First tested with 3.5.1, Win 10. First Text versus Canvas contrast below was confirmed with 2.7.11. >>> import tkinte

[issue26108] Calling PyInitialize with 2.7.11 on Windows x64 terminates process

2016-01-21 Thread David Heffernan
David Heffernan added the comment: Why was this closed as "not a bug"? Shouldn't it have been closed as a duplicate? -- ___ Python tracker ___ __

[issue23965] test_ssl failure on Fedora 22

2016-01-21 Thread Nick Coghlan
Nick Coghlan added the comment: This is working fine on Fedora 23, so yeah, I think the change to always disallow SSLv3 by default resolved it. -- resolution: -> out of date status: open -> closed ___ Python tracker

[issue23845] test_ssl: fails on recent libressl with SSLV3_ALERT_HANDSHAKE_FAILURE

2016-01-21 Thread Martin Panter
Martin Panter added the comment: Is this still relevant? At least the first part of the patch won’t be needed after SSLv3 was also disabling by default in Python: Issue 25530, revision 56f64ec9259f. See also Issue 25724 about Ubuntu disabling it a different way. -- nosy: +martin.panter

[issue25724] SSLv3 test failure on Ubuntu 16.04 LTS

2016-01-21 Thread Martin Panter
Martin Panter added the comment: This sounds like a Ubuntu-specific hack. Maybe it would be better to adjust the @skip_if_broken_ubuntu_ssl decorator? Also, according to Issue 25530, Python 3.4+ and 2.7 set OP_NO_SSLv3 by default, and according to Issue 23845, maybe some versions of Open SSL d

[issue23965] test_ssl failure on Fedora 22

2016-01-21 Thread Martin Panter
Martin Panter added the comment: Sorry bug disabling v3 by default is Issue 25530 -- ___ Python tracker ___ ___ Python-bugs-list maili

[issue23965] test_ssl failure on Fedora 22

2016-01-21 Thread Martin Panter
Martin Panter added the comment: I suspect the patches here are out of date considering SSL v3 has been disabled by default in Python via Issue 25613, revision 56f64ec9259f. Is there any bits of the patches worth resurrecting (for cleaner logic, future-proofing or something)? Or is this comple

[issue26175] Fully implement IOBase abstract on SpooledTemporaryFile

2016-01-21 Thread Martin Panter
Martin Panter added the comment: It would be nice to add test cases for this. Looking at , there is a version changed notice for the truncate() method. So perhaps this should be added as a new feature f

[issue26176] EmailMessage example doesn't work

2016-01-21 Thread Srujan Chaitanya
New submission from Srujan Chaitanya: Example provided in 19.1.14.1. Examples using the Provisional API at https://docs.python.org/3.4/library/email-examples.html?highlight=email%20example Doesn't work. This could be a EmailMessage class issue also? -- assignee: docs@python components:

[issue26169] Pasting 900000 chars into a tk Entry widget fails

2016-01-21 Thread Terry J. Reedy
Terry J. Reedy added the comment: Soufiane, when a core developer (indicated by the Python icon after the name) changes a header, do not change it back. Comment on the change if you want, but leave it as is. My revised title accurately describes the core problem: the paste operation does not

[issue26171] heap overflow in zipimporter module

2016-01-21 Thread Insu Yun
Insu Yun added the comment: in zipimport.c 1116 bytes_size = compress == 0 ? data_size : data_size + 1; 1117 if (bytes_size == 0) 1118 bytes_size++; 1119 raw_data = PyBytes_FromStringAndSize((char *)NULL, bytes_size); If compress != 0, then bytes_size = data_size + 1

[issue25830] _TypeAlias: Discrepancy between docstring and behavior

2016-01-21 Thread Guido van Rossum
Guido van Rossum added the comment: Actually isinstance() shouldn't be supported by most things in typing.py (except for those that mimic existing collection ABCs). Even issubclass() should be taken out according to the BDFL-delegate for PEP 484. See https://github.com/ambv/typehinting/issues/136

[issue24985] Python install test fails - OpenSSL - "dh key too small"

2016-01-21 Thread Martin Panter
Martin Panter added the comment: I suspect this is fixed in 3.4.4. The 512-bit file was replaced by a 1024-bit (or 2014-bit if you believe the commit message :) one in Issue 23844, revision 1ad7c0253abe. -- components: +Tests -Installation nosy: +martin.panter resolution: -> duplicate

[issue25830] _TypeAlias: Discrepancy between docstring and behavior

2016-01-21 Thread Berker Peksag
Berker Peksag added the comment: Looks like the docstring is a bit misleading. ``isinstance(m, Match)`` behavior is already tested in the test suite: https://hg.python.org/cpython/file/default/Lib/test/test_typing.py#l1297 -- nosy: +berker.peksag, gvanrossum __

[issue24761] ERROR: test_dh_params (test.test_ssl.ThreadedTests)

2016-01-21 Thread Martin Panter
New submission from Martin Panter: Same error log with a few more details in Issue 24985. -- nosy: +martin.panter resolution: -> duplicate status: open -> closed superseder: -> Python install test fails - OpenSSL - "dh key too small" ___ Python trac

[issue24930] test_ssl: try more protocols in test_options()

2016-01-21 Thread Martin Panter
Martin Panter added the comment: Your patch removes the testing of getting ctx.options. However, OP_NO_SSLv3 was enabled by default and added to the test in Issue 25530, so I suspect that problem is no longer valid. I guess that leaves the rest of your patch which exercises other protocol val

[issue18620] multiprocessing page leaves out important part of Pool example

2016-01-21 Thread Berker Peksag
Berker Peksag added the comment: Thanks for the patch, Davin. I tweaked code style a bit and removed trailing whitespaces. -- nosy: +berker.peksag resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: -Python 3.4 ___

[issue18620] multiprocessing page leaves out important part of Pool example

2016-01-21 Thread Roundup Robot
Roundup Robot added the comment: New changeset 9480e217ade0 by Berker Peksag in branch '2.7': Issue #18620: Improve Pool examples in multiprocessing documentation https://hg.python.org/cpython/rev/9480e217ade0 -- ___ Python tracker

[issue18620] multiprocessing page leaves out important part of Pool example

2016-01-21 Thread Roundup Robot
Roundup Robot added the comment: New changeset c89f4f59872f by Berker Peksag in branch '3.5': Issue #18620: Improve Pool examples in multiprocessing documentation https://hg.python.org/cpython/rev/c89f4f59872f New changeset 9f201578d8d9 by Berker Peksag in branch 'default': Issue #18620: Improve

[issue19225] lack of PyExc_BufferError doc

2016-01-21 Thread Gedai Tamás Bence
Gedai Tamás Bence added the comment: Let me try to solve this issue. Will be back in 4 days. -- nosy: +beng94 ___ Python tracker ___ _

[issue26175] Fully implement IOBase abstract on SpooledTemporaryFile

2016-01-21 Thread Gary Fernie
New submission from Gary Fernie: SpooledTemporaryFile does not fully satisfy the abstract for IOBase. Namely, `seekable`, `readable`, and `writable` are missing. This was discovered when seeking a SpooledTemporaryFile-backed lzma file. You may quickly repro this: `lzma.open(SpooledTemporaryFile(

[issue25613] fix ssl tests with sslv3 disabled

2016-01-21 Thread Martin Panter
Martin Panter added the comment: Sounds like this should be partly fixed via Issue 25530, and now Issue 25724 has been opened about the remaining problem (the patch there includes the same change from the Launchpad link). -- nosy: +martin.panter resolution: -> duplicate status: open -

[issue26169] Crash Python IDLE 2.7.11

2016-01-21 Thread Soufiane BOUSSALI
Soufiane BOUSSALI added the comment: The Function Find In Python IDLE 2.7.11 Affected To Crash Python Environnement On Windows Platform -- title: Pasting 90 chars into a tk Entry widget fails -> Crash Python IDLE 2.7.11 Added file: http://bugs.python.org/file41684/py2.7.11.png ___

[issue25520] unittest load_tests protocol not working as documented

2016-01-21 Thread Stefan Seefeld
Stefan Seefeld added the comment: I believe what I actually want is for the discovery mechanism to be fully implicit. It turns out that already *almost* works right now. What doesn't work (and what this bug report really was about initially), is the use of the 'discover' command with the '-p "

[issue11551] test_dummy_thread.py test coverage improvement

2016-01-21 Thread Mark Lawrence
Changes by Mark Lawrence : -- nosy: -BreamoreBoy ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.

[issue26174] Exception alias cause destruction of existing variable

2016-01-21 Thread Brett Cannon
Brett Cannon added the comment: So the exception is explicitly deleted when the `except` block is exited to prevent leaking memory from the traceback attached to the exception. Hence there's an implicit `del e` at the end of the `except` block which is what you're running up against. But I'm

[issue26174] Exception alias cause destruction of existing variable

2016-01-21 Thread Zachary Ware
Zachary Ware added the comment: I don't believe this is a bug. 1) try/except does not introduce a new scope 2) 'except E as N' is just name assignment 3) except clauses are documented to always delete the exception alias at the end of the except block[0]. The example in the docs could be clari

[issue25909] Incorrect documentation for PyMapping_Items and like

2016-01-21 Thread Senthil Kumaran
Senthil Kumaran added the comment: Thanks for the patch. I had to do some minor clarification like mention view types apply only to dict and also remove the sentence which mentioned those equivalent to list(o.values()) and list(o.items()) in the patch. With those fixed, I have commited the cha

[issue26099] site ignores ImportError when running sitecustomize and usercustomize

2016-01-21 Thread Brett Cannon
Brett Cannon added the comment: Semantics are fine (I initially misread what you wanted to do; sorry). And I wouldn't backport since it's an enhancement and not a bugfix. -- ___ Python tracker

[issue26099] site ignores ImportError when running sitecustomize and usercustomize

2016-01-21 Thread Brett Cannon
Changes by Brett Cannon : -- assignee: -> haypo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

[issue25909] Incorrect documentation for PyMapping_Items and like

2016-01-21 Thread Roundup Robot
Roundup Robot added the comment: New changeset e57949f5d0a9 by Senthil Kumaran in branch '3.5': issue25909 - Correct the documentation of PyMapping_Items, PyMapping_Keys and https://hg.python.org/cpython/rev/e57949f5d0a9 New changeset 739e1b0032c6 by Senthil Kumaran in branch 'default': merge fr

[issue26107] PEP 511: code.co_lnotab: use signed line number delta to support moving instructions in an optimizer

2016-01-21 Thread Roundup Robot
Roundup Robot added the comment: New changeset c6fb1651ea2e by Victor Stinner in branch 'default': Issue #26107: Fix typo in Objects/lnotab_notes.txt https://hg.python.org/cpython/rev/c6fb1651ea2e -- ___ Python tracker

[issue26146] PEP 511: Add ast.Constant to allow AST optimizer to emit constants

2016-01-21 Thread STINNER Victor
Changes by STINNER Victor : -- dependencies: +code_richcompare() don't use constant type when comparing code constants ___ Python tracker ___ ___

[issue26146] PEP 511: Add ast.Constant to allow AST optimizer to emit constants

2016-01-21 Thread STINNER Victor
STINNER Victor added the comment: > We also make no backwards-compatibility guarantees about the AST, so if it > simplifies things to switch entirely to Constant from Num, etc. then I said > do it. Replacing Num/Str/... with Constant causes bug in markerlib (used by pip, it breaks indirectly

[issue26099] site ignores ImportError when running sitecustomize and usercustomize

2016-01-21 Thread STINNER Victor
STINNER Victor added the comment: @Brett: Ping? I'm going to push the fix to Python 3.6. Tell me if you are ok to backport the change to Python 2.7 and 3.5 too. -- ___ Python tracker __

[issue26174] Exception alias cause destruction of existing variable

2016-01-21 Thread Ethan Furman
Changes by Ethan Furman : -- nosy: +ethan.furman ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.p

[issue26174] Exception alias cause destruction of existing variable

2016-01-21 Thread Jan Pokorny
New submission from Jan Pokorny: Encountered a weird behavior when working with variable with the same name as exception's alias. Observed behavior: - In case variable with the same name (e.g. 'e') already exists when any 'except Error as e' block is executed, the 'e' variable is removed afte

[issue25843] code_richcompare() don't use constant type when comparing code constants

2016-01-21 Thread STINNER Victor
STINNER Victor added the comment: Updated patch version 5. > I meant that set shouldn't be handled in _PyCode_ConstantKey at all. Only > frozenset constants can be considered equal. Sets as well as lists all should > be different. Ok, I dropped support for set type to only keep support for fr

[issue8690] multiprocessing.dummy.Queue does not expose same interface as multiprocessing.Queue

2016-01-21 Thread Berker Peksag
Changes by Berker Peksag : -- nosy: +berker.peksag stage: -> needs patch type: -> enhancement versions: +Python 3.6 -Python 2.6, Python 2.7, Python 3.1, Python 3.2 ___ Python tracker __

[issue26144] test_pkg test_4 and/or test_7 sometimes fail

2016-01-21 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- nosy: +brett.cannon, eric.snow, ncoghlan ___ Python tracker ___ ___ Python-bugs-list mailing list Uns

[issue26144] test_pkg test_4 and/or test_7 sometimes fail

2016-01-21 Thread Martin Panter
Martin Panter added the comment: I think I traced this to revision fbbf8b160e8d (Issue 9548, Python 3.4). Before that revision, I haven’t been able to produce the failures. Also, reverting that change in the current default branch seems to stop the failures. Attached is the patch that reverts

[issue26173] test_ssl.bad_cert_test() exception handling

2016-01-21 Thread Martin Panter
New submission from Martin Panter: In bad_cert_test(), there are two OSError exception handler; one masking the other. In Python 3, I think we should remove the second (dead) handler. In Python 2, maybe the first OSError handler should catch socket.error instead. Originally, in r80534, socket.

[issue25591] refactor imaplib tests

2016-01-21 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : Added file: http://bugs.python.org/file41680/new_imap_tests_v3.diff ___ Python tracker ___ ___ Python-bugs-list

[issue25591] refactor imaplib tests

2016-01-21 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- nosy: +serhiy.storchaka ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:

[issue25843] code_richcompare() don't use constant type when comparing code constants

2016-01-21 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I meant that set shouldn't be handled in _PyCode_ConstantKey at all. Only frozenset constants can be considered equal. Sets as well as lists all should be different. There is yet one issue with string and bytes literals. When run Python with the -b option:

[issue25907] Documentation i18n: Added trans tags in sphinx templates

2016-01-21 Thread STINNER Victor
STINNER Victor added the comment: > @haypo I used the ``{trans}`` ``{endtrans}`` syntax because [Sphinx uses > Jinja](http://www.sphinx-doc.org/en/stable/templating.html) and [``{trans}`` > is the Jinja syntax for > internationalisation](http://jinja.pocoo.org/docs/dev/templates/#i18n) Oh ok,

[issue11551] test_dummy_thread.py test coverage improvement

2016-01-21 Thread Berker Peksag
Berker Peksag added the comment: Thanks for the patch, Denver. Two things: 1. MockFunction needs to be replaced with unittest.mock.Mock. 2. Comments from Sandro and Ezio needs to be addressed. -- nosy: +berker.peksag stage: patch review -> needs patch versions: +Python 3.5, Python 3.6

[issue25907] Documentation i18n: Added trans tags in sphinx templates

2016-01-21 Thread Julien
Julien added the comment: That's also the actual syntax used by existing Sphinx templates: mandark@windhowl$ grep -r '{% trans' ~/.local/lib/python3.4/site-packages/sphinx_rtd_theme/ footer.html:{% trans path=pathto('copyright'), copyright=copyright|e %}© Copyright {{ copyrigh

[issue25907] Documentation i18n: Added trans tags in sphinx templates

2016-01-21 Thread Julien
Julien added the comment: @haypo I used the ``{trans}`` ``{endtrans}`` syntax because [Sphinx uses Jinja](http://www.sphinx-doc.org/en/stable/templating.html) and [``{trans}`` is the Jinja syntax for internationalisation](http://jinja.pocoo.org/docs/dev/templates/#i18n) So ``{trans}`` is the

[issue26167] Improve copy.copy speed for built-in types (list/set/dict)

2016-01-21 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Oh, sorry. Here is a patch. -- keywords: +patch Added file: http://bugs.python.org/file41679/copy_speedup.patch ___ Python tracker ___ ___

[issue25520] unittest load_tests protocol not working as documented

2016-01-21 Thread Michael Foord
Michael Foord added the comment: To find and run tests recursively from a test package you want test discovery rather than (necessarily) load_tests. For a bug report, please describe the behaviour you expect and the behaviour you're seeing instead. --

[issue15809] 2.7 IDLE console uses incorrect encoding.

2016-01-21 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It would be nice to add configuration option for IDLE Shell encoding and highlight non-encodable characters in Shell and Editor. But this feature is needed mainly for 2.7. -- resolution: -> fixed stage: patch review -> resolved status: open -> close

[issue26169] Pasting 900000 chars into a tk Entry widget fails

2016-01-21 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I can't reproduce the issue on Linux with the Entry widget, but can reproduce it with the Text widget. The difference is that the Text widget wraps its content on multiple lines. Looks the code for dynamical splitting the text on lines has quadratic (or larg

[issue5001] Remove assertion-based checking in multiprocessing

2016-01-21 Thread Berker Peksag
Changes by Berker Peksag : -- nosy: +berker.peksag type: -> enhancement versions: +Python 3.6 -Python 2.7, Python 3.4, Python 3.5 ___ Python tracker ___ _

[issue2931] optparse: various problems with unicode and gettext

2016-01-21 Thread Sean Wang
Sean Wang added the comment: when an unicode option.default_value could not be ascii encoded, it would throw exception, detailed logs below: File "/Users/seanwang/Documents/dev/foo/bar.py", line 119, in main parser.print_help() File "/usr/local/Cellar/python/2.7.10_2/Frameworks/Python.f

[issue26106] Move licences to literal blocks

2016-01-21 Thread STINNER Victor
Changes by STINNER Victor : -- resolution: -> fixed status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue25907] Documentation i18n: Added trans tags in sphinx templates

2016-01-21 Thread STINNER Victor
STINNER Victor added the comment: The patch only changes Doc/tools/templates/indexcontent.html. (Simplified) example of change on Doc/tools/templates/indexcontent.html: "What's new in Python {{ version }}?" becomes "{% trans %}What's new in Python {{ version }}?{% endtrans %}" I'm not

[issue26106] Move licences to literal blocks

2016-01-21 Thread STINNER Victor
STINNER Victor added the comment: Thanks for your effort of translation the doc. FYI the doc can be read at http://www.afpy.org/doc/python/ and the project (source) is at https://github.com/AFPY/python_doc_fr/ -- nosy: +haypo ___ Python tracker

[issue26106] Move licences to literal blocks

2016-01-21 Thread Roundup Robot
Roundup Robot added the comment: New changeset f2a0a4a45292 by Victor Stinner in branch '2.7': Issue #26106: doc: Move text of licenses to parsed literal block https://hg.python.org/cpython/rev/f2a0a4a45292 -- ___ Python tracker

[issue2931] optparse: various problems with unicode and gettext

2016-01-21 Thread Sean Wang
Sean Wang added the comment: Sorry, missed one condition: I used `unicode_literals` in Python 2.7.10, example below: >>> from __future__ import unicode_literals >>> str('api名称') Traceback (most recent call last): File "", line 1, in UnicodeEncodeError: 'ascii' codec can't encode characters in

[issue2931] optparse: various problems with unicode and gettext

2016-01-21 Thread Sean Wang
Sean Wang added the comment: This bug still exists in Python 2.7.10 with optparse version 1.5.3. When the default_value is not ASCII encoded, it would raise `UnicodeEncodeError: 'ascii' codec can't encode characters` this error is due to the `str` usage in `expand_default` method: def expa