[issue45671] str(CancelledError()) is empty

2021-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Then you would get >>> raise asyncio.CancelledError Traceback (most recent call last): File "", line 1, in asyncio.exceptions.CancelledError: CancelledError instead of >>> raise asyncio.CancelledError Traceback (most recent

[issue45669] An 'ascii_alphanumerics' variable is missing in the 'strings' lib

2021-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I was also against this feature. My reasons: 1. There will be not much benefit. ascii_alphanumerics is too long, so there is no much saving of typing. There is larger chance of typo. You will be not able to use it for several years, until support of

[issue45679] typing.Literal[True] is implicitly converted to typing.Literal[1]

2021-10-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I agree. lru_cache(typed=True) itself should not look into iterable internals. It would be not only slow, but a change of semantic. The simplest way to solve this issue is to remove caching of __getitem__(). The more sophisticated way is to move caching

[issue45679] typing.Literal[True] is implicitly converted to typing.Literal[1]

2021-10-30 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +27602 pull_request: https://github.com/python/cpython/pull/29334 ___ Python tracker <https://bugs.python.org/issue45

[issue45666] Warning: "'swprintf' : format string '%s' requires an argument of type 'unsigned short *', but variadic argument 1 has type 'const char *'"

2021-10-31 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: >From the man page: S (Not in C99 or C11, but in SUSv2, SUSv3, and SUSv4.) Synonym for ls. Don't use. -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org

[issue45679] typing.Literal[True] is implicitly converted to typing.Literal[1]

2021-10-31 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 634984d7dbdd91e0a51a793eed4d870e139ae1e0 by Serhiy Storchaka in branch 'main': bpo-45679: Fix caching of multi-value typing.Literal (GH-29334) https://github.com/python/cpython/commit/634984d7dbdd91e0a51a793eed4d87

[issue45679] typing.Literal[True] is implicitly converted to typing.Literal[1]

2021-10-31 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +27607 pull_request: https://github.com/python/cpython/pull/29342 ___ Python tracker <https://bugs.python.org/issue45

[issue10572] Move test sub-packages to Lib/test

2021-11-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Do we need Lib/test/test_sqlite3/__init__.py? Would not tests in package be loaded automatically? -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue10

[issue45687] Infinite recursion in Pickler.persistent_id

2021-11-02 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- components: +Interpreter Core nosy: +serhiy.storchaka versions: +Python 3.11 -Python 3.7, Python 3.8 ___ Python tracker <https://bugs.python.org/issue45

[issue45692] IDLE: define word/id chars in one place.

2021-11-02 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This set is mostly outdated. In Python 2 it was a set of characters composing identifiers, but in Python 3 identifiers can contain non-ASCII characters. -- nosy: +serhiy.storchaka ___ Python tracker <ht

[issue45692] IDLE: define word/id chars in one place.

2021-11-02 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Complete sets of characters which can be used in identifiers are too large: >>> allchars = ''.join(map(chr, range(0x11))) >>> identstartchars = ''.join(c for c in allchars if c.isidentifier()) >>> identcont

[issue45692] IDLE: define word/id chars in one place.

2021-11-02 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This in an interesting problem. I am going to work on it at the next weekends. -- ___ Python tracker <https://bugs.python.org/issue45

[issue45692] IDLE: define word/id chars in one place.

2021-11-03 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +27639 stage: test needed -> patch review pull_request: https://github.com/python/cpython/pull/29381 ___ Python tracker <https://bugs.python.org/issu

[issue45697] PyType_IsSubtype is doing excessive work in the common case

2021-11-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The PyObject_TypeCheck() macro is used in performance critical cases. If it is not the case the PyType_IsSubtype() function can be used. Adding yet check in PyType_IsSubtype() will slow down more performance sensitive cases in which PyObject_TypeCheck

[issue45698] Error on importing getopt

2021-11-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What error? -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue45698> ___ ___ Python-bugs-list m

[issue45698] Error on importing getopt

2021-11-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Could you please provide an output as a text? -- ___ Python tracker <https://bugs.python.org/issue45698> ___ ___ Python-bug

[issue45698] Error on importing getopt

2021-11-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It looks strange. The line containing "function (including the special meanings of arguments of the form `-'" is a part of a multiline string literal, so there should not be such error. And it is line 4, not line 3 as in

[issue45672] Mutation tests results of typing.py

2021-11-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What is the problem actually? -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue45672> ___ ___

[issue41105] Add some extra content check in configure process for some empty header file who has been deprecated by glibc

2021-11-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Rather of using AC_COMPILE_IFELSE() in configure.ac, would not be easier to use #ifdef in the C file? -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue41

[issue45697] PyType_IsSubtype is doing excessive work in the common case

2021-11-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Creating a new type takes microseconds, and using PyObject_TypeCheck() instead of PyType_IsSubtype() can save nanoseconds. So, while this replacement looks harmless, its effect can hardly be measured even in microbenchmarks

[issue45697] PyType_IsSubtype is doing excessive work in the common case

2021-11-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 2c045bd5673d56c3fdde7536da9df1c7d6f270f0 by Itamar Ostricher in branch 'main': bpo-45697: Use PyObject_TypeCheck in type_call (GH-29392) https://github.com/python/cpython/commit/2c045bd5673d56c3fdde7536da9df1

[issue45697] PyType_IsSubtype is doing excessive work in the common case

2021-11-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your contribution Itamar. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue45672] Mutation tests results of typing.py

2021-11-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The tests are passed because this modification does not affect behavior, it just makes the code slightly less efficient. Replacing i+1 with i just adds one iteration: b = bases[i] # == self if isinstance(b, _BaseGenericAlias) and b is not self

[issue27313] test case failures in test_widgets.ComboboxTest.of test_ttk_guionly on OS X with Cocoa Tk 8.5.18

2021-11-05 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +27678 pull_request: https://github.com/python/cpython/pull/29425 ___ Python tracker <https://bugs.python.org/issue27

[issue45708] PEP 515-style formatting with underscores does not seem to work for Decimal

2021-11-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This is a duplicate of issue43624. It was also discussed in Discuss. -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> Add underscore as a decimal separator for strin

[issue27313] test case failures in test_widgets.ComboboxTest.of test_ttk_guionly on OS X with Cocoa Tk 8.5.18

2021-11-05 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: -27678 ___ Python tracker <https://bugs.python.org/issue27313> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue45160] ttk.OptionMenu radiobuttons change variable value twice

2021-11-05 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +27681 pull_request: https://github.com/python/cpython/pull/29425 ___ Python tracker <https://bugs.python.org/issue45

[issue27313] test case failures in test_widgets.ComboboxTest.of test_ttk_guionly on OS X with Cocoa Tk 8.5.18

2021-11-05 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +27682 pull_request: https://github.com/python/cpython/pull/29425 ___ Python tracker <https://bugs.python.org/issue27

[issue45243] [sqlite3] add support for changing connection limits

2021-11-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 3d42cd9461e60c7427f3793f640cd975fbd99289 by Erlend Egeberg Aasland in branch 'main': bpo-45243: Use connection limits to simplify `sqlite3` tests (GH-29356) https://github.com/python/cpython/commit/3d42cd9461e60c7427f3793f640cd9

[issue45735] Promise the long-time truth that `args=list` works

2021-11-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: There is a difference if you modify the arguments list after creating a thread. args = [1] t = threading.Thread(target=access, args=args) args[0] = 2 t.start() Would it call access(1) or access(2)? -- nosy: +serhiy.storchaka

[issue45708] PEP 515-style formatting with underscores does not seem to work for Decimal

2021-11-06 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: duplicate -> stage: resolved -> status: closed -> open superseder: Add underscore as a decimal separator for string formatting -> ___ Python tracker <https://bugs.python

[issue45739] The Python implementation of Decimal does not support the "N" format

2021-11-06 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : The C implementation supports both formats "n" and "N". The Python implementation only supports format "n". >>> from decimal import Decimal >>> format(Decimal('1e100'), 'n') '1e+1

[issue45754] [sqlite3] SQLITE_LIMIT_LENGTH is incorrectly used to check statement length

2021-11-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: In alternative 1 we control the type and the message of exception. In alternative 3 we left this to the SQLite3 engine. It is difficult to keep consistency in alternative 2, errors raised for sizes less and larger than INT_MAX can be different. I think

[issue23041] csv needs more quoting rules

2021-11-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The quoting style affects not only the CSV formatting, but also the CSV parsing. How QUOTE_NOTNULL and QUOTE_STRINGS will affect parsing? -- ___ Python tracker <https://bugs.python.org/issue23

[issue45791] __instancecheck__ being checked of type(cls) instead of cls

2021-11-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think that the code is correct, and the documentation is not complete. As in most (but not all) cases of dunder methods it is looked up in a class, ignoring instance attributes. -- nosy: +serhiy.storchaka

[issue37295] Possible optimizations for math.comb()

2021-11-12 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- versions: +Python 3.11 -Python 3.8, Python 3.9 ___ Python tracker <https://bugs.python.org/issue37295> ___ ___ Python-bugs-list m

[issue45791] __instancecheck__ being checked on type(cls) instead of cls

2021-11-12 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +27789 stage: -> patch review pull_request: https://github.com/python/cpython/pull/29540 ___ Python tracker <https://bugs.python.org/issu

[issue45791] __instancecheck__ being checked on type(cls) instead of cls

2021-11-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Failed tests: == FAIL: test_isinstance_with_or_union (test.test_isinstance.TestIsInstanceIsSubclass) -- Traceback (most

[issue45791] __instancecheck__ being checked on type(cls) instead of cls

2021-11-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Most of failed tests are related to typing, but there is a purposed test for __instancecheck__ and __subclasscheck__ bypassing __getattr__ and __getattribute__ (test.test_descr.ClassPropertiesAndMethods.test_special_method_lookup

[issue45791] __instancecheck__ being checked on type(cls) instead of cls

2021-11-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: All typing related tests are fixed by updating types.GenericAlias.__getattribute__. So the only thing is left to make all tests passed is removing some special methods tests. The lookup of __instancecheck__ and __subclasscheck__ was changed by Benjamin

[issue45846] Incorrect name capitalisation in faq/programming

2021-11-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: But in this case it starts a sentence. -- nosy: +gvanrossum, serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue45

[issue45846] Incorrect name capitalisation in faq/programming

2021-11-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset bc2bc0dbdb52498d009f9f9771452e6aa4faff2b by JMcB in branch 'main': bpo-45846: Fix capitalisation of Van Rossum at the start of sentence (GH-29641) https://github.com/python/cpython/commit/bc2bc0dbdb52498d009f9f9771452e

[issue45832] Misleading membersip expression documentation

2021-11-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think there is a bug in either numpy.timedelta64.__hash__ or panda.Timedelta.__hash__. Please report it to corresponding libraries. It is not related to the documentation of membership test. If you have different hashes for equal objects most dict and

[issue45843] Optimizing LOAD_CONST followed by COMPARE_OP (or IS_OP)

2021-11-21 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Why anybody needs to write 255581293 > 12938373? We try to keep the compiler code maintenable and only implement optimizations which have the largest effect. PR 29639 adds around 200 lines of complex code and I do not see the bene

[issue45846] Incorrect name capitalisation in faq/programming

2021-11-21 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your report and PR JMcB. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue45853] Misspelled _IGNORED_ERROS in Lib/pathlib.py

2021-11-21 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: If it is only used in a single place in the module would not be better to inline it? -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue45

[issue45853] Misspelled _IGNORED_ERROS in Lib/pathlib.py

2021-11-21 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: BTW, is not the correct name _IGNORED_ERRNOS? -- ___ Python tracker <https://bugs.python.org/issue45853> ___ ___ Python-bug

[issue45509] Gzip header corruption not properly checked.

2021-11-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think it is good idea, although we may get reports about regressions in 3.11 when Python will start to reject GZIP files which was successfully read before. But before merging this I want to know: 1. How much overhead does it add for reading files with

[issue45865] Old syntax in unittest

2021-11-22 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Concur with Eric. -- nosy: +serhiy.storchaka resolution: -> rejected stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue45843] Optimizing constant comparisons/contains

2021-11-22 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> rejected stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue22067] time_test fails after strptime()

2021-11-23 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Yes, it was 2.7-only issue. Thank you Irit for checking and closing outdated issues. -- resolution: works for me -> out of date stage: -> resolved status: pending -> closed ___ Python tracke

[issue45878] Use `self.assertRaises` instead of `try/except` in `ctypes/test_functions.py::test_mro`

2021-11-23 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset b48ac6fe38b2fca9963b097c04cdecfc6083104e by Nikita Sobolev in branch 'main': bpo-45878: convert `try/except` to `self.assertRaises` in `Lib/ctypes/test/test_functions.py` (GH-29721) https://github.com/python/cpyt

[issue45894] exception lost when loop.stop() in finally

2021-11-24 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It is not related to loop.stop() and asyncio in general. It is the return statement which eats the exception. Simpler example: >>> def f(): ... try: ... 1/0 ... finally: ... return 42 ... >>> f() 42 Return (

[issue45907] Optimize literal comparisons and contains

2021-11-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > It doesn't seem to make sense why other operations on literals are optimized > but these particular ones aren't optimized (much). The existing optimizer optimizes the following cases (note that the parser does not produce negative or

[issue45908] dict.fromkeys insertion order

2021-11-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What else can it be? dict.fromkeys() adds keys in the order of obtaining them, and it obtains them by iterating its argument. If we need a special note here, we need a special note for list(), tuple(), filter(), enumerate() and all other functions which

[issue45902] Bytes and bytesarrays can be sorted with a much faster count sort.

2021-11-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I concur with Raymond. It is difficult to find any use case for sorting bytes objects (I cannot find any). As for using radix sort in list.sort() in special case of small integer keys, it is difficult to implement, because we should preserve the initial

[issue24040] plistlib assumes dict_type is descendent of dict

2021-11-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The patch LGTM, and I have nothing to add. Ronald, do you mind to create a PR. -- assignee: -> ronaldoussoren nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issu

[issue45911] SystemError occured while running an extention

2021-11-28 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue45739] The Python implementation of Decimal does not support the "N" format

2021-11-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I have no strong opinion. I found the discrepancy when reviewed one of Mark's PRs. I was surprised because I did not know that "N" is supported. On other hand, there are reasons for supporting upper-case variant of "n" if we suppo

[issue45922] Many method, function, built-in... are not clickable and should be

2021-11-29 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It is a good idea in general. Please go ahead, I am sure that the PR will be accepted. But keep in mind that not always additional links make the documentation better. The rule of tumb is to not add multiple links to the same entity in one paragraph. In

[issue45739] The Python implementation of Decimal does not support the "N" format

2021-11-29 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: You are right about an uppercase converter. I forget this. I withdraw this proposition. It seems that even if we add support of "N" to all numeric formatting it will not cover all use cases. "n" is a locale specific variant of &qu

[issue13236] unittest needs more flush calls

2021-11-30 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch nosy: +serhiy.storchaka nosy_count: 7.0 -> 8.0 pull_requests: +28091 stage: test needed -> patch review pull_request: https://github.com/python/cpython/pull/29864 ___ Python tracker

[issue13236] unittest needs more flush calls

2021-11-30 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- versions: +Python 3.10, Python 3.9 ___ Python tracker <https://bugs.python.org/issue13236> ___ ___ Python-bugs-list mailin

[issue13236] unittest needs more flush calls

2021-11-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I do not remember details, but I encountered this issue (maybe when run tests in subprocesses?). -- ___ Python tracker <https://bugs.python.org/issue13

[issue44884] logging Formatter behavior when using msecs and braces : '{'

2021-11-30 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- nosy: +vinay.sajip ___ Python tracker <https://bugs.python.org/issue44884> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue41270] NamedTemporaryFile is not its own iterator.

2021-11-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Biopython uses next() without iter(), and there is no guarantee that it should work. -- nosy: +brett.cannon, pitrou, serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue41

[issue45944] Avoid calling isatty() for most open() calls

2021-12-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What if change FileIO.isatty() instead? If make it returning False without invoking a system call if the file size is non-zero it will eliminate the need to expose _size. -- nosy: +serhiy.storchaka ___ Python

[issue45944] Avoid calling isatty() for most open() calls

2021-12-01 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- nosy: +benjamin.peterson, pitrou, stutzbach versions: -Python 3.10, Python 3.6, Python 3.7, Python 3.8, Python 3.9 ___ Python tracker <https://bugs.python.org/issue45

[issue43153] tempfile seems to treat a file as a directory when processing an exception in the onerror()

2021-12-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I agree with Andrei. I'll test this approach on Windows. -- ___ Python tracker <https://bugs.python.org/issue43153> ___ ___

[issue45939] PyErr_SetObject documentation lacks mention of reference counting

2021-12-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I concur with Ronald. If we explicitly document that PyErr_SetObject() does not steal reference we would need to document it for every parameter of every function. It would make the documentation worse because it would be more difficult to distinguish

[issue45957] _tkinter.TclError: expected boolean value but got ""

2021-12-02 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What is the result of root.tk.call('wm', 'overrideredirect', root._w, True) ? Is it not an empty string? -- nosy: +serhiy.storchaka ___ Python tracker <https://bug

[issue11455] issue a warning when populating a CPython type dict with non-string keys

2021-12-02 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Why not raise an error if it contradicts language spec? -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue11

[issue45957] _tkinter.TclError: expected boolean value but got ""

2021-12-02 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you Ali. It confirms my guess, but it is still not clear why we get a Tcl_Obj rather of None or empty string. Please examine what is the output of the following code: res = root.tk.call('wm', 'overrideredirect', root._w, True)

[issue27946] elementtree calls PyDict_GetItem without owning a reference to the dict

2021-12-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Concur with Irit. We should patch the caller of PyDict_GetItem, not PyDict_GetItem. -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue27

[issue45957] _tkinter.TclError: expected boolean value but got ""

2021-12-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It looks like a bug in Tk 8.6.11. It is expected that the implementation of "wm overrideredirect" returns an empty string if pass the boolean argument. The returned value is an empty string, but its type is not cleared. Seems it keeps the type o

[issue45979] Fix Tkinter tests with old Tk

2021-12-04 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : Some recently added tests are not compatible with old Tk versions. I have build all 8.5 and 8.6 versions and build and test Tkinter against them. The proposed PR makes tests passes on Tk versions 8.5.4 to 8.5.19 and 8.6.0 to 8.6.12. There are some

[issue45979] Fix Tkinter tests with old Tk

2021-12-04 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +28138 stage: -> patch review pull_request: https://github.com/python/cpython/pull/29913 ___ Python tracker <https://bugs.python.org/issu

[issue45979] Fix Tkinter tests with old Tk

2021-12-04 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- nosy: +epaine ___ Python tracker <https://bugs.python.org/issue45979> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue27946] elementtree calls PyDict_GetItem without owning a reference to the dict

2021-12-04 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +28140 stage: -> patch review pull_request: https://github.com/python/cpython/pull/29915 ___ Python tracker <https://bugs.python.org/issu

[issue27946] elementtree calls PyDict_GetItem without owning a reference to the dict

2021-12-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The issue is no longer reproduced by the original test because of the cache for dict key tables. But it is not gone, and can be reproduced with modified test. There may be many similar bugs in the Python core end extensions. Adding incref/decref in

[issue13236] unittest needs more flush calls

2021-12-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset f42a06ba279c916fb67289e47f9bc60dc5dee4ee by Serhiy Storchaka in branch 'main': bpo-13236: Flush the output stream more often in unittest (GH-29864) https://github.com/python/cpython/commit/f42a06ba279c916fb67289e47f9bc6

[issue27946] elementtree calls PyDict_GetItem without owning a reference to the dict

2021-12-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset d15cdb2f32f572ce56d7120135da24b9fdce4c99 by Serhiy Storchaka in branch 'main': bpo-27946: Fix possible crash in ElementTree.Element (GH-29915) https://github.com/python/cpython/commit/d15cdb2f32f572ce56d7120135da24

[issue27946] elementtree calls PyDict_GetItem without owning a reference to the dict

2021-12-05 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue45987] os.chdir in unittest's test case causes RecursionError on Windows

2021-12-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What is (snip)? -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue45987> ___ ___ Python-bugs-list m

[issue45934] python curses newterm implementation

2021-12-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What is it about? The first message is by Guido, but not this message nor the title does not give me any idea what is it about. -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue45

[issue37295] Possible optimizations for math.comb()

2021-12-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 60c320c38e4e95877cde0b1d8562ebd6bc02ac61 by Serhiy Storchaka in branch 'main': bpo-37295: Optimize math.comb() and math.perm() (GH-29090) https://github.com/python/cpython/commit/60c320c38e4e95877cde0b1d8562eb

[issue45662] Incorrect repr of InitVar of a type alias

2021-12-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 1fd4de5bddbbf2a97cdbac4d298c89e1156bdc6c by Serhiy Storchaka in branch 'main': bpo-45662: Fix the repr of InitVar with a type alias to the built-in class (GH-29291) https://github.com/python/cpyt

[issue45663] is_dataclass() does not work for dataclasses which are subclasses of types.GenericAlias

2021-12-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 446be166861b2f08f87f74018113dd98ca5fca02 by Serhiy Storchaka in branch 'main': bpo-45663: Fix is_dataclass() for dataclasses which are subclasses of types.GenericAlias (GH-29294) https://github.com/python/cpyt

[issue45664] resolve_bases() and new_class() do not work with type alias of a built-in type

2021-12-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 2b318ce1c988b7b6e3caf293d55f289e066b6e0f by Serhiy Storchaka in branch 'main': bpo-45664: Fix resolve_bases() and new_class() for GenericAlias instance as a base (GH-29298) https://github.com/python/cpyt

[issue45840] Improve cross-references in the data model documentation

2021-12-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset c0521fe49fd75e794a38a216813658ab40185834 by Alex Waygood in branch 'main': bpo-45840: Improve cross-references in the data model documentation (GH-29633) https://github.com/python/cpython/commit/c0521fe49fd75e794a38a216813658

[issue13236] unittest needs more flush calls

2021-12-05 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +28153 pull_request: https://github.com/python/cpython/pull/29929 ___ Python tracker <https://bugs.python.org/issue13

[issue45995] string formatting: normalize negative zero

2021-12-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: To normalize negative 0.0 to 0.0 you can just add 0.0. It will work with any method of converting floats to string, there is no need to change all formatting specifications. >>> x = -0.0 >>> x -0.0 >>> x + 0.0 0.0 -

[issue45934] python curses newterm implementation

2021-12-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you Guido for clarification. I have found that post: https://mail.python.org/archives/list/core-mentors...@python.org/thread/YGSMPKP7G3HO73ISEQZFAWPPGCOA3JYZ/ I agree that it is worth to implement newterm. In particular it would be useful in tests

[issue45934] python curses newterm implementation

2021-12-06 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- assignee: -> serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue45934> ___ ___ Python-bugs-list mailing list Un

[issue45996] Worse error from asynccontextmanager in Python 3.10

2021-12-06 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- nosy: +graingert, lukasz.langa, ncoghlan ___ Python tracker <https://bugs.python.org/issue45996> ___ ___ Python-bugs-list mailin

[issue45929] extend json.tool --json-lines to ignore empty rows

2021-12-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Both JSON Lines (https://jsonlines.org/) and Newline Delimited JSON (http://ndjson.org/) formats require that Each Line is a Valid JSON Value. If you want to ignore empty lines you can filter them out with `sed /^$/d`. -- nosy: +serhiy.storchaka

[issue46000] NetBSD curses compatibility

2021-12-07 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue46000> ___ ___ Python-bugs-list mailing list Unsub

[issue45995] string formatting: normalize negative zero

2021-12-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Well, it makes sense for negative zero produced by rounding. But if we add a special support for this case, it would be useful to have some control on the type of rounding. Currently floats are rounded to the nearest decimal number, but in some cases it

[issue46001] JSON module documentation mentions OverflowError for case that raises RecursionError

2021-12-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 8db06528cacc94e67eb1fb2e4c2acc061a515671 by James Gerity in branch 'main': bpo-46001: Change OverflowError to RecursionError in JSON library docstrings (GH-29943) https://github.com/python/cpyt

[issue46001] JSON module documentation mentions OverflowError for case that raises RecursionError

2021-12-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your contribution James! -- versions: +Python 3.10, Python 3.9 ___ Python tracker <https://bugs.python.org/issue46

<    17   18   19   20   21   22   23   24   25   26   >