[issue31817] Compilation Error with Python 3.6.1/3.6.3 with Tkinter

2017-11-28 Thread Josh Cullum
Josh Cullum added the comment: Hi Ned, I've built a new machine, tried the build again using Tk and Tcl shared libraries, built Python-3.6.3 and it's still not worked. The Python/3.6.3-foss-2017b/lib/python3.6/tkinter folder gets created and populated with several

Re: nospam ** infinity?

2017-11-28 Thread Peter Otten
Skip Montanaro wrote: >> I'm 99.5% certain it's not gate_news. > > A funny thing. All messages I have looked at so far with the "nospam" > thing have a Message-ID from binkp.net. (They are also all Usenet > posts.) For example: > > Newsgroups: comp.lang.python > Subject: Re: I have anaconda,

[issue31380] test_undecodable_filename() in Lib/test/test_httpservers.py broken on APFS

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: > @vstinner, as the expert in this area, what do you suggest as the best way to > deal with this? In support.__init__.py? Or test_httpservers itself? It's tricky when a filename is valid or not depending on the path, depending on

[issue32138] android: test_faulthandler fails also on API 24

2017-11-28 Thread Xavier de Gaye
Change by Xavier de Gaye : -- keywords: +patch pull_requests: +4521 stage: needs patch -> patch review ___ Python tracker ___

Re: nospam ** infinity?

2017-11-28 Thread Thomas Jollans
On 2017-11-28 02:14, Skip Montanaro wrote: >> I'm 99.5% certain it's not gate_news. > > A funny thing. All messages I have looked at so far with the "nospam" > thing have a Message-ID from binkp.net. (They are also all Usenet > posts.) For example: > > Newsgroups: comp.lang.python > Subject: Re:

Re: How to shut down a TCPServer serve_forever() loop?

2017-11-28 Thread Chris Angelico
On Tue, Nov 28, 2017 at 11:52 PM, Marko Rauhamaa wrote: > Chris Angelico : > >> On Tue, Nov 28, 2017 at 5:04 PM, Marko Rauhamaa wrote: >>> Seems to be one of the fundamental multithreading issues: each thread >>> is blocked on precisely one

Re: While, If, Count Statements

2017-11-28 Thread Cai Gengyang
On Tuesday, November 28, 2017 at 4:18:04 PM UTC+8, Frank Millman wrote: > "Cai Gengyang" wrote in message > news:c2dfc9c4-3e16-480c-aebf-553081775...@googlegroups.com... > > > Sure, so how would the code look like if I want the "if" statement to be > > nested inside the "while" loop > > Have

Re: How to shut down a TCPServer serve_forever() loop?

2017-11-28 Thread Chris Angelico
On Tue, Nov 28, 2017 at 5:04 PM, Marko Rauhamaa wrote: > Ian Kelly : > >> On Sat, Nov 25, 2017 at 7:10 AM, John Pote >> wrote: >>> The issue is that if I press a key on the keyboard the key is >>> immediately shown on the

[issue32153] mock.create_autospec fails if an attribute is a partial function

2017-11-28 Thread Claudiu Belu
Change by Claudiu Belu : -- versions: -Python 3.8 ___ Python tracker ___ ___

[issue32153] mock.create_autospec fails if an attribute is a partial function

2017-11-28 Thread Claudiu Belu
New submission from Claudiu Belu : If an object's attribute is a partial function, mock.create_autospec will fail while trying to copy the partial functions' details to the mocked function, as the partial function does not have the __name__ attribute. Example:

[issue31380] test_undecodable_filename() in Lib/test/test_httpservers.py broken on APFS

2017-11-28 Thread Ronald Oussoren
Ronald Oussoren added the comment: Another option is to skip this test unconditionally on macOS when using APFS, the test is already skipped on win32 and tests a generic codepath where only testing on Linux should be fine. BTW. It is fairly easy to detect if a path is

Re: nospam ** infinity?

2017-11-28 Thread breamoreboy
On Tuesday, November 28, 2017 at 1:14:51 AM UTC, Skip Montanaro wrote: > > I'm 99.5% certain it's not gate_news. > > A funny thing. All messages I have looked at so far with the "nospam" > thing have a Message-ID from binkp.net. (They are also all Usenet > posts.) For example: > > Newsgroups:

[issue32154] asyncio: Don't export selectors and _overlapped in asyncio namespace

2017-11-28 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch pull_requests: +4522 stage: -> patch review ___ Python tracker ___

Re: nospam ** infinity?

2017-11-28 Thread Tim Golden
On 28/11/2017 10:17, Thomas Jollans wrote: On 2017-11-28 02:14, Skip Montanaro wrote: I'm 99.5% certain it's not gate_news. A funny thing. All messages I have looked at so far with the "nospam" thing have a Message-ID from binkp.net. (They are also all Usenet posts.) For example: Newsgroups:

[issue32108] configparser bug: section is emptied if you assign a section to itself

2017-11-28 Thread Dong-hee Na
Change by Dong-hee Na : -- nosy: +corona10 ___ Python tracker ___ ___

Re: While, If, Count Statements

2017-11-28 Thread Frank Millman
"Cai Gengyang" wrote in message news:a8335d2c-1fb9-4ba9-b752-418d19e57...@googlegroups.com... On Tuesday, November 28, 2017 at 4:18:04 PM UTC+8, Frank Millman wrote: > "Cai Gengyang" wrote in message > news:c2dfc9c4-3e16-480c-aebf-553081775...@googlegroups.com... > > > Sure, so how would the

[issue32154] asyncio: Don't export selectors and _overlapped in asyncio namespace

2017-11-28 Thread STINNER Victor
New submission from STINNER Victor : For backward compatibility with Python 3.3, Lib/asyncio/__init__.py exports asyncio.selectors and asyncio._overlapped symbols. Python 3.3 reached it's end of line last september, it's time to move on:

Re: Increasing the diversity of people who write Python (was: Benefits of unicode identifiers)

2017-11-28 Thread Thomas Jollans
On 2017-11-24 17:41, Skip Montanaro wrote: > Perhaps for my next computer I should choose a > non-ASCII keyboard option when configuring it. > > Skip > I'm quite fond of the US international keyboard layout. It lets you type most Latin-lettered languages with relative ease (including,

[issue32108] configparser bug: section is emptied if you assign a section to itself

2017-11-28 Thread Dong-hee Na
Change by Dong-hee Na : -- keywords: +patch pull_requests: +4523 stage: -> patch review ___ Python tracker ___

Re: How to shut down a TCPServer serve_forever() loop?

2017-11-28 Thread Marko Rauhamaa
Chris Angelico : > On Tue, Nov 28, 2017 at 5:04 PM, Marko Rauhamaa wrote: >> Seems to be one of the fundamental multithreading issues: each thread >> is blocked on precisely one event. Asyncio is more flexible: you can >> multiplex on a number of events. > >

[issue32157] Remove explicit quotes around %r and {!r}

2017-11-28 Thread Yury Selivanov
Change by Yury Selivanov : -- nosy: -yselivanov ___ Python tracker ___ ___

[issue32157] Remove explicit quotes around %r and {!r}

2017-11-28 Thread Ethan Furman
Ethan Furman added the comment: Yup, I sure did. :/ Looks like a good change to me. Are these the only instances of quotes used with %r? -- ___ Python tracker

Has anyone worked on docker with windows

2017-11-28 Thread Robert Clove
Hi, what am i trying to achieve is, container of windows with an application like slack on it. Does window container has an UI? Has anyone worked on it, is it feasible? -- https://mail.python.org/mailman/listinfo/python-list

[issue31440] wrong default module search path in help message

2017-11-28 Thread Christian Heimes
Christian Heimes added the comment: New changeset cb79c2203953bd465f2c53b7a09a51071717575f by Christian Heimes (Miss Islington (bot)) in branch '3.6': bpo-31440: Changed default module search path for windows (#4613)

[issue31440] wrong default module search path in help message

2017-11-28 Thread Christian Heimes
Christian Heimes added the comment: I'll do a backport tomorrow. -- assignee: -> christian.heimes ___ Python tracker ___

Salabim 2.2.7 released

2017-11-28 Thread Ruud van der Ham
This is to announce salabim version 2.2.7 . Salabim is a discrete event event simulation (DES) package with a very powerful animation engine. With this release, queues and 'states' can be animated with just a couple of lines of code. See several examples for a demonstration of these new

[issue32157] Remove explicit quotes around %r and {!r}

2017-11-28 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +4530 ___ Python tracker ___

Re: How to shut down a TCPServer serve_forever() loop?

2017-11-28 Thread Chris Angelico
On Wed, Nov 29, 2017 at 4:22 AM, Marko Rauhamaa wrote: > I have solved the gethostbyname() problem by implementing the DNS > protocol myself (in Python). Do you respect /etc/nsswitch.conf? >> I don't understand why you keep insisting that asyncio and threads are >> somehow

[issue32157] Remove explicit quotes around %r and {!r}

2017-11-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Yes, these are the only instances of quotes used with %r or {!r}. -- ___ Python tracker

[issue32072] Issues with binary plists

2017-11-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Ronald, could you please make a review? I want to merge this before 3.7.0a3. -- ___ Python tracker

[issue32157] Remove explicit quotes around %r and {!r}

2017-11-28 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : It is common to use quotes around %s. If the formatted argument is a string this will produce a string in qoutes, that look as a string literal in Python and other programming languages or just as a quoted string in English.

Re: How to shut down a TCPServer serve_forever() loop?

2017-11-28 Thread Marko Rauhamaa
Chris Angelico : > On Tue, Nov 28, 2017 at 11:52 PM, Marko Rauhamaa wrote: >> The original poster's problem seems to be caused by blocking APIs that >> cannot be multiplexed using select(). A good many Python facilities are >> the same way. >> >> Such

[issue32157] Remove explicit quotes around %r and {!r}

2017-11-28 Thread Antoine Pitrou
Antoine Pitrou added the comment: Ethan, I think you misunderstood Serhiy's proposal. -- ___ Python tracker ___

[issue16487] Allow ssl certificates to be specified from memory rather than files.

2017-11-28 Thread Jan-Philip Gehrcke
Jan-Philip Gehrcke added the comment: Hello! I would very much appreciate if we can find a way for us to get another review for the last patch. I did most of the work in August 2016 and got a review from Senthil and Christian which I processed. When I got back to the

Re: How to shut down a TCPServer serve_forever() loop?

2017-11-28 Thread Chris Angelico
On Wed, Nov 29, 2017 at 5:03 AM, Marko Rauhamaa wrote: > Chris Angelico : > >> On Wed, Nov 29, 2017 at 4:22 AM, Marko Rauhamaa wrote: >>> I have solved the gethostbyname() problem by implementing the DNS >>> protocol myself (in Python). >> >>

[issue32107] Improve MAC address calculation and fix test_uuid.py

2017-11-28 Thread Barry A. Warsaw
Change by Barry A. Warsaw : -- title: test_uuid uses the incorrect bitmask -> Improve MAC address calculation and fix test_uuid.py ___ Python tracker

[issue32156] Fix flake8 warning F401: ... imported but unused

2017-11-28 Thread STINNER Victor
New submission from STINNER Victor : Attached PR removes unused imports. -- components: Library (Lib) messages: 307126 nosy: vstinner priority: normal severity: normal status: open title: Fix flake8 warning F401: ... imported but unused versions: Python 3.7

[issue32155] Fix flake8 warning F841: local variable ... is assigned to but never used

2017-11-28 Thread Berker Peksag
Berker Peksag added the comment: I don't think distutils changes are correct. ('realm', self.DEFAULT_REALM) 'realm' is the config name and 'self.DEFAULT_REALM' is its default value. In the 'for key, default in ...:' loop, 1. It checks if it's already set in the

[issue32150] Expand tabs to spaces in C files

2017-11-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thanks Guido! I think now we can revive issue8912. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue32157] Remove explicit quotes around %r and {!r}

2017-11-28 Thread Ethan Furman
Ethan Furman added the comment: I make sure to use %r in error-reporting and debugging messages precisely because it's output is (usually) valid python. If I see a 1 without quotes I know it's a number, and with quotes I know it's a string. -1 -- nosy:

Re: How to shut down a TCPServer serve_forever() loop?

2017-11-28 Thread Marko Rauhamaa
Chris Angelico : > On Wed, Nov 29, 2017 at 5:03 AM, Marko Rauhamaa wrote: >> Chris Angelico : >>> Do you respect /etc/nsswitch.conf? >> >> No, but I don't need to. > > Ah, right. Until the day you're wrestling with "why doesn't /etc/hosts >

[issue32157] Remove explicit quotes around %r and {!r}

2017-11-28 Thread Ethan Furman
Change by Ethan Furman : -- Removed message: https://bugs.python.org/msg307149 ___ Python tracker ___

[issue16487] Allow ssl certificates to be specified from memory rather than files.

2017-11-28 Thread Senthil Kumaran
Senthil Kumaran added the comment: Hello JP, I had been little inactive for a while (>2 years). However, I think, I can take now some load in CPython world and I will take this ticket/feature forward this Sunday (1-Dec-2017). If Christian (or currently active committers)

Re: How to shut down a TCPServer serve_forever() loop?

2017-11-28 Thread Marko Rauhamaa
Chris Angelico : > On Wed, Nov 29, 2017 at 4:22 AM, Marko Rauhamaa wrote: >> I have solved the gethostbyname() problem by implementing the DNS >> protocol myself (in Python). > > Do you respect /etc/nsswitch.conf? No, but I don't need to. >>> I don't

Re: While, If, Count Statements

2017-11-28 Thread Cai Gengyang
On Tuesday, November 28, 2017 at 8:12:09 PM UTC+8, Frank Millman wrote: > "Cai Gengyang" wrote in message > news:a8335d2c-1fb9-4ba9-b752-418d19e57...@googlegroups.com... > > > > On Tuesday, November 28, 2017 at 4:18:04 PM UTC+8, Frank Millman wrote: > > > "Cai Gengyang" wrote in message > > >

[issue27535] Ignored ResourceWarning warnings leak memory in warnings registries

2017-11-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I'm not sure. Ask the RM for 3.6. As for 2.7, does this problem exist in 2.7? -- ___ Python tracker

[issue32156] Fix flake8 warning F401: ... imported but unused

2017-11-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I suggest to split your patch on several PR for different domains, and let the domain experts review changes separately. IDLE changes look mostly harmless to me. But changes in distutils should be made with a large care.

[issue32046] 2to3 fix for operator.isCallable()

2017-11-28 Thread Éric Araujo
Éric Araujo added the comment: Merged in master, I suppose stable branches should be left alone? -- ___ Python tracker ___

[issue32155] Fix flake8 warning F841: local variable ... is assigned to but never used

2017-11-28 Thread STINNER Victor
New submission from STINNER Victor : Using flake8, I found some bugs in the standard libraries and tools. I already fixed another flake8 error: --- commit 28e61650b23119b68cd7943ccc01b8b9af1b4103 Author: Victor Stinner Date: Tue Nov 28

[issue31901] atexit callbacks should be run at subinterpreter shutdown

2017-11-28 Thread Marcel Plch
Change by Marcel Plch : -- keywords: +patch pull_requests: +4527 stage: -> patch review ___ Python tracker ___

[issue32155] Fix flake8 warning F841: local variable ... is assigned to but never used

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: > If you have replaced self.DEFAULT_REALM with realm why not replace > self.DEFAULT_REPOSITORY with repository? Oh, I didn't notice that there is also a repository variable which is not used in all code paths. > I don't know what

[issue31440] wrong default module search path in help message

2017-11-28 Thread Roundup Robot
Change by Roundup Robot : -- pull_requests: +4528 ___ Python tracker ___

[issue32154] asyncio: Don't export selectors and _overlapped in asyncio namespace

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: Serhiy Storchaka: "Is this function publicly documented? If this is true, it should first be deprecated." It's not documented, but I found a reference in the documentation: --- try: from socket import socketpair except

[issue32150] Expand tabs to spaces in C files

2017-11-28 Thread Guido van Rossum
Guido van Rossum added the comment: OK, so I think you can go ahead with this. I was fine with the state of the patch yesterday, so whatever you added today is also fine. -- ___ Python tracker

[issue30657] Unsafe arithmetic in PyString_DecodeEscape

2017-11-28 Thread Leo kirotawa silva
Leo kirotawa silva added the comment: I re-did the build here for python3.4 and couldn't reach the same test fail. So I'm assuming it was a false alarm. Said that, I believe the same patch that applies to py2.7 also applies to 3.4 and 3.5. I've build them using the patch

[issue32155] Fix flake8 warning F841: local variable ... is assigned to but never used

2017-11-28 Thread Éric Araujo
Éric Araujo added the comment: The best course of action would be to revert the distutils changes. There are a handful of tickets related to register/upload commands, which are funky commands with their own config file not 100% in line with other distutils commands.

[issue32154] asyncio: Don't export selectors and _overlapped in asyncio namespace

2017-11-28 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +4525 ___ Python tracker ___ ___

[issue27535] Ignored ResourceWarning warnings leak memory in warnings registries

2017-11-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I meant the original issue. AFAIK ResourceWarningis not raised in 2.7. And other warnings less likely have unique messages. Seems the problem is less critical in 2.7. -- ___ Python

[issue32154] asyncio: Don't export selectors and _overlapped in asyncio namespace

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: New changeset 4271dfd7815c05fd39b515c240050b3585bdfcd4 by Victor Stinner in branch 'master': bpo-32154: Remove asyncio.selectors (#4605) https://github.com/python/cpython/commit/4271dfd7815c05fd39b515c240050b3585bdfcd4 --

[issue32154] asyncio: Don't export selectors and _overlapped in asyncio namespace

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: I also proposed the PR 4609 to remove the old asyncio.windows_utils.socketpair alias. -- ___ Python tracker

asyncio loop.call_soon()

2017-11-28 Thread ast
Hello Python's doc says about loop.call_soon(callback, *arg): Arrange for a callback to be called as soon as possible. The callback is called after call_soon() returns, when control returns to the event loop. But it doesn't seem to be true; see this program: import asyncio async def

[issue27535] Ignored ResourceWarning warnings leak memory in warnings registries

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: Victor: "I consider that PR 4489 is a bugfix, so I proposed backports to Python 2.7 (PR 4588) and 3.6 (PR 4587)." Serhiy: Are you ok to backport the change to stable branches? -- ___

[issue32155] Fix flake8 warning F841: local variable ... is assigned to but never used

2017-11-28 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch pull_requests: +4524 stage: -> patch review ___ Python tracker ___

[issue32156] Fix flake8 warning F401: ... imported but unused

2017-11-28 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch pull_requests: +4529 stage: -> patch review ___ Python tracker ___

[issue32154] asyncio: Don't export selectors and _overlapped in asyncio namespace

2017-11-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Is this function publicly documented? If this is true, it should first be deprecated. It is left in the __all__ list. -- nosy: +serhiy.storchaka ___ Python tracker

[issue32108] configparser bug: section is emptied if you assign a section to itself

2017-11-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: PR 4607 doesn't look a correct solution to me. I don't know a precedence of calling deepcopy() for a value in __setitem__(). deepcopy() is too heavy, calling it can slow down normal cases. Using deepcopy likely means a bad

[issue32046] 2to3 fix for operator.isCallable()

2017-11-28 Thread Éric Araujo
Éric Araujo added the comment: New changeset a489599793f9b00ddc2c68e2ce3bce9cbb2c09a2 by Éric Araujo (Dong-hee Na) in branch 'master': bpo-32046: Update 2to3 when converts operator.isCallable(obj). (#4417)

[issue32144] email.policy.SMTP and SMTPUTF8 doesn't honor linesep's value

2017-11-28 Thread R. David Murray
R. David Murray added the comment: OK, I should have used the term the docs actually use: "serialization". get_content() is, I hope, clearly not serialization, while as_string() is. Does that make it make more sense? Do you see a way to improve the docs in this

[issue32155] Fix flake8 warning F841: local variable ... is assigned to but never used

2017-11-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: If you have replaced self.DEFAULT_REALM with realm why not replace self.DEFAULT_REPOSITORY with repository? I don't know what is correct. Added distutils experts for review. -- nosy: +dstufft, eric.araujo,

[issue31440] wrong default module search path in help message

2017-11-28 Thread Christian Heimes
Christian Heimes added the comment: New changeset 08d2b86a1058b733bb7f1ae2b55818dd9687d21c by Christian Heimes (gauravbackback) in branch 'master': bpo-31440: Changed default module search path for windows

[issue31440] wrong default module search path in help message

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: I confirm that Python 2.7 is affected and should also be fixed. -- nosy: +vstinner ___ Python tracker

[issue27535] Ignored ResourceWarning warnings leak memory in warnings registries

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: Serhiy: "As for 2.7, does this problem exist in 2.7?" Yes, see my PR 4588. If you run the test without the fix, the test fails. -- ___ Python tracker

[issue32150] Expand tabs to spaces in C files

2017-11-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 598ceae876ff4a23072e59945597e945583de4ab by Serhiy Storchaka in branch 'master': bpo-32150: Expand tabs to spaces in C files. (#4583)

Re: asyncio loop.call_soon()

2017-11-28 Thread Ian Kelly
On Tue, Nov 28, 2017 at 8:30 AM, ast wrote: > Hello > > Python's doc says about loop.call_soon(callback, *arg): > > Arrange for a callback to be called as soon as possible. The callback is > called after call_soon() returns, when control returns to the event loop. > > But it

Re: How to shut down a TCPServer serve_forever() loop?

2017-11-28 Thread Ian Kelly
On Tue, Nov 28, 2017 at 11:54 AM, Marko Rauhamaa wrote: > Chris Angelico : >> Would the OP have been trivially able to send a signal to the >> process? Yes. > >Python signal handlers are always executed in the main Python thread, >even if the signal was

[issue31732] Add TRACE level to the logging module

2017-11-28 Thread Antoine Pitrou
Change by Antoine Pitrou : -- Removed message: https://bugs.python.org/msg307162 ___ Python tracker ___

[issue32160] lzma documentation: example to XZ compress file on disk

2017-11-28 Thread Daniel Himmelstein
New submission from Daniel Himmelstein : The documentation for the lzma module currently contains 6 examples (https://docs.python.org/3.6/library/lzma.html#examples). However, it does not include an example to XZ compress a file on disk. The functionality I'm

Re: How to shut down a TCPServer serve_forever() loop?

2017-11-28 Thread Marko Rauhamaa
Chris Angelico : > On Wed, Nov 29, 2017 at 5:32 AM, Marko Rauhamaa wrote: >> Don't you worry about my programs. > > Okay, but you can't claim that problems are solvable if you cheat them. What I'm saying is that there's no particular reason why glibc couldn't

Re: asyncio loop.call_soon()

2017-11-28 Thread Terry Reedy
On 11/28/2017 11:02 AM, Ian Kelly wrote: On Tue, Nov 28, 2017 at 8:30 AM, ast wrote: Hello Python's doc says about loop.call_soon(callback, *arg): Arrange for a callback to be called as soon as possible. The callback is called after call_soon() returns, when control

[issue32158] Suppress (and other contextlib context managers) should work as decorators (where appropriate)

2017-11-28 Thread Jason R. Coombs
New submission from Jason R. Coombs : The contextlib docs explain why a decorator is nice: > It makes it clear that the cm applies to the whole function, rather than just > a piece of it (and saving an indentation level is nice, too). However, the built-in context managers

[issue32158] Suppress (and other contextlib context managers) should work as decorators (where appropriate)

2017-11-28 Thread Barry A. Warsaw
Change by Barry A. Warsaw : -- nosy: +barry ___ Python tracker ___ ___ Python-bugs-list

[issue31732] Add TRACE level to the logging module

2017-11-28 Thread Antoine Pitrou
Antoine Pitrou added the comment: Perhaps a recipe should be published to explain how to add your own levels? e.g.: >>> import logging >>> logging.NOTE = logging.INFO + 5 >>> logging.addLevelName(logging.INFO + 5, 'NOTE') >>> class MyLogger(logging.Logger): ...:def

[issue32159] Remove tools for CVS and Subversion

2017-11-28 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch pull_requests: +4531 stage: -> patch review ___ Python tracker ___

ANN: Bokeh 0.12.11 Released

2017-11-28 Thread Bryan Van de ven
On behalf of the Bokeh team, I am pleased to announce the release of version 0.12.11 of Bokeh! For more information and details, please see the announcement post at: https://bokeh.github.io/blog/2017/11/28/release-0-12-11/ If you are using Anaconda/miniconda, you can install it with

[issue32158] Suppress (and other contextlib context managers) should work as decorators (where appropriate)

2017-11-28 Thread Raymond Hettinger
Raymond Hettinger added the comment: > But it got me thinking - couldn't suppress (and possibly other) > contextlib decorators support this usage out of the box? They possibly could but probably shouldn't. My experience is that giving them a dual role makes them

[issue32159] Remove tools for CVS and Subversion

2017-11-28 Thread STINNER Victor
New submission from STINNER Victor : CPython migrated from CVS to Subversion, to Mercurial, and then to Git. CVS and Subversion are no more used to develop CPython. Changes of attached PR: * platform module: drop support for sys.subversion. The sys.subversion

[issue27535] Ignored ResourceWarning warnings leak memory in warnings registries

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: Serhiy: "I meant the original issue. AFAIK ResourceWarningis not raised in 2.7. And other warnings less likely have unique messages. Seems the problem is less critical in 2.7." Oh yes, sorry, I forgot your comment and I forgot that

[issue31732] Add TRACE level to the logging module

2017-11-28 Thread Antoine Pitrou
Antoine Pitrou added the comment: Perhaps a recipe should be published to explain how to add your own levels? >>> import logging >>> logging.NOTE = logging.INFO + 5 >>> logging.addLevelName(logging.INFO + 5, 'NOTE') >>> class MyLogger(logging.getLoggerClass()): ...:def

Re: How to shut down a TCPServer serve_forever() loop?

2017-11-28 Thread Chris Angelico
On Wed, Nov 29, 2017 at 5:32 AM, Marko Rauhamaa wrote: > Chris Angelico : > >> On Wed, Nov 29, 2017 at 5:03 AM, Marko Rauhamaa wrote: >>> Chris Angelico : Do you respect /etc/nsswitch.conf? >>> >>> No, but I don't need

[issue32071] Add py.test-like "-k" test selection to unittest

2017-11-28 Thread Antoine Pitrou
Antoine Pitrou added the comment: New changeset 4d193bcc2560b824389e4d98d9d8b9b34e33dbaf by Antoine Pitrou (Jonas Haag) in branch 'master': bpo-32071: Fix regression and add What's New entry (#4589)

[issue32158] Suppress (and other contextlib context managers) should work as decorators (where appropriate)

2017-11-28 Thread Jason R. Coombs
Jason R. Coombs added the comment: Fair enough. For an example, here's the case where I wanted to use the decorator to avoid excess indentation and keep the most meaningful part of the function at the base of the body: @suppress(KeyError) def v12_to_13(manager, case):

[issue32154] asyncio: Don't export selectors and _overlapped in asyncio namespace

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: New changeset ac577d7d0bd27a69921ced14c09172235ceebab5 by Victor Stinner in branch 'master': bpo-32154: Remove asyncio.windows_utils.socketpair (#4609) https://github.com/python/cpython/commit/ac577d7d0bd27a69921ced14c09172235ceebab5

[issue32154] asyncio: Don't export selectors and _overlapped in asyncio namespace

2017-11-28 Thread STINNER Victor
Change by STINNER Victor : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue32157] Remove explicit quotes around %r and {!r}

2017-11-28 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker

[issue32159] Remove tools for CVS and Subversion

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: Serhiy: "Is svnmap.txt used for mapping Subversion references to Mercurial references on the tracker? r88752" Brett, David, Ezio: any idea for Serhiy's question? -- nosy: +brett.cannon, ezio.melotti, r.david.murray

[issue32160] lzma documentation: example to XZ compress file on disk

2017-11-28 Thread Daniel Himmelstein
Change by Daniel Himmelstein : -- assignee: -> docs@python components: +Documentation nosy: +docs@python type: -> enhancement ___ Python tracker

[issue27535] Ignored ResourceWarning warnings leak memory in warnings registries

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: I ran a quick benchmark on Python 3.6: current code (3.6 branch, ref) => PR 4587 (patch): vstinner@apu$ python3 -m perf compare_to ref.json patch.json Mean +- std dev: [ref] 597 ns +- 10 ns -> [patch] 830 ns +- 15 ns: 1.39x slower

[issue32157] Remove explicit quotes around %r and {!r}

2017-11-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset a4a3020abc065d40f57069d6c69d0ddc85d6 by Serhiy Storchaka in branch 'master': bpo-32157: Removed explicit quotes around %r and {!r}. (#4582)

[issue32159] Remove tools for CVS and Subversion

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: New changeset fe2d5babba5d26de2093b6518316b268488187be by Victor Stinner in branch 'master': bpo-32159: Remove tools for CVS and Subversion (#4615) https://github.com/python/cpython/commit/fe2d5babba5d26de2093b6518316b268488187be

[issue32159] Remove tools for CVS and Subversion

2017-11-28 Thread STINNER Victor
STINNER Victor added the comment: > Are you sure that these scripts are not used outside of CPython? How would someone use it? There are only part of the code base, they are not installed on the system (by "make install"). If someone uses these scripts on another

  1   2   >