[issue21085] Cygwin does not provide siginfo_t.si_band

2016-09-30 Thread Zachary Ware

Changes by Zachary Ware :


--
title: compile error Python3.3 on Cygwin -> Cygwin does not provide 
siginfo_t.si_band

___
Python tracker 

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



[issue21085] compile error Python3.3 on Cygwin

2016-09-30 Thread Zachary Ware

Zachary Ware added the comment:

Thanks for the patch, masamoto, and thanks for the review and rebase, erik.bray!

I only applied this to 3.7.  It's much more open to experimentation currently, 
and we have a way to go before Python can even be built on Cygwin.  Once we 
reach a more stable point (say, the full test suite can be run, even if not 
everything passes), we can evaluate whether backporting all the changes it took 
to get there is worthwhile.

--
assignee: erik.bray -> zach.ware
nosy: +zach.ware
resolution:  -> fixed
stage: commit review -> resolved
status: open -> closed
versions: +Python 3.7 -Python 3.5, Python 3.6

___
Python tracker 

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



[issue21085] compile error Python3.3 on Cygwin

2016-09-30 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 6874928eae4b by Zachary Ware in branch 'default':
Issue #21085: add configure check for siginfo_t.si_band
https://hg.python.org/cpython/rev/6874928eae4b

--
nosy: +python-dev

___
Python tracker 

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



[issue27897] Avoid possible crash in pysqlite_connection_create_collation

2016-09-30 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Thanks Martin!

--
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



[issue27897] Avoid possible crash in pysqlite_connection_create_collation

2016-09-30 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 38e954a2a37e by Serhiy Storchaka in branch '2.7':
Issue #27897: Fixed possible crash in sqlite3.Connection.create_collation()
https://hg.python.org/cpython/rev/38e954a2a37e

--

___
Python tracker 

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



[issue28275] LZMADecompressor.decompress Use After Free

2016-09-30 Thread Martin Panter

Changes by Martin Panter :


--
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



[issue28276] test_loading.py - false positive result for "def test_find" when find_library() is not functional or the (shared) library does not exist

2016-09-30 Thread Martin Panter

Martin Panter added the comment:

Other tests in this file skip the test if libc_name is None. So I think it 
would make more sense to skip the test rather than fail in test_find(). I.e.

if not found:
self.skipTest("Could not find c and m libraries")

If you are confident that find_library() will always find libc on AIX, perhaps 
you can suggest an extra test (or add to an existing test), to first check for 
the AIX platform, and only then fail if find_library() returned None.

--

___
Python tracker 

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



[issue28275] LZMADecompressor.decompress Use After Free

2016-09-30 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 36d37ff6c236 by Martin Panter in branch '3.5':
Issue #28275: Clean up to avoid use-after-free after bzip decompress failure
https://hg.python.org/cpython/rev/36d37ff6c236

New changeset dca18f0ec280 by Martin Panter in branch '3.6':
Issue #28275: Merge bz2 fix from 3.5 into 3.6
https://hg.python.org/cpython/rev/dca18f0ec280

New changeset 35b5f4cc08f4 by Martin Panter in branch 'default':
Issue #28275: Merge bz2 fix from 3.6
https://hg.python.org/cpython/rev/35b5f4cc08f4

--

___
Python tracker 

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



[issue27897] Avoid possible crash in pysqlite_connection_create_collation

2016-09-30 Thread Martin Panter

Martin Panter added the comment:

The test in 2.7 (1aae9b7ff321) seems to cause a Windows 8.1 buildbot to hang in 
test_sqlite. I deduced this because there is no mention of "test_sqlite" in the 
test log output, compared to a previous successful test log.

http://buildbot.python.org/all/builders/AMD64%20Windows8.1%20Non-Debug%202.7/builds/474

--
nosy: +martin.panter

___
Python tracker 

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



[issue28288] Expose environment variable for Py_Py3kWarningFlag

2016-09-30 Thread Berker Peksag

Berker Peksag added the comment:

Thanks for the patch. I left some comments on Rietveld.

--
stage: test needed -> patch review

___
Python tracker 

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



[issue28225] bz2 does not support pathlib

2016-09-30 Thread Berker Peksag

Changes by Berker Peksag :


--
nosy: +berker.peksag

___
Python tracker 

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



[issue27511] Add PathLike objects support to BZ2File

2016-09-30 Thread Berker Peksag

Changes by Berker Peksag :


--
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
superseder:  -> bz2 does not support pathlib

___
Python tracker 

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



[issue28228] imghdr does not support pathlib

2016-09-30 Thread Berker Peksag

Berker Peksag added the comment:

Thanks for the review, Brett!

The next target is gzip module. Thanks for the all patches Ethan :)

--
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



[issue28227] gzip does not support pathlib

2016-09-30 Thread Berker Peksag

Changes by Berker Peksag :


--
nosy: +berker.peksag

___
Python tracker 

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



[issue28228] imghdr does not support pathlib

2016-09-30 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 929e3adefe7a by Berker Peksag in branch '3.6':
Issue #28228: imghdr now supports pathlib
https://hg.python.org/cpython/rev/929e3adefe7a

New changeset 013b3b5d3b6c by Berker Peksag in branch 'default':
Issue #28228: Merge from 3.6
https://hg.python.org/cpython/rev/013b3b5d3b6c

--
nosy: +python-dev

___
Python tracker 

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



[issue28259] Ctypes bug windows

2016-09-30 Thread Steve Dower

Steve Dower added the comment:

You keep removing the Windows component - is this not actually a bug on Windows?

--

___
Python tracker 

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



[issue28283] test_sock_connect_sock_write_race() of test.test_asyncio.test_selector_events fails randomly on FreeBSD

2016-09-30 Thread Roundup Robot

Roundup Robot added the comment:

New changeset f7688db81753 by Berker Peksag in branch '3.5':
Issue #28283: Remove flaky test test_sock_connect_sock_write_race again
https://hg.python.org/cpython/rev/f7688db81753

New changeset 0fe04467c4b5 by Berker Peksag in branch '3.6':
Issue #28283: Merge from 3.5
https://hg.python.org/cpython/rev/0fe04467c4b5

New changeset 4ba2f6bce7f4 by Berker Peksag in branch 'default':
Issue #28283: Merge from 3.6
https://hg.python.org/cpython/rev/4ba2f6bce7f4

--

___
Python tracker 

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



[issue28226] compileall does not support pathlib

2016-09-30 Thread Berker Peksag

Changes by Berker Peksag :


--
status: open -> closed

___
Python tracker 

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



[issue10415] readline.insert_text documentation incomplete

2016-09-30 Thread Berker Peksag

Berker Peksag added the comment:

I agree with Martin. Closing this as 'out of date' for now, but we can reopen 
if you could provide more information. Thanks!

--
resolution:  -> out of date
stage: needs patch -> resolved
status: pending -> closed
type:  -> behavior

___
Python tracker 

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



[issue28226] compileall does not support pathlib

2016-09-30 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 13cd90bdcfbe by Berker Peksag in branch '3.6':
Issue #28226: Fix test_compileall on Windows
https://hg.python.org/cpython/rev/13cd90bdcfbe

New changeset ff80d77200ed by Berker Peksag in branch 'default':
Issue #28226: Merge from 3.6
https://hg.python.org/cpython/rev/ff80d77200ed

--

___
Python tracker 

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



[issue18235] _sysconfigdata.py wrong on AIX installations

2016-09-30 Thread David Edelsohn

David Edelsohn added the comment:

Michael Felt,

The patch was from Michael Haubenwallner.  I was addressing Michael 
Haubenwallner.

--

___
Python tracker 

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



[issue28294] HTTPServer server.py assumes sys.stderr != None

2016-09-30 Thread Guido van Rossum

Guido van Rossum added the comment:

I wonder if we shouldn't close this as "won't fix" and tell the OP to override 
the log_message() method. It's kind of curious to complain about *this* 
dependency on sys.stderr existing and working, since there are probably 1000s 
of other places in the stdlib that also depend on that.

--
nosy: +gvanrossum

___
Python tracker 

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



[issue28321] Plistlib: Half of the double width characters are missing when writing binary plist

2016-09-30 Thread kuglee

New submission from kuglee:

I read an emoji character from a plist file. The emoji printed correctly to 
stdout. However when I dump the file to a binary plist only the half of the 
emoji was present.

--

___
Python tracker 

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



[issue28321] Plistlib: Half of the double width characters are missing when writing binary plist

2016-09-30 Thread kuglee

Changes by kuglee :


--
components: Library (Lib)
files: input.plist
nosy: kuglee
priority: normal
severity: normal
status: open
title: Plistlib: Half of the double width characters are missing when writing 
binary plist
type: behavior
versions: Python 3.5
Added file: http://bugs.python.org/file44897/input.plist

___
Python tracker 

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



[issue28321] Plistlib: Half of the double width characters are missing when writing binary plist

2016-09-30 Thread kuglee

Changes by kuglee :


Added file: http://bugs.python.org/file44898/output.plist

___
Python tracker 

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



[issue18235] _sysconfigdata.py wrong on AIX installations

2016-09-30 Thread Michael Felt

Michael Felt added the comment:

I am not suggesting anything. I am only trying to report what I experience.

The first observation was that I could not build python when src != build 
directory. I believe that was the original complaint as well.

The second observation came when I tried to use pip install, and also make of 
the mercurial "addition". That module consistently failed until I editted, 
manually, the _sysconf*.py file to make LDwhatever the same as LDCXXwhatever.

With study I  could figure out what they stand for - I would guess they are 
related, if not derived from, to some "autotool" conventions.

To be honest, I do not understand what is meant by "flipping", so I am neither 
for nor against.

For me to test a patch - which I am very willing to do - I would be grateful 
for the mercurial command(s) to test it normally (now that I finally have it 
working - I figured out how to make the SSL part work this evening).

In short, please do not shoot me, the messenger :)

--

___
Python tracker 

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



[issue28319] typo in lzma module documentation

2016-09-30 Thread Berker Peksag

Berker Peksag added the comment:

Thanks for the report!

--
nosy: +berker.peksag
resolution:  -> fixed
stage:  -> resolved
status: open -> closed
versions: +Python 3.6

___
Python tracker 

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



[issue28319] typo in lzma module documentation

2016-09-30 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 258436eecb51 by Berker Peksag in branch '3.5':
Issue #28319: Fix typo in lzma.rst
https://hg.python.org/cpython/rev/258436eecb51

New changeset a1e7c9d249ed by Berker Peksag in branch '3.6':
Issue #28319: Merge from 3.5
https://hg.python.org/cpython/rev/a1e7c9d249ed

New changeset 40bcf4a8b57d by Berker Peksag in branch 'default':
Issue #28319: Merge from 3.6
https://hg.python.org/cpython/rev/40bcf4a8b57d

--
nosy: +python-dev

___
Python tracker 

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



[issue28319] typo in lzma module documentation

2016-09-30 Thread Berker Peksag

Changes by Berker Peksag :


--
type:  -> behavior

___
Python tracker 

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



[issue28226] compileall does not support pathlib

2016-09-30 Thread Berker Peksag

Berker Peksag added the comment:

Windows buildbots didn't like a6f0cc1820f4 :) Fix is incoming.

==
FAIL: test_compile_dir_pathlike (test.test_compileall.CompileallTests)
--
Traceback (most recent call last):
  File "D:\buildarea\3.6.ware-win81-release\build\lib\test\test_compileall.py", 
line 161, in test_compile_dir_pathlike
self.assertIn("Listing '{}'...".format(self.directory), stdout.getvalue())
AssertionError: "Listing 'D:\\temp\\tmpuziqv_kw'..." not found in "Listing 
'D:temptmpuziqv_kw'...\nListing 
'D:temptmpuziqv_kw_subdir'...\nCompiling 
'D:temptmpuziqv_kw_subdir_test3.py'...\nCompiling 
'D:temptmpuziqv_kw_test.py'...\nCompiling 
'D:temptmpuziqv_kw_test2.py'...\n"

==
FAIL: test_compile_file_pathlike (test.test_compileall.CompileallTests)
--
Traceback (most recent call last):
  File "D:\buildarea\3.6.ware-win81-release\build\lib\test\test_compileall.py", 
line 111, in test_compile_file_pathlike
"Compiling '{}'...\n".format(self.source_path))
AssertionError: "Compiling 'D:temptmpqvjkm0fm_test.py'...\n" != 
"Compiling 'D:\\temp\\tmpqvjkm0fm\\_test.py'...\n"
- Compiling 'D:\\temp\\tmpqvjkm0fm\\_test.py'...
?  - --
+ Compiling 'D:\temp\tmpqvjkm0fm\_test.py'...

--
status: closed -> open

___
Python tracker 

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



[issue28228] imghdr does not support pathlib

2016-09-30 Thread Brett Cannon

Brett Cannon added the comment:

Berker, your patch LGTM

--
assignee:  -> berker.peksag

___
Python tracker 

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



[issue28226] compileall does not support pathlib

2016-09-30 Thread Ethan Furman

Ethan Furman added the comment:

Thanks, Berker Peksag!

--
assignee: ethan.furman -> 

___
Python tracker 

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



[issue28226] compileall does not support pathlib

2016-09-30 Thread Berker Peksag

Berker Peksag added the comment:

I found a similar problem in compile_dir() and fixed it in the commit.

--
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



[issue28226] compileall does not support pathlib

2016-09-30 Thread Roundup Robot

Roundup Robot added the comment:

New changeset a6f0cc1820f4 by Berker Peksag in branch '3.6':
Issue #28226: compileall now supports pathlib
https://hg.python.org/cpython/rev/a6f0cc1820f4

New changeset fcce24bc9416 by Berker Peksag in branch 'default':
Issue #28226: Merge from 3.6
https://hg.python.org/cpython/rev/fcce24bc9416

--
nosy: +python-dev

___
Python tracker 

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



[issue28320] Hostname validation is False by default in imaplib

2016-09-30 Thread Maciej Szulik

New submission from Maciej Szulik:

According to David [1] hostname validation should be True by default for the 
imaplib, my tests clearly show something different. Additionally he states you 
Christian were doing so, that's why I'm opening this not to forget about the 
problem and discuss eventually what should happen.


[1] 
http://bugs.python.org/review/25591/diff/16398/Lib/test/test_imaplib.py#newcode451

--
assignee: christian.heimes
components: email
messages: 22
nosy: barry, christian.heimes, maciej.szulik, r.david.murray
priority: normal
severity: normal
stage: needs patch
status: open
title: Hostname validation is False by default in imaplib
type: security
versions: Python 3.7

___
Python tracker 

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



[issue25591] refactor imaplib tests

2016-09-30 Thread Maciej Szulik

Maciej Szulik added the comment:

David I apologize for 2 emails from Reitveld, for some reason it didn't show me 
all in one view :/ (I need to master Reitveld better). I've just updated patch 
according to your comments.

--
Added file: http://bugs.python.org/file44896/new_imap_tests_v5.diff

___
Python tracker 

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



[issue28315] incorrect "in ?" output in 'divide' example at "Defining Clean-up Actions" in tutorial

2016-09-30 Thread Terry J. Reedy

Terry J. Reedy added the comment:

Pushed to all 4 versions in ce57a74b5223, 1bead1f0260f, c729a62d4ec5, and 
89cc2a6b64aa, but I gave issue # as 28815 instead of 28315.  Thanks for the 
clean patch for 3.5.  It mostly worked for 2.7, which also had an additional 
item not in 3.5.

The only other file in /Doc with 'in ?' is Doc/includes/test.py, which is 
mostly a doctest docstring.  The test obviously have not been run for years and 
the directory puzzles me, so I left it alone.

--
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



[issue28315] incorrect "in ?" output in 'divide' example at "Defining Clean-up Actions" in tutorial

2016-09-30 Thread Terry J. Reedy

Changes by Terry J. Reedy :


--
assignee: docs@python -> terry.reedy
nosy: +terry.reedy
stage:  -> commit review
versions: +Python 3.6, Python 3.7

___
Python tracker 

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



[issue18235] _sysconfigdata.py wrong on AIX installations

2016-09-30 Thread David Edelsohn

David Edelsohn added the comment:

Michael,

Are you suggesting to move the code fragment *AND* revert or change the 
reversal of LDSHARED?  The Python code seems to be setting and reversing the 
value in multiple places.

This also relates to Issue25825.

Repeatedly flipping this around is not making progress.

--

___
Python tracker 

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



[issue28287] Refactor subprocess.Popen to let a subclass handle IO asynchronously

2016-09-30 Thread Terry J. Reedy

Changes by Terry J. Reedy :


--
versions: +Python 3.7 -Python 3.6

___
Python tracker 

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



[issue28287] Refactor subprocess.Popen to let a subclass handle IO asynchronously

2016-09-30 Thread Terry J. Reedy

Changes by Terry J. Reedy :


--
nosy: +yselivanov

___
Python tracker 

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



[issue28228] imghdr does not support pathlib

2016-09-30 Thread Ethan Furman

Ethan Furman added the comment:

Berker, yes please.  I just got back from vacation.

--

___
Python tracker 

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



[issue28264] Turtle.onclick events blocked by Turtle.stamp

2016-09-30 Thread Terry J. Reedy

Terry J. Reedy added the comment:

3.4 only gets security patches.  I cannot reproduce in 3.5.2 or 3.6.0b1 on Win  
10.  Left click always moves the turtle whether or not stamp is activated.  
Until problem is verified in a current release, we will have to assume it has 
been fixed by a turtle or tkinter patch in 3.5.

--
nosy: +terry.reedy
title: Python 3.4.4 Turtle library - Turtle.onclick events blocked by 
Turtle.stamp -> Turtle.onclick events blocked by Turtle.stamp

___
Python tracker 

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



[issue28318] Python unittest.mock.mock_calls stores references to arguments instead of their values

2016-09-30 Thread R. David Murray

R. David Murray added the comment:

This is pretty much just the way python works.  The only alternative would be 
for mock to try to do a deepcopy, which won't always work, so it is probably 
better not to do it at all.

--
nosy: +michael.foord, r.david.murray, rbcollins

___
Python tracker 

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



[issue28319] typo in lzma module documentation

2016-09-30 Thread Vladimir Rutsky

New submission from Vladimir Rutsky:

"Specifying custom filter chains" section contains:

> It only supports a single The delta filter supports only one option, dist.

Probably should be just:

> The delta filter supports only one option, dist.

--
assignee: docs@python
components: Documentation
messages: 277765
nosy: docs@python, vrutsky
priority: normal
severity: normal
status: open
title: typo in lzma module documentation
versions: Python 3.5, Python 3.7

___
Python tracker 

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



[issue28301] python3.4-config --extension-suffix reports '.cpython-34m.so'

2016-09-30 Thread Berker Peksag

Changes by Berker Peksag :


--
resolution:  -> not a bug
stage:  -> 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



[issue28318] Python unittest.mock.mock_calls stores references to arguments instead of their values

2016-09-30 Thread Guillaume Chorn

New submission from Guillaume Chorn:

In the unittest.mock library, when a Mock object stores the calls made on it in 
its `mock_calls` attribute, it appears to store references to the call 
arguments instead of the actual values of the call arguments. In cases where 
call args are mutable types, this results in the undesirable behavior below:

```python
import mock

arg = ['one']

test_function(arg)

# passes
test_function.assert_has_calls([mock.call(['one'])])

arg += ['two']

test_function(arg)

# fails, even though we just verified the first call above!
test_function.assert_has_calls([
mock.call(['one']),
mock.call(['one','two'])
])

# passes, even though we didn't make the exact same call twice!
test_function.assert_has_calls([
mock.call(['one', 'two']),
mock.call(['one', 'two'])
])
```

--
components: Tests
messages: 277764
nosy: Guillaume Chorn
priority: normal
severity: normal
status: open
title: Python unittest.mock.mock_calls stores references to arguments instead 
of their values
type: behavior
versions: Python 3.4

___
Python tracker 

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



[issue28217] Add interactive console tests

2016-09-30 Thread Steve Dower

Steve Dower added the comment:

Added my work on this so far. I've only done input testing, but that's the more 
important one anyway in my opinion.

Feel free to suggest more edge cases we ought to test and I'll try and get to 
adding them before b2.

--
keywords: +patch
Added file: http://bugs.python.org/file44895/28217_1.patch

___
Python tracker 

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



[issue28259] Ctypes bug windows

2016-09-30 Thread Aristotel

Aristotel added the comment:

I use 32-bit python on 64-bit windows

--
components:  -Windows

___
Python tracker 

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



[issue28269] [MinGW] Can't compile Python/dynload_win.c due to static strcasecmp

2016-09-30 Thread Steve Dower

Steve Dower added the comment:

Why not replace it entirely with stricmp? Does it behave differently?

--
components: +Windows
nosy: +paul.moore, steve.dower, tim.golden, zach.ware

___
Python tracker 

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



[issue28259] Ctypes bug windows

2016-09-30 Thread Steve Dower

Steve Dower added the comment:

Are you using 64-bit? There was an issue passing structs a while back, but I 
don't recall when or if we've merged the patch.

--
components: +Windows
nosy: +paul.moore, steve.dower, tim.golden, zach.ware

___
Python tracker 

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



[issue28277] ./Modules/_io/_iomodule.c build failure on AIX (beta1) while (a2) was fine.

2016-09-30 Thread Berker Peksag

Changes by Berker Peksag :


--
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



[issue28207] Use pkg-config to find dependencies

2016-09-30 Thread Xavier de Gaye

Changes by Xavier de Gaye :


--
nosy: +xdegaye

___
Python tracker 

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



[issue28288] Expose environment variable for Py_Py3kWarningFlag

2016-09-30 Thread Roy Williams

Roy Williams added the comment:

Thanks for your support!  Here's a patch to enable the `PYTHON3WARNINGS` 
environment variable.

--
keywords: +patch
Added file: http://bugs.python.org/file44894/pythonenable3kwarningsflag.patch

___
Python tracker 

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



[issue28190] Detect curses headers correctly for cross-compiling

2016-09-30 Thread Xavier de Gaye

Changes by Xavier de Gaye :


--
nosy: +xdegaye

___
Python tracker 

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



[issue28199] Compact dict resizing is doing too much work

2016-09-30 Thread INADA Naoki

INADA Naoki added the comment:

Ah, I'm sorry.
I forget to remove some changes relating to inplace compaction (reusing oldkeys 
when oldsize==newsize).

--
Added file: http://bugs.python.org/file44893/dictresize2.patch

___
Python tracker 

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



[issue26351] Occasionally check for Ctrl-C in long-running operations like sum

2016-09-30 Thread Trey Hunner

Trey Hunner added the comment:

This is a problem I experience occasionally while teaching and while developing 
teaching curriculum.

I tend to close problem windows quickly enough to avoid a computer crash in 
front of a live audience, but it's still an annoyance to get the REPL state 
back to the way I had it before killing the process.

This mostly happens when I'm teaching iterators or itertools, but occasionally 
I hit a "Ctrl-C free zone" in other ways.  I believe this memory-filling 
snippet wouldn't respond to Ctrl-C either: x=[0]*2**30

I hadn't thought to report a bug on this because my use seemed niche.  I mostly 
get this error while demonstrating concepts via weird/incorrect code at the 
REPL.

--
nosy: +trey

___
Python tracker 

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



[issue28199] Compact dict resizing is doing too much work

2016-09-30 Thread STINNER Victor

STINNER Victor added the comment:

dictresize.patch is quite big, it seems like half of the patch is more 
cleanup/refactoring. Can you please split the patch into two parts, to only a 
smaller patch just for the optimization part?

--

___
Python tracker 

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



[issue28199] Compact dict resizing is doing too much work

2016-09-30 Thread STINNER Victor

STINNER Victor added the comment:

Oh, your message reminded me that I always wanted an option in the timeit 
module to run the benchmark on two Python versions and then directly compare 
the result. I just added the feature to perf and then I released perf 0.7.11, 
enjoy! The output is more compact and it's more reliable because the comparison 
ensures that the difference is significant.

---
$ export PYTHONPATH=~/prog/GIT/perf
$ ./python-resize -m perf timeit --inherit-environ=PYTHONPATH 
--compare-to=./python-ref -s 'x = range(1000); d={}' 'for i in x: d[i]=i; del 
d[i];' --rigorous
python-ref:  77.6 us +- 1.8 us
python-resize:  74.8 us +- 1.9 us

Median +- std dev: [python-ref] 77.6 us +- 1.8 us -> [python-resize] 74.8 us +- 
1.9 us: 1.04x faster
---

I can reproduced the 4% speedup.

(I didn't review the patch yet.)

--
nosy: +haypo

___
Python tracker 

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



[issue28317] Improve support of FORMAT_VALUE in dis

2016-09-30 Thread Serhiy Storchaka

New submission from Serhiy Storchaka:

FORMAT_VALUE packs the information about conversion flags and boolean flag that 
denotes whether format specifier is passed on the stack in one integer 
argument. It is not easy to decode this information in disassemble output. 
Proposed patch makes disassembler producing human readable representation of 
FORMAT_VALUE argument.

$ echo 'f"{a} {b:4} {c!r} {d!r:4}"' | ./python -m dis
  1   0 LOAD_NAME0 (a)
  2 FORMAT_VALUE 0
  4 LOAD_CONST   0 (' ')
  6 LOAD_NAME1 (b)
  8 LOAD_CONST   1 ('4')
 10 FORMAT_VALUE 4 (with format)
 12 LOAD_CONST   0 (' ')
 14 LOAD_NAME2 (c)
 16 FORMAT_VALUE 2 (repr)
 18 LOAD_CONST   0 (' ')
 20 LOAD_NAME3 (d)
 22 LOAD_CONST   1 ('4')
 24 FORMAT_VALUE 6 (repr, with format)
 26 BUILD_STRING 7
 28 POP_TOP
 30 LOAD_CONST   2 (None)
 32 RETURN_VALUE

--
components: Library (Lib)
files: dis_format_string.patch
keywords: patch
messages: 277754
nosy: eric.smith, serhiy.storchaka
priority: normal
severity: normal
stage: patch review
status: open
title: Improve support of FORMAT_VALUE in dis
type: enhancement
versions: Python 3.6, Python 3.7
Added file: http://bugs.python.org/file44892/dis_format_string.patch

___
Python tracker 

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



[issue28301] python3.4-config --extension-suffix reports '.cpython-34m.so'

2016-09-30 Thread Chi Hsuan Yen

Chi Hsuan Yen added the comment:

Yeah that's expected. See issue9806 and PEP 3149.

--
nosy: +Chi Hsuan Yen

___
Python tracker 

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



[issue28183] Clean up and speed up dict iteration

2016-09-30 Thread INADA Naoki

INADA Naoki added the comment:

Refactoring includes replacing PyDict_Next with _PyDict_Next.
It can improve performance by skipping some checks.
But it would be too small to see difference from benchmark.

I'll reduce diff size, hopefully in this weekend.

--

___
Python tracker 

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



[issue28199] Compact dict resizing is doing too much work

2016-09-30 Thread INADA Naoki

INADA Naoki added the comment:

$ ./install/bin/python3.6-default -m perf timeit -s 'x = range(1000); d={}' 
'for i in x: d[i]=i; del d[i];'

Median +- std dev: 363 us +- 11 us
$ ./install/bin/python3.6 -m perf timeit -s 'x = range(1000); d={}' 'for i in 
x: d[i]=i; del d[i];'  # patched

Median +- std dev: 343 us +- 17 us
$ ./install/bin/python3.6-default -m perf timeit -s 'x = range(1000); d={}' 
'for i in x: d[i]=i; del d[i];'

Median +- std dev: 362 us +- 11 us
$ ./install/bin/python3.6 -m perf timeit -s 'x = range(1000); d={}' 'for i in 
x: d[i]=i; del d[i];'  # patched

Median +- std dev: 342 us +- 14 us
$ ./install/bin/python3.6-default -m perf timeit -s 'x = range(1000); d={}' 
'for i in x: d[i]=i; del d[i];'

Median +- std dev: 364 us +- 11 us

--
assignee:  -> inada.naoki

___
Python tracker 

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



[issue27275] KeyError thrown by optimised collections.OrderedDict.popitem()

2016-09-30 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Eric, could you please look at the patch? Maybe I missed some reasons for 
current implementation.

--

___
Python tracker 

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



[issue27942] Default value identity regression

2016-09-30 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Thanks Naoki and Josh for reviews.

Backported to 2.7 and 3.5 since the patch also fixes other issues.

Note that the result of ``arg is "str_value"`` is implementation detail. Other 
Python implementations may not intern string constants. Even CPython interns 
only strings constants consisting of ASCII alphanumerical characters.

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

___
Python tracker 

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



[issue27942] Default value identity regression

2016-09-30 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 78bea78d9335 by Serhiy Storchaka in branch '3.5':
Issue #27942: String constants now interned recursively in tuples and 
frozensets.
https://hg.python.org/cpython/rev/78bea78d9335

New changeset 0ce63a7651b9 by Serhiy Storchaka in branch '3.6':
Issue #27942: String constants now interned recursively in tuples and 
frozensets.
https://hg.python.org/cpython/rev/0ce63a7651b9

New changeset 44af6bd21b94 by Serhiy Storchaka in branch 'default':
Issue #27942: String constants now interned recursively in tuples and 
frozensets.
https://hg.python.org/cpython/rev/44af6bd21b94

New changeset 7cea3bf44acb by Serhiy Storchaka in branch '2.7':
Issue #27942: String constants now interned recursively in tuples and 
frozensets.
https://hg.python.org/cpython/rev/7cea3bf44acb

--
nosy: +python-dev

___
Python tracker 

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



[issue28311] AIX shared library extension modules installation broken - Python2.7

2016-09-30 Thread Martin Panter

Martin Panter added the comment:

I think this might be separate to Issue 25825, but my investigation at 
 may be relevant. Following on 
from that, I reopened Issue 18235, which seems to be about the same LDSHARED vs 
BLDSHARED problem, but never fixed in 2.7.

--
nosy: +martin.panter
resolution:  -> duplicate
status: open -> closed
superseder:  -> _sysconfigdata.py wrong on AIX installations

___
Python tracker 

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



[issue25488] IDLE: Remove '', user_dir, and idlelib from sys.path when added

2016-09-30 Thread Terry J. Reedy

Terry J. Reedy added the comment:

I usually start repository IDLE with 'import idlelib.idle' in repository 
console python, which I have pinned to my taskbar.  This is at least as faster 
as entering a command in the console (which would block the console), keeps 
error messages for one version together in one place and separate from anything 
else, and leaves my console free to enter other commands.

The import change will make idlelib.idle.main() work to restart IDLE after 
closing it.  Previously, idlelib.idle.idlelib.pyshell.main() was required, 
which I never did.  I marked the import as subject to change, as I intend to 
move (and edit) much of pyshell.main to idle.py.

--
versions: +Python 3.7

___
Python tracker 

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



[issue18235] _sysconfigdata.py wrong on AIX installations

2016-09-30 Thread Martin Panter

Martin Panter added the comment:

Reopening this to fix the original bug in 2.7, and to improve things for Python 
3.

Michael Felt (or anyone else): Can you confirm if Michael Haubenwallner’s 
suggested patch from  is 
appropriate? It looks like that patch won’t apply directly to 2.7, but the 
spirit of that patch looks sensible to me for Python 2 and 3. I.e. don’t mess 
with the variables in _generate_posix_vars(), which writes them to a data file, 
but overwrite LDSHARED in _init_posix(), which happens at run time.

--
nosy: +Michael.Felt
stage: resolved -> patch review
status: closed -> open
superseder: AIX shared library extension modules installation broken - 
Python2.7 -> 
versions: +Python 2.7, Python 3.5, Python 3.6, Python 3.7 -Python 3.3, Python 
3.4

___
Python tracker 

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



[issue25488] IDLE: Remove '', user_dir, and idlelib from sys.path when added

2016-09-30 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 5f788ad057ca by Terry Jan Reedy in branch '2.7':
Issue #25488: Stpp idle.py from adding a entry when it is a duplicate.
https://hg.python.org/cpython/rev/5f788ad057ca

New changeset 013956a801e4 by Terry Jan Reedy in branch '3.5':
Issue #25488: Stpp idle.py from adding a entry when it is a duplicate.
https://hg.python.org/cpython/rev/013956a801e4

New changeset 25ae49903496 by Terry Jan Reedy in branch '3.6':
Issue #25488: merge idle.py from 3.5.
https://hg.python.org/cpython/rev/25ae49903496

--
nosy: +python-dev

___
Python tracker 

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



[issue25488] IDLE: Remove '', user_dir, and idlelib from sys.path when added

2016-09-30 Thread Terry J. Reedy

Terry J. Reedy added the comment:

sys.path for 3.6.0b1 on Win 10.
Start python from icon (start menu), console (py -3.6) or Explorer (click on 
python.exe)
'',
'C:\\Programs\\Python36\\python36.zip',
'C:\\Programs\\Python36\\DLLs',
'C:\\Programs\\Python36\\lib',
'C:\\Programs\\Python36',
'C:\\Programs\\Python36\\lib\\site-packages',

Start Python from Explorer by double-clicking *.py file or context menu 'Open': 
replace '' with
'C:/user/Terry/lib'  # directory containing file.

Running 'import sys; sys.path' (in user process) from IDLE Shell adds the 
following after ''.
Start IDLE from icon:
'C:\\Programs\\Python36\\Lib\\idlelib',
Start IDLE in console with py -3.6 -m idlelib:
'F:\\Python\\dev'  # the CWD of the console
Start IDLE in console with py -3.6 -m idlelib.idle:
'C:\\Programs\\Python36\\lib',  # duplicate added by idle.py
'F:\\Python\\dev'  # the CWD of the console
Start IDLE from Python with 'import idlelib.idle'
'C:\\Programs\\Python36\\lib',  # duplicate added by idle.py
'C:\\Programs\\Python36'  # the CWD of the running Python (dup)

Currently, idle.py inserts the directory containing idlelib into sys.path.  
This is a duplicate unless running idlelib in a non-stanard location.  Check 
first.

--

___
Python tracker 

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



[issue28316] descriptor and repr get into conflict

2016-09-30 Thread Benjamin Peterson

Benjamin Peterson added the comment:

This is no different than this simpler case:

class A:
def __init__(self, name):
print("init {!r}".format(self))
self.name = name
def __repr__(self):
return "I am {}".format(self.name)

The instance of A doesn't not have a name attribute for __repr__ to use until 
you set it.

--
nosy: +benjamin.peterson
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



[issue18235] _sysconfigdata.py wrong on AIX installations

2016-09-30 Thread Martin Panter

Martin Panter added the comment:

It might have been good to get this reopened to attract more attention to it. 
Anyway, Issue 28311 has now been opened for 2.7, and it seems to be about the 
same problem.

--
nosy: +martin.panter
superseder:  -> AIX shared library extension modules installation broken - 
Python2.7

___
Python tracker 

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



[issue28316] descriptor and repr get into conflict

2016-09-30 Thread Sabine Maennel

New submission from Sabine Maennel:

I was working with descriptors and hit on an error, that I do not understand. 
I attach a protocol of my interactive python session that will show you what 
happened and the session is reproducible:

I had a class employing a descriptor: 
class Descriptor(object):
def __init__(self, name):
self.name = name
def __set__(self, instance, val):
print('Updating', self.name, 'for', instance)
instance.__dict__[self.name] = val

class A:
x = Descriptor('x')
def __init__(self, name, x):
self.x = x
self.name = name
def __repr__(self):
return "I am {}".format(self.name)

if defined like this it hits an error when I want to initialize it:
a = A('a', 2)
Traceback (most recent call last):
  File "", line 1, in 
  File "", line 4, in __init__
  File "", line 5, in __set__
  File "", line 7, in __repr__
AttributeError: 'A' object has no attribute 'name'
Updating x for 

The error could be fixed by just exchanging the assignments in the __init__ of 
A:
class A:
x = Descriptor('x')
def __init__(self, name, x):
self.name = name
self.x = x
def __repr__(self):
return "I am {}".format(self.name)
Now a = A('a', 2) works as expected. But this seems weird to me.

--
files: descriptor_and_repr_error
messages: 277740
nosy: sabine.maen...@gmail.com
priority: normal
severity: normal
status: open
title: descriptor and repr get into conflict
type: crash
versions: Python 3.5
Added file: http://bugs.python.org/file44891/descriptor_and_repr_error

___
Python tracker 

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



[issue27942] Default value identity regression

2016-09-30 Thread Josh Rosenberg

Changes by Josh Rosenberg :


--
nosy: +josh.r

___
Python tracker 

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