[issue27286] str object got multiple values for keyword argument

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 34d24c51eab6 by Serhiy Storchaka in branch '3.5':
Issue #27286: Fixed compiling BUILD_MAP_UNPACK_WITH_CALL opcode.  Calling
https://hg.python.org/cpython/rev/34d24c51eab6

New changeset 194549801bd5 by Serhiy Storchaka in branch 'default':
Issue #27286: Fixed compiling BUILD_MAP_UNPACK_WITH_CALL opcode.  Calling
https://hg.python.org/cpython/rev/194549801bd5

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25455] Some repr implementations don't check for self-referential structures

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset e44bd1259bda by Serhiy Storchaka in branch '3.5':
Issue #25455: Fixed a crash in repr of ElementTree.Element with recursive tag.
https://hg.python.org/cpython/rev/e44bd1259bda

New changeset e3671a684ea0 by Serhiy Storchaka in branch 'default':
Issue #25455: Fixed a crash in repr of ElementTree.Element with recursive tag.
https://hg.python.org/cpython/rev/e3671a684ea0

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16484] pydoc generates invalid docs.python.org link for xml.etree.ElementTree and other modules

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset ede10138327e by Martin Panter in branch '2.7':
#16484: Change PYTHONDOCS to "https:", and fix links to use lowercase
https://hg.python.org/cpython/rev/ede10138327e

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27030] Remove deprecated re features

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset a2482e805dff by Martin Panter in branch '3.5':
Fix buggy RE “\parrot_example.py”, uncovered by Issue #27030
https://hg.python.org/cpython/rev/a2482e805dff

New changeset be193f8dbe4c by Martin Panter in branch 'default':
Issue #27030: Merge RE fix from 3.5
https://hg.python.org/cpython/rev/be193f8dbe4c

New changeset c5411cfa0bd3 by Martin Panter in branch '2.7':
Fix buggy RE “\parrot_example.py”, uncovered by Issue #27030
https://hg.python.org/cpython/rev/c5411cfa0bd3

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27277] Fatal Python error: Segmentation fault in test_exceptions

2016-06-11 Thread Rohit Mediratta

Rohit Mediratta added the comment:

Leads to the same Segfault


[/loc/rom/pyd/cpython] $ ./python -m test test_exceptions
Run tests sequentially
0:00:00 [1/1] test_exceptions
Fatal Python error: Segmentation fault

Current thread 0x7fb466572700 (most recent call first):
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 490 in 
f
  File "/local/romedira/pydev/cpython/Lib/test/test_exceptions.py", line 4

[issue16484] pydoc generates invalid docs.python.org link for xml.etree.ElementTree and other modules

2016-06-11 Thread Martin Panter

Martin Panter added the comment:

Thanks Kaushik. I also changed the https:// detection to also detect http://, 
to maintain backwards compatibility.

I am porting these changes to 2.7.

--
versions: +Python 2.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27277] Fatal Python error: Segmentation fault in test_exceptions

2016-06-11 Thread Berker Peksag

Berker Peksag added the comment:

Can you please try without coveragepy?

./python -m test test_exceptions

--
nosy: +berker.peksag

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27186] add os.fspath()

2016-06-11 Thread Martin Panter

Martin Panter added the comment:

Test_fspath_protocol_bytes() (added in revision 5a62d682636e) fails on Windows:

http://buildbot.python.org/all/builders/AMD64%20Windows7%20SP1%203.x/builds//steps/test/logs/stdio
==
ERROR: test_fspath_protocol_bytes (test.test_os.TestScandir)
--
Traceback (most recent call last):
  File "C:\buildbot.python.org\3.x.kloth-win64\build\lib\test\test_os.py", line 
2958, in test_fspath_protocol_bytes
bytes_entry = self.create_file_entry(name=bytes_filename)
  File "C:\buildbot.python.org\3.x.kloth-win64\build\lib\test\test_os.py", line 
2932, in create_file_entry
return self.get_entry(os.path.basename(filename))
  File "C:\buildbot.python.org\3.x.kloth-win64\build\lib\test\test_os.py", line 
2923, in get_entry
entries = list(os.scandir(path))
TypeError: os.scandir() doesn't support bytes path on Windows, use Unicode 
instead

--
nosy: +martin.panter

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25455] Some repr implementations don't check for self-referential structures

2016-06-11 Thread Stefan Behnel

Stefan Behnel added the comment:

Etree patch looks straight forward to me, feel free to apply it.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26867] test_ssl test_options fails on ubuntu 16.04

2016-06-11 Thread Larry Hastings

Larry Hastings added the comment:

This still affects 3.4 and 3.5.  It'd be lovely if it could be fixed in all the 
still-alive versions.  (Yes, this is technically a "bug fix", but I'd still 
like it fixed in 3.4.)

--
versions: +Python 3.4, Python 3.5

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16484] pydoc generates invalid docs.python.org link for xml.etree.ElementTree and other modules

2016-06-11 Thread Berker Peksag

Changes by Berker Peksag :


--
type: compile error -> behavior

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27299] urllib does not splitport while putrequest realhost to HTTP headers

2016-06-11 Thread gr zhang

gr zhang added the comment:

Yes, I mean when set h.putheader('Host', "www.github.com:443") and the status 
code from httplib will be 405 while when set h.putheader('Host', 
"www.github.com") the code will be 200, this is confused to me.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26867] test_ssl test_options fails on ubuntu 16.04

2016-06-11 Thread Matthias Klose

Matthias Klose added the comment:

ubuntu doesn't do anything crazy, but just disables oldish, deprecated und 
probably now unsecure ssl protocols.  This is done by other vendors as well.   
From my point of of view this skip_if_ubuntu stuff should be replaced by proper 
feature tests.  I'll see if I can come up with another work around.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27095] Simplify MAKE_FUNCTION

2016-06-11 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Added more comments on Rietveld.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16484] pydoc generates invalid docs.python.org link for xml.etree.ElementTree and other modules

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset c60d2e4f4f96 by Martin Panter in branch '2.7':
Issue #16484: PYTHONDOCS still uses “http:” in Python 2
https://hg.python.org/cpython/rev/c60d2e4f4f96

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26867] test_ssl test_options fails on ubuntu 16.04

2016-06-11 Thread Larry Hastings

Larry Hastings added the comment:

I got this when testing 3.5.2rc1 on my Ubuntu 16.04 machine.  CAs Xiang Zhang 
showed, this is Ubuntu doing something crazy.  I ignored the failure and 
shipped 3.5.2rc1, however I would be interested in suppressing the test for 
3.5.2 final.  That way it has a chance of passing the whole test suite on 
user's Linux machines...!

--
nosy: +larry

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16484] pydoc generates invalid docs.python.org link for xml.etree.ElementTree and other modules

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset d84268ed62ac by Martin Panter in branch '3.5':
Issue #16484: Fix pydoc link and test on Windows, by Kaushik Nadikuditi
https://hg.python.org/cpython/rev/d84268ed62ac

New changeset 84d1e5a4b1c5 by Martin Panter in branch 'default':
Issue #16484: Merge pydoc Windows fixes from 3.5
https://hg.python.org/cpython/rev/84d1e5a4b1c5

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5124] IDLE - pasting text doesn't delete selection

2016-06-11 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Ah, I looked on 3.5 change and missed that in 3.6 you test both tkinter.Entry 
and ttk.Entry.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5124] IDLE - pasting text doesn't delete selection

2016-06-11 Thread Terry J. Reedy

Terry J. Reedy added the comment:

Serhiy: entry=entry as much as any name=expression pair to print the value of 
variable entry on test failure, either "entry=)" or "entry=)", as in

==
FAIL: test_paste_entry (__main__.PasteTest) (ans='two', end='end', 
entry=)
Test pasting into an entry with and without a selection.
--
Traceback (most recent call last):
  File "F:\Python\dev\36\lib\idlelib\idle_test\test_editmenu.py", line 53, in 
test_paste_entry
self.assertTrue(False)
AssertionError: False is not true

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27299] urllib does not splitport while putrequest realhost to HTTP headers

2016-06-11 Thread Xiang Zhang

Xiang Zhang added the comment:

The standard[1] says the Host header is OK to include port. Why not use 
'https://www.github.com'?

[1] https://tools.ietf.org/html/rfc7230#section-5.4

--
nosy: +xiang.zhang

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27299] urllib does not splitport while putrequest realhost to HTTP headers

2016-06-11 Thread gr zhang

New submission from gr zhang:

h.putheader('Host', "www.github.com:443") 
# this will make errcode 405, if urllib lib splitport first, and this will set 
Host ---> www.github.com and get 200 code.
h.endheaders(None)
errcode, errmsg, headers = h.getreply()
print errcode

--
components: Library (Lib)
files: urllib_part.py
messages: 268317
nosy: gr zhang
priority: normal
severity: normal
status: open
title: urllib does not splitport while putrequest realhost to HTTP headers
type: behavior
versions: Python 2.7
Added file: http://bugs.python.org/file43356/urllib_part.py

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27292] Warn users that os.urandom() can return insecure values

2016-06-11 Thread Larry Hastings

Larry Hastings added the comment:

This is not a release blocker.

--
priority: release blocker -> normal

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue16484] pydoc generates invalid docs.python.org link for xml.etree.ElementTree and other modules

2016-06-11 Thread Kaushik Nadikuditi

Kaushik Nadikuditi added the comment:

- fixed broken test - test_mixed_case_module_names_are_lower_cased
- tested on Windows, Mac, Ubuntu
- thank you Martin Panter for suggestions.

--
components: +Tests -Documentation
type:  -> compile error
Added file: http://bugs.python.org/file43355/issue16484_test_python3.6.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17900] Recursive OrderedDict pickling

2016-06-11 Thread Raymond Hettinger

Raymond Hettinger added the comment:

At this point, we can drop it.  PyYAML will just have to deal with it.

--
assignee: rhettinger -> 

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27136] sock_connect fails for bluetooth (and probably others)

2016-06-11 Thread Martin Panter

Martin Panter added the comment:

Revision 3f49e89be8a9 seems to be the cause of an x86 Tiger buildbot failure:

http://buildbot.python.org/all/builders/x86%20Tiger%203.x/builds/10924/steps/test/logs/stdio
==
FAIL: test_create_connection_no_inet_pton 
(test.test_asyncio.test_base_events.BaseEventLoopWithSelectorTests)
--
Traceback (most recent call last):
  File "/Users/db3l/buildarea/3.x.bolen-tiger/build/Lib/unittest/mock.py", line 
1180, in patched
return func(*args, **keywargs)
  File 
"/Users/db3l/buildarea/3.x.bolen-tiger/build/Lib/test/test_asyncio/test_base_events.py",
 line 1210, in test_create_connection_no_inet_pton
self._test_create_connection_ip_addr(m_socket, False)
  File 
"/Users/db3l/buildarea/3.x.bolen-tiger/build/Lib/test/test_asyncio/test_base_events.py",
 line 1195, in _test_create_connection_ip_addr
self.assertRegex(host, r'::(0\.)*2')
AssertionError: Regex didn't match: '::(0\\.)*2' not found in '0.0.0.2'

--
nosy: +martin.panter
status: closed -> open

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue24136] document PEP 448: unpacking generalization

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset a7e04b4e51b2 by Martin Panter in branch '3.5':
Issue #24136: Document generalized unpacking, PEP 448
https://hg.python.org/cpython/rev/a7e04b4e51b2

New changeset 4cf3389cd8e6 by Martin Panter in branch 'default':
Issue #24136: Merge unpacking doc from 3.5
https://hg.python.org/cpython/rev/4cf3389cd8e6

New changeset 2c10f0e92256 by Martin Panter in branch 'default':
Issue #24136: Adjust f-strings doc for interable unpacking
https://hg.python.org/cpython/rev/2c10f0e92256

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27122] Hang with contextlib.ExitStack and subprocess.Popen (regression)

2016-06-11 Thread Gregory P. Smith

Changes by Gregory P. Smith :


--
assignee: gregory.p.smith -> ncoghlan

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27122] Hang with contextlib.ExitStack and subprocess.Popen (regression)

2016-06-11 Thread Gregory P. Smith

Gregory P. Smith added the comment:

Proposed fix based on STINNER and Nick's earlier comments and the simple 
reproducer turned into a test.

Nick - your most recent comment makes me wonder if this shouldn't be doing more.

this does make both hang_bug*.py examples do something reasonable.

I'm at a loss for what Misc/NEWS entry to write for this one as I don't know 
how to accurately describe the scope of the problem.  I'd also like to avoid 
conflating issue25782's problem with this one (that causes the hang, but once 
that is fixed isn't there still a problem here to be fixed)?

--
keywords: +patch
Added file: http://bugs.python.org/file43354/issue27122-gps01.diff

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25782] CPython hangs on error __context__ set to the error itself

2016-06-11 Thread Larry Hastings

Larry Hastings added the comment:

I'm not the right person to decide this.

As RM, all I can do is decide whether or not to hold up a release based on the 
bug.  The answer: no.  Since this isn't fixed yet in the 3.5 branch, 3.5.2 will 
go out without it being fixed.  Sorry folks.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27122] Hang with contextlib.ExitStack and subprocess.Popen (regression)

2016-06-11 Thread Gregory P. Smith

Changes by Gregory P. Smith :


--
dependencies: +CPython hangs on error __context__ set to the error itself

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25782] CPython hangs on error __context__ set to the error itself

2016-06-11 Thread Gregory P. Smith

Changes by Gregory P. Smith :


--
stage: commit review -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25782] CPython hangs on error __context__ set to the error itself

2016-06-11 Thread Gregory P. Smith

Gregory P. Smith added the comment:

Patch review: I see two competing solutions with differing behaviors. 

Yury's raises a RuntimeError in the loop situation.

Serhiy's simply reorders the exception context to put the referred to one at 
the front of the chain in the event of a loop.

The 3.5 Release manager or someone familiar with the contextlib ExitStack code 
where this is triggered should make the decision as to the best way to fix this.

(I came to this bug via the ExitStack + subprocess issue27122 which merely has 
a suggested workaround patch as a band aid that might help until this is fixed)

--
nosy: +gregory.p.smith

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue24086] Configparser interpolation is unexpected

2016-06-11 Thread Łukasz Langa

Łukasz Langa added the comment:

This is solved upstream in setuptools by disabling configparser interpolation.

--
resolution:  -> not a bug
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue14209] pkgutil.iter_zipimport_modules ignores the prefix parameter for packages

2016-06-11 Thread Łukasz Langa

Łukasz Langa added the comment:

Done. Fix is going to be present for 3.5.2 and 3.6. Thank you, James.

--
resolution:  -> fixed
status: open -> closed
versions: +Python 3.5, Python 3.6 -Python 2.7, Python 3.2, Python 3.3

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue14209] pkgutil.iter_zipimport_modules ignores the prefix parameter for packages

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 9649acf7d472 by Łukasz Langa in branch '3.5':
Issue #14209: pkgutil.iter_zipimport_modules ignores the prefix for packages
https://hg.python.org/cpython/rev/9649acf7d472

New changeset 389b7456a053 by Łukasz Langa in branch 'default':
Merge 3.5, issue #14209
https://hg.python.org/cpython/rev/389b7456a053

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15468] Edit docs to hide hashlib.md5()

2016-06-11 Thread Gregory P. Smith

Changes by Gregory P. Smith :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15468] Edit docs to hide hashlib.md5()

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 1cfd627bee05 by Gregory P. Smith in branch 'default':
Clarify that md5 is in the algorithms_guaranteed list despite what
https://hg.python.org/cpython/rev/1cfd627bee05

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15468] Edit docs to hide hashlib.md5()

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 13ea0a1d7dde by Gregory P. Smith in branch 'default':
issue15468 - use sha256 instead of md5 or sha1 in the examples.
https://hg.python.org/cpython/rev/13ea0a1d7dde

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27095] Simplify MAKE_FUNCTION

2016-06-11 Thread Demur Rumed

Demur Rumed added the comment:

mkfu4 implements #27140. It doesn't special case 1-tuples into `BUILD_MAP 1`

It may be easier to have `BUILD_CONST_KEY_MAP 1` peepholed if it's really 
preferable to strength reduce

I'm also noticing that it could've been suggested to go to the extreme with 
BUILD_CONST_KEY_MAP where instead of relying on peepholer to constant fold 
tuple, we implement constant folding const keys entirely there. Just a random 
thought, not a suggestion or anything else

--
Added file: http://bugs.python.org/file43353/mkfu4.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27291] two heap corruption issues when running modified pyc code.

2016-06-11 Thread Gregory P. Smith

Gregory P. Smith added the comment:

Executing code in any form from untrusted sources can do arbitrary things.

If someone can corrupt .pyc data before python executes it, they are just as 
likely to be able to corrupt other things leading to more direct exploits not 
even requiring the CPython interpreter.

--
nosy: +gregory.p.smith
resolution:  -> not a bug
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22558] Missing doc links to source code for Python-coded modules.

2016-06-11 Thread Terry J. Reedy

Terry J. Reedy added the comment:

Yes, new issue, make me nosy, assign to me if allowed, upload patch. Start with 
"This is a follow to #22558."

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27294] Better repr for Tkinter event objects

2016-06-11 Thread Terry J. Reedy

Terry J. Reedy added the comment:

If you want more, say so, and I will do them after resting.

--
Added file: http://bugs.python.org/file43352/tk-win-key-events.txt

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22558] Missing doc links to source code for Python-coded modules.

2016-06-11 Thread Yoni Lavi

Yoni Lavi added the comment:

Thank you Terry, Nathan and David for your work on this.
Sorry about the whitespace issue, I indeed forgot to run patchcheck when I 
prepared the 3rd patch.

Tery, would you like me to prepare a patch for the follow-on you suggested? If 
so, given that this one is now marked as fixed, we should open a new bug, right?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27194] Tarfile superfluous truncate calls slows extraction.

2016-06-11 Thread Łukasz Langa

Łukasz Langa added the comment:

Thanks for the patch, Jason. This is now merged and will be available in 3.5.2 
and 3.6.

--
resolution:  -> fixed
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27194] Tarfile superfluous truncate calls slows extraction.

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset b63474aa8a5f by Łukasz Langa in branch '3.5':
Issue #27194: superfluous truncate calls in tarfile.py slow down extraction
https://hg.python.org/cpython/rev/b63474aa8a5f

New changeset a4f918de25e5 by Łukasz Langa in branch 'default':
Merge 3.5, issue #27194
https://hg.python.org/cpython/rev/a4f918de25e5

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5124] IDLE - pasting text doesn't delete selection

2016-06-11 Thread Terry J. Reedy

Terry J. Reedy added the comment:

The two stable buildbots that failed on test_idle before do not now: AMD64 
SnowLeapard 1403, AMD64 Win 7 2258.

--
stage: needs patch -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25733] Code and IDLE should catch all compile errors.

2016-06-11 Thread Terry J. Reedy

Terry J. Reedy added the comment:

Code patch, still needs tests.  ppperry, thanks.  I may create a temporary big 
file when large memory tests are allowed.

--
keywords: +patch
stage: needs patch -> test needed
Added file: http://bugs.python.org/file43351/catch_all_syntax_errors.diff

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27221] multiprocessing documentation is outdated regarding method picklability

2016-06-11 Thread Jelle Zijlstra

Jelle Zijlstra added the comment:

Thanks for the Rietveld comments. I have attached a new patch.

--
Added file: http://bugs.python.org/file43350/issue27221-cr.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27263] Tkinter sets the HOME environment variable, breaking scripts

2016-06-11 Thread ppperry

Changes by ppperry :


--
nosy:  -ppperry

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27025] More human readable generated widget names

2016-06-11 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

"1" looks too similar to "l".

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27263] Tkinter sets the HOME environment variable, breaking scripts

2016-06-11 Thread Terry J. Reedy

Terry J. Reedy added the comment:

ppperry, when I changed this to a doc issue, I added IDLE back as a component 
because, as I said in my last message, I want to include the facts revealed 
here in the IDLE doc.

--
nosy: +ppperry

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27294] Better repr for Tkinter event objects

2016-06-11 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Next patch decodes the state attribute. Modifier names can be platform 
depended, please test on Windows. What modifiers correspond Shift, Ctrl, Alt, 
Win, CapsLock, etc?

--
Added file: http://bugs.python.org/file43349/tkinter_event_repr_key_state.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue24136] document PEP 448: unpacking generalization

2016-06-11 Thread Jelle Zijlstra

Jelle Zijlstra added the comment:

Thanks for writing a better patch. The patch looks good to me and it builds 
correctly.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27025] More human readable generated widget names

2016-06-11 Thread Terry J. Reedy

Terry J. Reedy added the comment:

I agree with back-compatibility, suppression of '1' suffix, and numbering, 
which makes suppressed '1' common.

I prefer '1' rather that '0' prefix.  Visually, '1' leaves more space between 
digit and word.  Semantically, each component represents 1 of something.  0 
this, 0 that, 0 etcetera, is a bad semantic clash.

--
stage: patch review -> commit review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25733] Code and IDLE should catch all compile errors.

2016-06-11 Thread ppperry

ppperry added the comment:

OverflowError is raised when one attempts to compile a string of 2**31 or more 
characters.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27263] Tkinter sets the HOME environment variable, breaking scripts

2016-06-11 Thread ppperry

Changes by ppperry :


--
components:  -IDLE

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27288] secrets should use getrandom() on Linux

2016-06-11 Thread Jelle Zijlstra

Jelle Zijlstra added the comment:

I'm interested in implementing this for 3.6, but I'm not sure exactly what the 
changes are that were decided upon. Is the following accurate?

1. Nothing changes in os (all the necessary changes were made in 3.5.2 already).
2. On Linux 3.17+ only, we add a new extension module called _secrets that 
provides a wrapper around the getrandom() system call and nothing else. I'll 
have to figure out whether to make the extension module just not exist all on 
non-Linux OSs (are there any existing extension modules that only exist on one 
OS?), or whether to make it empty on non-Linux. _secrets.getrandom() will look 
like def getrandom(buflen: int, flags: int) -> bytes.
3. We change secrets.SystemRandom so that on Linux 3.17+ only, it subclasses 
random.SystemRandom to use _secrets.getrandom() instead of os.urandom(). We 
will not pass in any flags to getrandom() (so we read from /dev/urandom and 
block until there is sufficient entropy). To make the subclassing easier, we 
may want to change random.SystemRandom to have a private method for calling 
os.urandom. (Currently, both of its methods call os.urandom directly.)
4. Similarly, we change secrets.token_bytes to use _secrets.getrandom(). Other 
functions in secrets.py won't need to change since they use 
secrets.SystemRandom or secrets.token_bytes.
5. _secrets and _secrets.getrandom will remain private and undocumented.

--
nosy: +Jelle Zijlstra

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27291] two heap corruption issues when running modified pyc code.

2016-06-11 Thread Park Alex

Park Alex added the comment:

oops, I cannot modify reply even I wrote it, 

want to fix tiny typo.

I don't want to bother you guys, I respect python-dev as always.

Thanks,
-- Alex

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27213] Rework CALL_FUNCTION* opcodes

2016-06-11 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

I was going to write a patch myself, but since I'm sure in your skills, I yield 
it to you.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27291] two heap corruption issues when running modified pyc code.

2016-06-11 Thread Park Alex

Park Alex added the comment:

I totally agreed with your opinion.
So I hesitated before reporting the issue (I thought)

It's kinda, we have different point of view.
As far as I can tell, 
python could be corrupted with .pyc like heap-use-after-free, buffer overrun 
and so on. 

Again, I agreed with your comment below:
"If you are able to execute untrusted .pyc, you can already execute arbitrary 
code, no?"

If don't want to bother you guys, I respect python-dev as always.

Thanks,
-- Alex

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27095] Simplify MAKE_FUNCTION

2016-06-11 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Now with adding BUILD_CONST_KEY_MAP I think MAKE_FUNCTION can be more compact.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27140] Opcode for creating dict with constant keys

2016-06-11 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Yes, I left it for symmetry and for easier modifying if we will add more 
restrictions on using BUILD_CONST_KEY_MAP. Thank you for your reviews Demur and 
Benjamin.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27140] Opcode for creating dict with constant keys

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 27b0dbaf0ea8 by Serhiy Storchaka in branch 'default':
Issue #27140: Added BUILD_CONST_KEY_MAP opcode.
https://hg.python.org/cpython/rev/27b0dbaf0ea8

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27291] two heap corruption issues when running modified pyc code.

2016-06-11 Thread ppperry

Changes by ppperry :


--
title: two heap corruption issue -> two heap corruption issues when running 
modified pyc code.

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27291] two heap corruption issue

2016-06-11 Thread STINNER Victor

STINNER Victor added the comment:

Hi, corrupted .pyc files are known to be abel to crash Python. What is the
point of your bug report? If you are able to execute untrusted .pyc, you
can already execute arbitrary code, no?

IMHO we should document the limitation of the security of CPython.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue10839] email module should not allow some header field repetitions

2016-06-11 Thread Raymond Hettinger

Raymond Hettinger added the comment:

I think we should consider this as an API design bug and backport the fix.

This seems to be the exact cause of this week's email address leak at 
LetsEncrypt:  

* 
https://community.letsencrypt.org/t/email-address-disclosures-preliminary-report-june-11-2016/16867

* https://news.ycombinator.com/item?id=11881704

* https://twitter.com/TvdW/status/741482093054550016

--
nosy: +rhettinger
priority: normal -> high
status: closed -> open
versions: +Python 2.7 -Python 3.3

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27288] secrets should use getrandom() on Linux

2016-06-11 Thread Brett Cannon

Brett Cannon added the comment:

It should be mentioned that Guido really doesn't like the idea of 
os.getrandom() as it exposes stuff where we would rather simply tell people to 
use the secrets module.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27288] secrets should use getrandom() on Linux

2016-06-11 Thread Tim Peters

Tim Peters added the comment:

I think it's clear Guido would say "#1".  The thrust of all his comments to 
date is that it was a mistake to change the semantics of os.urandom() on Linux 
(and one other platform? don't really care), and that in 3.6+ only `secrets` 
should _try_ to supply possibly-blocking behavior on Linux.

Indeed, even in 3.6+ he doesn't want to expose the new-ish getrandom() 
directly.  Today he said:

"""
So what should the secrets module use? Let's make that part an extension module.
"""

So he feels strongly enough about this as to recommend a teensy private C 
extension module for secrets.py alone to get at the platform getrandom() (if 
any - of course it needs to fall back to os.urandom() on other platforms).

"""
The main thing that I want to avoid is that people start cargo-culting whatever 
the secrets module uses rather than just using the secrets module. Having it 
redundantly available as os.getrandom() is just begging for people to show off 
how much they know about writing secure code. 
"""

Whenever he starts taking that tone, his mind is made up for good ;-)

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27298] redundant iteration over digits in _PyLong_AsUnsignedLongMask

2016-06-11 Thread Oren Milman

Changes by Oren Milman :


Added file: http://bugs.python.org/file43347/patchedCPythonTestOutput.txt

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27298] redundant iteration over digits in _PyLong_AsUnsignedLongMask

2016-06-11 Thread Serhiy Storchaka

Changes by Serhiy Storchaka :


--
nosy: +mark.dickinson, serhiy.storchaka

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27298] redundant iteration over digits in _PyLong_AsUnsignedLongMask

2016-06-11 Thread Oren Milman

New submission from Oren Milman:

 current state 
1. In Objects/longobject.c in _PyLong_AsUnsignedLongMask, in case v is a 
multiple-digit int, _PyLong_AsUnsignedLongMask iterates over all of its digits 
(going from the most to the least significant digit) and does (for each digit) 
'x = (x << PyLong_SHIFT) | v->ob_digit[i];'.
However, iterating over digits other than the 'ceil(sizeof(x) * 8.0 / 
PyLong_SHIFT)' least significant digits is redundant, because their bits would 
be shifted out of x anyway.

With regard to relevant changes made in the past, the iteration over all of the 
digits of a multiple-digit v remained quite the same since 
_PyLong_AsUnsignedLongMask was added, in revision 28652.

2. In Modules/_testcapimodule.c, the function comment of test_k_code, and an 
error string inside that function, contain mistakes.

With regard to relevant changes made in the past, these mistakes were there 
since test_k_code was added, in revision 28652.


 proposed changes 
1. In _PyLong_AsUnsignedLongMask, in case v is a multiple-digit int, iterate 
only over the 'Py_MIN(i, sizeof(x) * 8 / PyLong_SHIFT + 1)' least significant 
digits.

Obviously, 'sizeof(x) * 8 / PyLong_SHIFT + 1' might be off by one in case 
CPython is compiled with a PyLong_SHIFT other than 15 or 30. I suspect it's an 
overkill, but I added an assert, just in case.

2. Fix the function comment of test_k_code, and an error string inside that 
function.


 alternative changes 
1. I have also considered iterating only over the 'Py_MIN(i, 
(Py_ssize_t)ceil(sizeof(x) * 8.0 / PyLong_SHIFT))' least significant digits. 
Even though this number of digits is guaranteed to be accurate, it cannot be 
calculated at compile time, so it would probably cause the optimization to 
overall introduce a performance penalty.


 diff 
The proposed patches diff file is attached.


 tests 
I built the patched CPython for x86, and played with it a little. Everything 
seemed to work as usual. 

In addition, I ran 'python_d.exe -m test -j3' (on my 64-bit Windows 10) with 
and without the patches, and got quite the same output.
The outputs of both runs are attached.

--
components: Interpreter Core
files: proposedPatches.diff
keywords: patch
messages: 268274
nosy: Oren Milman
priority: normal
severity: normal
status: open
title: redundant iteration over digits in _PyLong_AsUnsignedLongMask
type: performance
Added file: http://bugs.python.org/file43346/proposedPatches.diff

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27294] Better repr for Tkinter event objects

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 61a92a102b2d by Serhiy Storchaka in branch 'default':
Issue #27294: Improved repr for Tkinter event objects.
https://hg.python.org/cpython/rev/61a92a102b2d

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27298] redundant iteration over digits in _PyLong_AsUnsignedLongMask

2016-06-11 Thread Oren Milman

Changes by Oren Milman :


Added file: http://bugs.python.org/file43348/CPythonTestOutput.txt

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27291] two heap corruption issue

2016-06-11 Thread Park Alex

Park Alex added the comment:

all of .pyc files had been altered by fuzzer.

original py code is following:

$ cat helloworld.py
def hello(s=0x4142434445464748):
print s
if type(s) == str:
print s.encode('hex')
print repr(s)
else:
s = str(s)
print len(s) << 8, len(s) ^ 8, len(s) | 8, len(s) & 8, len(s) == 8, len(s) 
<= 8, len(s) >= 8
x = __import__("sys")

#for k, v in x.__dict__.items():
#if hasattr(v, '__subclasses__') == True:
#cmd = "Subclasses:", 
(v.__class__.__base__.__subclasses__()[11].__init__.__str__())

return 0x5152535455565758 == max(s, abs(len(s)) % 0x1234)

H = 'A'*128
hello(H.encode('base64'))
hello()

plus, python compiled with ASAN generated .pyc code.
After that, fuzzer found a few crashes.

Here are some diff information between original pyc and fuzzed pyc.
file: poc_heap-buffer-overflow.pyc
cmp -bl helloworld.pyc poc_heap-buffer-overflow.pyc | gawk '{printf "%08X %02X 
%02X\n", $1, strtonum(0$2), strtonum(0$4)}'
0010 00 03
0012 03 00
0026 01 00
0027 00 F7
006A 06 EE
006B 00 FF
006C 00 FF
006D 00 FF
0129 01 FE
012A 00 FF
012B 64 00
012C 04 00
01F0 6C DB
01FD 6C 49

file: poc_heap-use-after-free.pyc 
cmp -bl helloworld.pyc poc_heap-use-after-free.pyc | gawk '{printf "%08X %02X 
%02X\n", $1, strtonum(0$2), strtonum(0$4)}'
006A 06 D0
006B 00 FF
006C 00 FF
006D 00 FF
0129 01 EB
012A 00 FF
012B 64 00
012C 04 00
01F0 6C DB
01FD 6C 49
026F 6C 7D

Thanks,
-- Alex

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27140] Opcode for creating dict with constant keys

2016-06-11 Thread Benjamin Peterson

Benjamin Peterson added the comment:

Okay, I think it's fine then. However, you have a for loop in 
compiler_subkwargs which only executes once.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27294] Better repr for Tkinter event objects

2016-06-11 Thread Terry J. Reedy

Terry J. Reedy added the comment:

Right.  This is why I suggested leaving anything we are not sure of to a later 
patch, after gaining more experience (and thought).

However, 'state' behaved strangely in my experiments.  In a sequence of about 
900 events, it started as 8 (Left Alt according to Shipman, but I never touched 
the key) and changed to 0 here







back to 8 here





and briefly back to 0 here






--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22253] ConfigParser does not handle files without sections

2016-06-11 Thread Pedro Lacerda

Pedro Lacerda added the comment:

I also never found a mixture of sectionless options followed by sectioned 
options. So an unnamed section that is also the DEFAULTSECTION will probably 
work.

In this patch when `default_section=None` is passed to `RawConfigParser` it 
will parse top level options into the default section and skip writing its 
title.

As drawback, default options is not showed in `options()` or `has_section()` 
reducing it usefulness. It works with `items()` and `keys()` however.

> Using DEFAULTSECT for this purpose is equally wrong since it would
> silently inject default values to every section

I disagree with that because I really *never* found in wild a file where it 
will happen.

> All in all, it comes down to the question whether the programmer
> expects section-less configuration. If not, the '' section will not be 
> helpful anyway. If yes, then it's desirable to be able to specify a
> section name for global options at *read time*.

Pass a name at read time will improve the API as `sections()` and 
`has_section()` will work as usual and not like a DEFAULTSECTION.

Please look my patch and tell if it's acceptable, if you prefer that a section 
name must be given at read and write time we can manage it.

It's my first post in this tracker and I'm very glad that I got it working even 
if not merged!

--
keywords: +patch
nosy: +Pedro Lacerda
versions:  -Python 3.5
Added file: http://bugs.python.org/file43345/nosection.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27291] two heap corruption issue

2016-06-11 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

poc.zip contains only precompiled files. Could you please provide source files?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27291] two heap corruption issue

2016-06-11 Thread Raymond Hettinger

Changes by Raymond Hettinger :


--
nosy: +haypo, rhettinger, serhiy.storchaka, stutzbach

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27295] heaps library does not have support for max heap

2016-06-11 Thread Raymond Hettinger

Raymond Hettinger added the comment:

Sorry James, we don't grow the APIs without sufficient demonstrated need; 
otherwise, we end-up with API sprawl.  People with actual use cases haven't 
requested behavior (and the occasional one-off gets by negating the numeric 
argument).  That is why the maxheap functions were intentionally made private.

FWIW, this module is very old and the core functions have long proven 
themselves sufficient to meet their use cases (like being used in an event loop 
to efficiently select the next scheduled event).

--
resolution:  -> rejected
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26556] Update expat to 2.2.1

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset d8a0a016d8d4 by Benjamin Peterson in branch '2.7':
upgrade expt to 2.1.1 (closes #26556)
https://hg.python.org/cpython/rev/d8a0a016d8d4

New changeset bb3ce78572f5 by Benjamin Peterson in branch '3.4':
upgrade expt to 2.1.1 (closes #26556)
https://hg.python.org/cpython/rev/bb3ce78572f5

New changeset f3c36afdedae by Benjamin Peterson in branch '3.5':
merge 3.4 (#26556)
https://hg.python.org/cpython/rev/f3c36afdedae

New changeset 77353f0106cc by Benjamin Peterson in branch 'default':
merge 3.5 (#26556)
https://hg.python.org/cpython/rev/77353f0106cc

--
nosy: +python-dev
resolution:  -> fixed
stage: needs patch -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27294] Better repr for Tkinter event objects

2016-06-11 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

The key state can be interesting for mouse events too. Ctrl-Click, Shift-Move. 
Maybe it is worth to omit the output of state=0.

Agreed, the 4 mouse positions are pretty noisy. Maybe omit root_x and root_y? 
But mouse position can be relevant for such key events as pressing Ctrl. For 
example if the mouse pointer points on module name in import statement, 
pressing Ctrl can convert the name into a hyperling to a file of the module.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5124] IDLE - pasting text doesn't delete selection

2016-06-11 Thread Terry J. Reedy

Terry J. Reedy added the comment:

Oh right, requires('gui') does not work at module level in 2.7.
This should fix.  Will try to check next round of bot builds.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5124] IDLE - pasting text doesn't delete selection

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 274308a3b8b6 by Terry Jan Reedy in branch '2.7':
Issue #5124: For 2.7, move requires('gui') from module level to setUpClass.
https://hg.python.org/cpython/rev/274308a3b8b6

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27294] Better repr for Tkinter event objects

2016-06-11 Thread Terry J. Reedy

Terry J. Reedy added the comment:

Summary: Though I would like to see some refinements, this looks really useful 
as is and I would like it applied soon even if refinements have to wait for a 
second patch.

Moving the window did not generate a printed event.

I like the compact way of handling customization.  Two more possible 
exclusions: 1. The key state seems like it should only be interesting for key 
events.  2. The 4 mouse positions are pretty noisy and seem not relevant to key 
events, and to many other non-mouse events.

I wish "VirtualEvent event"s had the triggering sequence available, but you 
cannot change that.
.

--
stage: patch review -> commit review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27277] Fatal Python error: Segmentation fault in test_exceptions

2016-06-11 Thread Rohit Mediratta

Rohit Mediratta added the comment:

It's set to 1000, I didnt change during install, so it's likely set to the 
default value.

>>> import sys
>>> sys.getrecursionlimit()
1000


I also have a lot of memory free (87G) to run scripts (should be able to handle 
without running into issues)

[/loc/rom/pyd/cpython] $ free -m
 total   used   free sharedbuffers cached
Mem: 96870   9849  87021  0716   7512
-/+ buffers/cache:   1620  95250
Swap:0  0  0

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26565] [ctypes] Add value attribute to non basic pointers.

2016-06-11 Thread Memeplex

Memeplex added the comment:

Martin, there were two reasons:

1. Conciseness: addressof(p.contents) vs. p.value.
2. Uniformity: I expect the value of a pointer to be the address it points to.

Then Eryk pointed out that p.value has already another meaning for simple 
pointer types, so (2) can't be fully achieved and for (1) it will be necessary 
to pick another attribute name. But we could still get something shorter and 
uniform inside the subset of pointer types.

p.as_void makes me expect a c_void_p instance. In that case the address will be 
p.as_void.value (or p.as_void().value?), which is a bit indirect. I think 
p.toaddress conveys the exact meaning[1] and consistently follows the naming 
style of addressof, besides being slightly shorter.


[1] Well, toaddress might mean "get the pointed-to address" or "convert from 
pointer to address", but in any case the meaning is right.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20508] IndexError from ipaddress._BaseNetwork.__getitem__ has no message

2016-06-11 Thread Gareth Rees

Gareth Rees added the comment:

Thank you for applying this patch.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5124] IDLE - pasting text doesn't delete selection

2016-06-11 Thread Ned Deily

Ned Deily added the comment:

Terry, the 2.7 version of the test changes is causing buildbot and test_idle 
failures when the "gui" condition is not met. See, for example, 
http://buildbot.python.org/all/builders/AMD64%20Snow%20Leop%202.7/builds/1400.

--
stage: resolved -> needs patch
status: closed -> open

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27297] Add support for /dev/random to "secrets"

2016-06-11 Thread Donald Stufft

Donald Stufft added the comment:

> It's just that the manpage for urandom (and in fact the comments in the 
> source code for /dev/random and /dev/urandom) both recommend using 
> /dev/random for these long-lived cryptographic keys. 

It's a hedge because of the bad behavior of /dev/urandom on early boot in a 
situation where it's highly unlikely that the randomly blocking behavior of 
/dev/random is going to matter.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27294] Better repr for Tkinter event objects

2016-06-11 Thread Terry J. Reedy

Terry J. Reedy added the comment:

Testing now.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27025] More human readable generated widget names

2016-06-11 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Patch updated.

1. The prefix "0" is used for generated names. This keeps the old rule 
(generated names start from a digit and are not valid Python identifier) and 
looks less striking than "_".

2. Lowercased Python class name is used as a base name for generated name.

3. Numbering is separate for every type and every parent widget.

4. Numerical suffix is not used for the first (often the single) child of every 
type.

--
Added file: http://bugs.python.org/file43344/tkinter_names2.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20508] IndexError from ipaddress._BaseNetwork.__getitem__ has no message

2016-06-11 Thread Berker Peksag

Changes by Berker Peksag :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed
versions:  -Python 3.5

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20508] IndexError from ipaddress._BaseNetwork.__getitem__ has no message

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset bc758c62bc4f by Berker Peksag in branch 'default':
Issue #20508: Improve exception message of IPv{4,6}Network.__getitem__
https://hg.python.org/cpython/rev/bc758c62bc4f

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22558] Missing doc links to source code for Python-coded modules.

2016-06-11 Thread Terry J. Reedy

Terry J. Reedy added the comment:

I committed the excellent patch.  It should appear in the upcoming 3.5 and 3.6 
releases, and within a day online.  Thanks to both package author and also to 
reviewers.  I would like to see more patches like this.

I reverted the deletion of version added in mock examples.  It is a separate 
page, so the reminder is not inappropriate.

Minor nit: Yoni, you 'forgot' to run "python tools/scripts/patchcheck.py" on a 
patched  repository.  Not too surprisingly, the editing left trailing 
whitespace that needed to be removed.  See the devguide for more.

A possible follow-on.  Some of the packages that document contained modules do 
so on the main page rather than in separate pages.  If the source link is to 
the package __init__, rather than to the package directory, then it would be 
appropriate to add links to the module sections.  The particular example I am 
thinking of is importlib, where we linked to .__init__.  There may be another.  
Multiprocessing is not, because we linked to the directory.

--
resolution:  -> fixed
stage: commit review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27297] Add support for /dev/random to "secrets"

2016-06-11 Thread Larry Hastings

Larry Hastings added the comment:

I understand.  It's just that the manpage for urandom (and in fact the comments 
in the source code for /dev/random and /dev/urandom) both recommend using 
/dev/random for these long-lived cryptographic keys.  Under normal 
circumstances I'd simply assume that was correct and I'd follow their advice.

But you're claiming that there are extenuating political circumstances 
surrounding these statements and they should be ignored.  I trust your 
judgement and I'd be happy to see the secrets module do as you suggest.  But 
you must admit, this is a surprising state of affairs.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue21386] ipaddress.IPv4Address.is_global not implemented

2016-06-11 Thread Berker Peksag

Berker Peksag added the comment:

Thanks Roger!

--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed
type: enhancement -> behavior

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue21386] ipaddress.IPv4Address.is_global not implemented

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset d65191861599 by Berker Peksag in branch '3.5':
Issue #21386: Implement missing IPv4Address.is_global property
https://hg.python.org/cpython/rev/d65191861599

New changeset 1519ca772e54 by Berker Peksag in branch 'default':
Issue #21386: Merge from 3.5
https://hg.python.org/cpython/rev/1519ca772e54

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27297] Add support for /dev/random to "secrets"

2016-06-11 Thread Donald Stufft

Donald Stufft added the comment:

I will add, /dev/random is not going to *hurt* when generating long lived 
cryptographic keys (e.g. like your SSH keys) because that's something you're 
generally going to do once every couple of years and if it takes a few seconds 
longer because of snake oil then who cares. It's not going matter once 
/dev/urandom is initialized (of course, it does matter if /dev/urandom hasn't 
been initialized yet). So it does guard against early on in the boot process in 
a way that /dev/urandom doesn't (but then, so does getrandom(0)).

It's obviously not acceptable for your webserver to randomly block for seconds 
at a time trying to generate signing keys for cookies just because of snakeoil 
though.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue22558] Missing doc links to source code for Python-coded modules.

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 222c1d461aa8 by Terry Jan Reedy in branch '3.5':
Issue #22558: Add remaining doc links to source code for Python-coded modules.
https://hg.python.org/cpython/rev/222c1d461aa8

New changeset 2a01d7a488e9 by Terry Jan Reedy in branch 'default':
Merge Issue #22558.
https://hg.python.org/cpython/rev/2a01d7a488e9

--
nosy: +python-dev

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



  1   2   >