[issue30767] logging must check exc_info correctly

2017-10-12 Thread Matthew Patton
Matthew Patton added the comment: Additionally (probably should have separate PR) the _checkLevel was full of holes. First, it's allowing any Integer which if you're claiming to "check" things is rather silly. At least bounds-check it to GE to NOTSET and LE to CRITICAL (or MAX or something ha

[issue31771] tkinter geometry string +- when window ovelaps left or top of screen

2017-10-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Tkinter is just a wrapper around the Tk library. It returns what Tk returns. See Tk documentation: https://www.tcl.tk/man/tcl8.6/TkCmd/winfo.htm#M15 https://www.tcl.tk/man/tcl8.6/TkCmd/wm.htm#M42 If you want to improve Tkinter documentation, patches are wel

[issue31771] tkinter geometry string +- when window ovelaps left or top of screen

2017-10-12 Thread Peter J
New submission from Peter J : the root.geometry() top-level window method returns strings like "212x128+-9+-8" when the window is located in the top left corner. The documentation only describes geometry strings containing + or - location coordinates. If this is correct behaviour, the document

[issue30767] logging must check exc_info correctly

2017-10-12 Thread Matthew Patton
Matthew Patton added the comment: "exc_info which, if it does not evaluate as false", so we provide '1' or 'True'. The IF passes and immediately the formatter tries to dereference it blindly assuming it's Tuple and throws an Exception. Either the Formatter needs to guard itself (best) or the

[issue28647] python --help: -u is misdocumented as binary mode

2017-10-12 Thread STINNER Victor
STINNER Victor added the comment: Serhiy: "(...) I think it is more correct to say that stdin is always unbuffered in Python 3." I disagree. Technically, sys.stdin.read(1) reads up to 1024 bytes from the file descriptor 0. For me, "unbuffered read" means that read(1) reads a single byte. Exp

[issue25588] Run test suite from IDLE idlelib.run subprocess

2017-10-12 Thread STINNER Victor
STINNER Victor added the comment: Serhiy: "If some tests are failed on IDLE I would prefer to fix or skip only these tests." Ok, go ahead. There are many failing tests :-) -- ___ Python tracker

[issue31732] Add TRACE level to the logging module

2017-10-12 Thread pmpp
pmpp added the comment: As a dumb user I vote in favor of this on the ground that five levels is not sufficient for a long and that the need for finer distinctions already arose for me in practice. Till i overcame the mental cost to think, learn and *find time* on how to make a finer level o

[issue28647] python --help: -u is misdocumented as binary mode

2017-10-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: In Python 2 there is an internal buffering in xreadlines(), readlines() and file-object iterators. You need to enter many lines first that the program get the first of them. And -u doesn't help. But in Python 3 the program gets the input right as it becomes

[issue25588] Run test suite from IDLE idlelib.run subprocess

2017-10-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think it would be nice to make testing so flexible as possible. This would help to get rid of unintended assumptions. If some tests are failed on IDLE I would prefer to fix or skip only these tests. -- ___ Pyth

[issue31732] Add TRACE level to the logging module

2017-10-12 Thread STINNER Victor
STINNER Victor added the comment: Raymond Hettinger: "... the need for finer distinctions almost never arises in practice" I gave a list of 10 projects which are alreading using widely the 6th TRACE level. In this list, I consider that OpenStack and SaltStack are two big and serious project

[issue31761] regrtest: faulthandler.enable() fails with io.UnsupportedOperation: fileno when run from IDLE

2017-10-12 Thread STINNER Victor
STINNER Victor added the comment: > "If you don’t have easy access to a command line, you can run the test suite > from a Python or IDLE shell: The devguide is wrong. You should not run the Python test suite in IDLE. It doesn't work and many tests fail just because of IDLE. Please run the te

[issue25588] Run test suite from IDLE idlelib.run subprocess

2017-10-12 Thread STINNER Victor
STINNER Victor added the comment: I proposed PR 3962 to fix a few issues in regrtest when sys.stdout and sys.stderr have to file descriptor. I'm not sure that we should promote running tests with unusual sys.stdout and sys.stderr, since many tests fail in that case. That's why I chose to not

[issue25588] Run test suite from IDLE idlelib.run subprocess

2017-10-12 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch pull_requests: +3940 stage: needs patch -> patch review ___ Python tracker ___ ___ Pyt

[issue13802] IDLE font settings: use multiple character sets in examples

2017-10-12 Thread Dong-hee Na
Dong-hee Na added the comment: '가냐더려모뵤수유즈치캐턔페혜' is better than '가나다라마바사아차카파타하' -- ___ Python tracker ___ ___ Python-bugs-list mailin

[issue31769] configure includes user CFLAGS when detecting pthreads support

2017-10-12 Thread Chi Hsuan Yen
Change by Chi Hsuan Yen : -- nosy: +Chi Hsuan Yen ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail

[issue13802] IDLE font settings: use multiple character sets in examples

2017-10-12 Thread Dong-hee Na
Dong-hee Na added the comment: Louie Lu Thanks for the cc. In Korea, 'ᅡᅦᅩᆨᆫ가결걵곴극' are not recommended characters sequence. This sequence is not fully cover Korean characters. FYI, MS Windows default font preview sequence is '다람쥐 헌 쳇바퀴에 타고파' Google chrome preview sequence is '정 참판 양반댁 규수 큰

[issue31761] regrtest: faulthandler.enable() fails with io.UnsupportedOperation: fileno when run from IDLE

2017-10-12 Thread STINNER Victor
Change by STINNER Victor : -- components: +Tests -Documentation title: Possible error in devguide part about tests -> regrtest: faulthandler.enable() fails with io.UnsupportedOperation: fileno when run from IDLE ___ Python tracker

[issue31753] Unnecessary closure in ast.literal_eval

2017-10-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I prefer the existing code too. But I'm surprised that this change has a measurable effects at all. I thought that creating a closure is cheaper. Of course it is much faster than creating a class. Maybe it is worth to spend some time for optimizing closure

[issue31770] crash and refleaks when calling sqlite3.Cursor.__init__() more than once

2017-10-12 Thread STINNER Victor
Change by STINNER Victor : -- nosy: +haypo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python

[issue31770] crash and refleaks when calling sqlite3.Cursor.__init__() more than once

2017-10-12 Thread Oren Milman
New submission from Oren Milman : The following code crashes: import sqlite3 import weakref def callback(*args): pass connection = sqlite3.connect(":memory:") cursor = sqlite3.Cursor(connection) ref = weakref.ref(cursor, callback) cursor.__init__(connection) del cursor del ref IIUC, this is

[issue13802] IDLE font settings: use multiple character sets in examples

2017-10-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I suggest to make the sample text editable: self.font_sample = Text(frame_sample, font=temp_font, width=20) self.font_sample.insert(END, sample) This will allow a user to test fonts in any perspective. -- ___

[issue31763] Add NOTICE level to the logging module

2017-10-12 Thread Raymond Hettinger
Raymond Hettinger added the comment: As mentioned in the other tracker item, I'm against adding another level. While it might serve an exotic need, I think most users would be worse off having to learn and think about yet another level of distinction. The mental costs would be on going. FW

[issue30767] logging must check exc_info correctly

2017-10-12 Thread Raymond Hettinger
Raymond Hettinger added the comment: I agree that this should be closed. -- nosy: +rhettinger stage: patch review -> resolved status: pending -> closed ___ Python tracker ___ _

[issue28647] python --help: -u is misdocumented as binary mode

2017-10-12 Thread Berker Peksag
Berker Peksag added the comment: I think it's better to be explicit and mention 'stdin' in this case. Plus, "stdin is always buffered" is quite short so potential of creating noise is quite minimal IMO. (FYI, I asked this question on GitHub: https://github.com/python/cpython/pull/3961#issuec

[issue31753] Unnecessary closure in ast.literal_eval

2017-10-12 Thread Raymond Hettinger
Raymond Hettinger added the comment: I prefer the existing code and think this shouldn't be changed. -- nosy: +rhettinger ___ Python tracker ___ ___

[issue31732] Add TRACE level to the logging module

2017-10-12 Thread Raymond Hettinger
Raymond Hettinger added the comment: I vote against this on the ground that five levels have sufficed for a long and that the need for finer distinctions almost never arises in practice. There would be an ongoing mental cost to making users learn and think about finer levels of distinction.

[issue31741] backports import path can not be overridden in Windows (Linux works fine)

2017-10-12 Thread Paul Moore
Paul Moore added the comment: Also, one of the packages installed creates a file configparser-3.5.0-py2.7-nspkg.pth This has some very suspicious looking content: import sys, types, os;has_mfs = sys.version_info > (3, 5);p = os.path.join(sys._getframe(1).f_locals['sitedir'], *('backports',))

[issue13802] IDLE font settings: use multiple character sets in examples

2017-10-12 Thread Louie Lu
Louie Lu added the comment: PR 3960 display on my Linux works well, and the combination of the Chinese characters has no political controversial. But it is lack of simplify characters, the only one is '汉', others are all traditional characters (or they are same in simp. and trad.). For Japan

[issue28647] python --help: -u is misdocumented as binary mode

2017-10-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The -u option doesn't affect the buffering of stdin. Is it worth to document this explicitly? Or it just adds a noise? Maybe remove this from the help and manpage but add in the RST documentation? -- ___ Python t

[issue13802] IDLE font settings: use multiple character sets in examples

2017-10-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think empty lines and headers are not needed. They just increase the size of the dialog window, it may be too large for low resolution screens. The standard font chooser on Windows uses the following sets for Unicode-aware fonts: Western, Cyrillic, Hebrew

[issue30767] logging must check exc_info correctly

2017-10-12 Thread Vinay Sajip
Vinay Sajip added the comment: This is not an issue that needs fixing; the current behaviour is by design. The documentation states about exc_info: "There are two keyword arguments in kwargs which are inspected: exc_info which, if it does not evaluate as false, causes exception information to

<    1   2