[issue38715] Regression in compileall ddir parameter when recursing

2019-11-06 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue38715> ___ ___ Python-bugs-list mailing list Unsub

[issue38706] What should the error message in the exception raised by assertTrue and assertFalse be?

2019-11-06 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +16583 stage: -> patch review pull_request: https://github.com/python/cpython/pull/17073 ___ Python tracker <https://bugs.python.org/issu

[issue38717] csv DictWriter's internal _dict_to_list raise error unsupported operand

2019-11-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I guess you try to write not a dict, but an object whose keys() method returns a list. -- nosy: +rhettinger, serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue38

[issue38706] What should the error message in the exception raised by assertTrue and assertFalse be?

2019-11-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: If there is anything wrong with terms "true" and "false" (I don't know), we should fix this not only in one particular place, but everywhere. If there is nothing wrong with them, there is nothing to "improve". If this

[issue36906] Compile time textwrap.dedent() equivalent for str or bytes literals

2019-11-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think it would be better to use use backtick quotes for f-strings instead of the f prefix. This would stress the special nature of f-strings (they are not literals, but expressions). But there was strong opposition to using backticks anywhere in Python

[issue36906] Compile time textwrap.dedent() equivalent for str or bytes literals

2019-11-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The user expects what they read in the documentation of what they learn in other programming languages. If we update the documentation their expectation will change. As for other programming languages, Bash has an option for stripping all leading tab

[issue36906] Compile time textwrap.dedent() equivalent for str or bytes literals

2019-11-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Julia syntax looks well thought out, so I suggest to borrow it. -- ___ Python tracker <https://bugs.python.org/issue36

[issue38706] What should the error message in the exception raised by assertTrue and assertFalse be?

2019-11-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: In some cases "a true value" and "a false value" are used in the documentation. But in most cases it is just "true" and "false". -- ___ Python trac

[issue38738] Fix formatting of True and False

2019-11-07 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : The proposed PR fixes some issues with True and False in the documentation: * "Return true/false" is replaced with "Return ``True``/``False``" if the function actually returns a bool. * Fixed formatting of some True and False litera

[issue38738] Fix formatting of True and False

2019-11-07 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +16593 stage: -> patch review pull_request: https://github.com/python/cpython/pull/17083 ___ Python tracker <https://bugs.python.org/issu

[issue38706] What should the error message in the exception raised by assertTrue and assertFalse be?

2019-11-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: See also issue38738. -- ___ Python tracker <https://bugs.python.org/issue38706> ___ ___ Python-bugs-list mailing list Unsub

[issue22367] Add open_file_descriptor parameter to fcntl.lockf() (use the new F_OFD_SETLK flag)

2019-11-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset befa032d8869e0fab4732d910f3887642879d644 by Serhiy Storchaka (Dong-hee Na) in branch 'master': bpo-22367: Add tests for fcntl.lockf(). (GH-17010) https://github.com/python/cpython/commit/befa032d8869e0fab4732d910f3887

[issue38740] Line count mis match between open() vs sys.stdin api calls

2019-11-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Try to add newline="\n" in open(). -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.o

[issue43471] Fails to import bz2 on Ubuntu

2021-03-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: You are likely did not have headers for bz2 library installed. Read thoughtfully the output of ./configure and make. See also https://devguide.python.org/setup/#install-dependencies . -- nosy: +serhiy.storchaka status: pending -> o

[issue30491] Add a lightweight mechanism for detecting un-awaited coroutine objects

2021-03-13 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The most common error is missing keyword "await" in function call. "f()" instead of "await f()". There is a way to detect this error at runtime with minimal false positive and with minimal overhead. We can add a new opcode wh

[issue43411] wm_manage fails with ttk.Frame

2021-03-13 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Minor correction: Tk does not generate names as digit sequences. Its syntax requires a name to be always specified. Past versions of Tkinter generated names as digit sequences, now it generates more readable and informative names. If we ever add

[issue26362] Approved API for creating a temporary file path

2021-03-13 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This function would increase security risks. Even if it will be documented as "This function is only purposed to generate file paths which looks similar to paths of temporary files generated by other functions in this module, but should not be use

[issue43267] [sqlite3] Redundant type checks in pysqlite_statement_bind_parameter()

2021-03-13 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I would not add such "optimization", but it is up to Berker to keep or remove it. Please create a PR for review. -- ___ Python tracker <https://bugs.python.o

[issue42917] Block stack size for frame objects should be dynamically sizable

2021-03-15 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > There are also other ideas floating about for improving memory locality > related to the frame stack, e.g. putting the stack frames in an array instead > of a linked list. Would it work with generators and c

[issue43497] SyntaxWarning for "assertion is always true, perhaps remove parentheses?" does not work with constants

2021-03-15 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What is the use case for assert with a constant? -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue43

[issue43475] Worst-case behaviour of hash collision with float NaN

2021-03-15 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What about Decimal NaN? Even if make float NaN a singleton, there will be other NaNs. And making float('nan') returning a singleton, but 1e1000 * 0 returning different NaN would cause large confusion. -- nosy: +serhiy

[issue43497] SyntaxWarning for "assertion is always true, perhaps remove parentheses?" does not work with constants

2021-03-15 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: In such case I prefer to write assert not 'reachable' It is shorter than writing False. If I want to keep an exception even with -O, I write raise AssertionError -- ___ Python track

[issue43499] Compiler warnings in building Python 3.9 on Windows

2021-03-15 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : Currently building Python 3.9 on Windows produce many compiler warnings. 3.8 and master are clean. * Warnings in the _sre module caused by the bug in MSVC (complains about automatic conversion of "void **" to "const void *").

[issue43499] Compiler warnings in building Python 3.9 on Windows

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

[issue43499] Compiler warnings in building Python 3.9 on Windows

2021-03-15 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 651fc30af7ac6138764106b87632cabca56a98bb by Serhiy Storchaka in branch '3.9': bpo-43499: Silence compiler warnings about using legacy C API on Windows (GH-24873) https://github.com/python/cpyt

[issue43499] Compiler warnings in building Python 3.9 on Windows

2021-03-16 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Ammar Askar, do you mind to backport PR 20628 to 3.9? It is the only warning left, and it seems there is a potential bug. -- ___ Python tracker <https://bugs.python.org/issue43

[issue43517] Fix false positives in circular import detection with from-imports

2021-03-16 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- nosy: +brett.cannon, eric.snow, nanjekyejoannah, ncoghlan, serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue43

[issue43526] Programmatic management of BytesWarning doesn't work for native triggers.

2021-03-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Yes, it is intended behaviour. BytesWarning is only emitted when you set a special internal flag (by the -b option). Warning filters control what happen with that warning later: be it ignored, printed, or converted to exception. In normal circumstances

[issue43499] Compiler warnings in building Python 3.9 on Windows

2021-03-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset db733761060be92915b5f5cba209dcaada88f94e by Ammar Askar in branch '3.9': [3.9] bpo-43499: Restrict co_code to be under INT_MAX in codeobject (GH-20628) (GH-24896) https://github.com/python/cpyt

[issue43499] Compiler warnings in building Python 3.9 on Windows

2021-03-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you Ammar. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue43511] tkinter with Tk 8.6.11 is slow on macOS

2021-03-17 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The result of help('modules') depends on Python version. Do you have any example which does not depend on Python version? Could you also run some pure Tcl/Tk demos to check whether the difference is in Tcl/Tk instead of the wrapper? -

[issue43535] Make str.join auto-convert inputs to strings.

2021-03-18 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It was proposed by newbies several times before. It was rejected because it would make errors to hide unnoticed. Python is dynamically but strongly typed, and it is its advantage. I am -1. -- nosy: +serhiy.storchaka

[issue43534] turtle.textinput window is not transient

2021-03-18 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +23687 pull_request: https://github.com/python/cpython/pull/24923 ___ Python tracker <https://bugs.python.org/issue43

[issue43546] "Impossible" KeyError from importlib._bootstrap acquire line 110

2021-03-18 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It looks like method _ModuleLock.acquire() was re-entered in the same thread. * Enter acquire() first time, set _blocking_on[tid]. * Trigger some callback (profiler, debugger, tracemalloc) which uses import and calls acquire() again from the same thread

[issue43535] Make str.join auto-convert inputs to strings.

2021-03-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Vedran, it is not what strong typing means. Strong typing means that '2'+3 is an error instead of '23' or 5. str.join() expects an iterable of strings. If some of items is not a string, it is a sign of programming error. I prefer

[issue29996] Use terminal width by default in pprint

2021-03-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Closing then. I'll just add my implementation in my .pythonrc.py. -- resolution: -> rejected stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.pyth

[issue29178] Adding bytes.frombuffer(byteslike) constructor

2021-03-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I am more warm to this feature now (+0). Not because it would allow to write some code shorter, but because it can be in line with other type-strict alternate constructors, like int.fromnumber() and int.parse(). But questions about parameters and

[issue43520] Make Fraction(string) handle non-ascii slashes

2021-03-20 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It would be nice to have an utility function in unicodedata to convert Unicode characters to their ASCII equivalents (if they exist). It would allow to explicitly convert all slashes to / (and all digits to 0-9) before passing string to Fraction

[issue43604] Fix tempfile.mktemp()

2021-03-23 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: You can use TemporaryDirectory. with tempfile.TemporaryDirectory() as dir: fifo_path = os.path.join(dir, "fifo") os.mkfifo(fifo_path, 0o600) ... -- nosy: +serhiy.storchaka ___ Python track

[issue43606] PySimpleGUI: initial huge window & no widgets visible

2021-03-24 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: PySimpleGUI is not a part of the stdlib. If you have problems with pure Tkinter, look if you have files .Xdefaults or .Xresources in your home directory. They can alter default look of Tk widgets. Try to remove them and test whether the problem is gone

[issue43614] Search is not beginner friendly

2021-03-24 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Ha! I just was going to open the same issue (perhaps we read the same post on Quora). I concur that it is perhaps worth to add index entries for common parameter names (args, kwargs, self, cls) and also for *args and **kwargs and add notions that such

[issue37773] ValueError: I/O operation on closed file. in ZipFile destructor

2021-03-27 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: That's what happened. Function foo creates a reference loop. It has reference to the module dict, and the dict has reference to the function. The dict has also references to BytesIO and ZipFile objects. At shutdown stage the garbage collector is c

[issue43645] xmlrpc.client.ServerProxy silently drops query string from URI

2021-03-28 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> xmlrpc.client ignores query in URI ("?action=xmlrpc2") since python-3.9 ___ Python tracker <https://b

[issue43433] xmlrpc.client ignores query in URI ("?action=xmlrpc2") since python-3.9

2021-03-28 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- assignee: -> serhiy.storchaka nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue43433> ___ ___ Python-

[issue43433] xmlrpc.client ignores query in URI ("?action=xmlrpc2") since python-3.9

2021-03-28 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +23804 pull_request: https://github.com/python/cpython/pull/25057 ___ Python tracker <https://bugs.python.org/issue43

[issue43647] Sudden crash displaying certain characters in tk widget

2021-03-28 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Looks like a duplicate of issue42225. It happens with colored fonts. In any case it is a Tk issue and it should be fixed in the latest Tk bugfix release (8.6.11). -- ___ Python tracker <https://bugs.python.

[issue42225] Tkinter hangs or crashes when displaying astral chars

2021-03-29 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: At least it is not a regression caused by support of astral characters (issue13153). -- ___ Python tracker <https://bugs.python.org/issue42

[issue43433] xmlrpc.client ignores query in URI ("?action=xmlrpc2") since python-3.9

2021-03-29 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your reports OndrejPtak and frathgeber. Indeed, the behavior change was unintended. PR 25057 tries to to restore the old behavior. Query and fragment are now preserved in the server URL. But there are still minor differences. Empty query and

[issue43655] Tkinter: Not setting _NET_WM_WINDOW_TYPE on FileDialog

2021-03-29 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you for your report and PR Patrick. I agree, it would be better to to set the "type" attribute to "dialog" for the FileDialog window. Tk does it for its dialog windows. But it is more complex. * It should be set not only for

[issue43659] AIX: test_curses crashes buildbot

2021-03-29 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset c8b5738810516df5722caf049003e9b319427bec by Michael Felt in branch 'master': bpo-43659: Fix test_curses on AIX (GH-25074) https://github.com/python/cpython/commit/c8b5738810516df5722caf049003e9b319427bec -- nosy: +serhiy

[issue43659] AIX: test_curses crashes buildbot

2021-03-29 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Minor correction. update_lines_cols() is not provided by the underlying curses library, it is a helper defined in Python wrapper. But it is optional, snd skipping test is the correct solution. Thank you. As for the core dump, could you please run the test

[issue43656] StackSummary.format fails if str(value) fails

2021-03-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Why str() is called at all? Would not be better to use repr()? -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue43

[issue43659] AIX: test_curses crashes buildbot

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

[issue43659] AIX: test_curses crashes buildbot

2021-03-30 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: fixed -> stage: resolved -> status: closed -> open ___ Python tracker <https://bugs.python.org/issue43659> ___ ___

[issue43659] AIX: test_curses crashes buildbot

2021-03-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you. I see that 7 tests are failed (test_background, test_color_attrs, test_color_content, test_getch, test_getstr, test_init_pair, test_insert_delete) and test_output_string perhaps crashes. Could you please run tests with test_insert_delete

[issue43659] AIX: test_curses crashes buildbot

2021-03-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Please also try to comment out the following line in test_output_string. Does it help? s = '\u0661\u0662\u0663\u0664' try: func(s, 3) except UnicodeE

[issue39228] traceback.FrameSummary does not handle exceptions from `repr()`

2021-03-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: __repr__() and repr() can raise exceptions. Silencing arbitrary exception is usually a bad idea. Even correctly raised code can raise exceptions such as MemoryError, RecursionError and KeybordInterrupt. For this reason I think that the proposed change

[issue43399] xml.etree.ElementTree.extend does not work with iterators when using the Python implementation

2021-03-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 51a85ddce8b336addcb61b96f04c9c5edef07296 by Alex Prengère in branch 'master': bpo-43399: Fix ElementTree.extend not working on iterators (GH-24751) https://github.com/python/cpython/commit/51a85ddce8b336addcb61b96f04c9c

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

2021-03-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Concur. Also you can add "ssl" to the list of tested names if both "c" and "m" fail on AIX. -- nosy: +serhiy.storchaka ___ Python tracker <h

[issue43399] xml.etree.ElementTree.extend does not work with iterators when using the Python implementation

2021-03-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Pinging us was the only action needed. Thank you for your contribution Alex. -- ___ Python tracker <https://bugs.python.org/issue43

[issue41461] test_pathlib assumes underlying filesystem permits creation with world-write permissions

2021-03-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: umask(0o002) looks good idea (and perhaps umask(0o026) instead of umask(0o022)). Please add also a short explanation comment. -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue41

[issue39228] traceback.FrameSummary does not handle exceptions from `repr()`

2021-03-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: See also issue43656. -- ___ Python tracker <https://bugs.python.org/issue39228> ___ ___ Python-bugs-list mailing list Unsub

[issue43655] Tkinter: Not setting _NET_WM_WINDOW_TYPE on FileDialog

2021-03-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: No, it is not ready for publishing yet. I'll try to work on it on the next weekend. Since it is a large change, there is a risk of breaking user code, so perhaps it would be worth to separate changes related to this issue which can be backp

[issue43680] Remove undocumented io.OpenWrapper and _pyio.OpenWrapper

2021-03-31 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: As for dbm.dumb, it was an attempt to make _Database._commit() working at the shutdown stage (it is indirectly called from __del__()). See issue723231. Although in Python 2 __builtin__.open != io.open, and in Python 3.0 the code already uses io.open

[issue43680] Remove undocumented io.OpenWrapper and _pyio.OpenWrapper

2021-03-31 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: OpenWrapper was added in ce3a72aec6eaa0293c397c8d0407f7afe0072b2f (issue1267) and was only used to set __builtin__.open (I suppose that at thet moment dumbdbm.py still set open as a class attribute). It is still can be set as a class attribute in user

[issue43682] Make static methods created by @staticmethod callable

2021-04-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: If make staticmethod a calllable and always wrap open, we need to change also its repr and add the __doc__ attribute (and perhaps other attributes to make it more interchangeable with the original function). Alternate option: make staticmethod(func

[issue43684] Add combined opcodes

2021-04-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: We usually rejected such propositions unless there were evidences of significant effect on performance. I myself withdrawn several my patches after analyzing statistics. What percent of opcodes will be ADD_INT in the compiled bytecode? What percent of

[issue43694] Tkinter scaling does not work on some linux systems

2021-04-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: >From "man font": FONT OPTIONS -size size The desired size of the font. If the size argument is a posi‐ tive number, it is interpreted as a size in points. If size is a negative number,

[issue43695] Improve `=` in f-strings

2021-04-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think it goes too far. It was initially designed as a simple for implementation and use feature which covers a large amount of use cases of using f-strings for debugging. You propose to add syntactically a new postfix operator which is valid only in

[issue43694] Tkinter scaling does not work on some linux systems

2021-04-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: What did you expect to get? -- ___ Python tracker <https://bugs.python.org/issue43694> ___ ___ Python-bugs-list mailin

[issue43694] Tkinter scaling does not work on some linux systems

2021-04-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The size of of the window is determined by the size of its components. The size of the label and the munu is determined by the size of the font. If font has the same size and you output the same string (or string containing characters of the same

[issue43692] Raise SyntaxError on implicit string concatentation in list

2021-04-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It is valid Python syntax, so SyntaxErorr cannot be raised. SyntaxWarning is an option, but the Python compiler only emits it if we absolutely sure that the code contains a bug (either it does not work as intended or can work differently on other

[issue43694] Tkinter scaling does not work on some linux systems

2021-04-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: AFAIK X Window uses two font systems: for bitmap fonts and for scalable fonts. If default fonts on your system are bitmap fonts, they are not scaled. -- resolution: -> not a bug stage: -> resolved status: open -&g

[issue43695] Improve `=` in f-strings

2021-04-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I think there is a slim chance of implementing similar feature in future. If once we implement pytest-like asserts, we will need to add special expression evaluator which saves all intermediate results of subexpressions and pass them to some hook

[issue41638] Error message: sqlite3.ProgrammingError: You did not supply a value for binding # might be improved

2021-04-01 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Sure. Thanks for the reminder. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue43703] xml.etree parser does not accept valid control characters

2021-04-02 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It is a known issue, see issue11804 and issue39512. In short, the underlying library for XML parsing (expat) does not support XML 1.1 and does not have plans to support it. And seems that XML 1.1 is a dead standard if it is not supported in popular

[issue43711] cgi.log() uses locale encoding

2021-04-03 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This is a duplicate of issue41139. -- nosy: +serhiy.storchaka resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> cgi uses the locale encoding for log files ___ Py

[issue43655] Tkinter: Not setting _NET_WM_WINDOW_TYPE on FileDialog

2021-04-04 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +23929 pull_request: https://github.com/python/cpython/pull/25187 ___ Python tracker <https://bugs.python.org/issue43

[issue43655] Tkinter: Not setting _NET_WM_WINDOW_TYPE on FileDialog

2021-04-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: PR 25187 makes all Tkinter dialog windows and most IDLE dialog windows (except about and help windows) be recognized as dialogs by window managers on macOS and X Window. It conforms the behavior of standard Tk dialog windows. This change is harmless

[issue43655] Tkinter: make X window & macOS recognize dialogs as such

2021-04-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: See https://wiki.tcl-lang.org/page/MacWindowStyle . I suppose it affects window decoration. -- ___ Python tracker <https://bugs.python.org/issue43

[issue43730] Tutorial Documentation for 4.7.3.2. Positional-Only Parameters, no "/" question?

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

[issue43728] Change the exception type and message raised when _curses is not found.

2021-04-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: ModuleNotFoundError is the correct exception. Its purpose is to be raised for missed modules. I do not know about macOS, but the curses module is not supported on Windows, so it is expected to get ModuleNotFoundError. Some distributions can provide some

[issue43729] Tutorial Documentation for 3.1.1. Numbers missing "result"

2021-04-05 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- nosy: +ezio.melotti, rhettinger ___ Python tracker <https://bugs.python.org/issue43729> ___ ___ Python-bugs-list mailin

[issue22538] turtledemo two_canvases reversion

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

[issue43734] PEP 597: pdb uses locale encoding for pdbrc file

2021-04-05 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> pdb uses the locale encoding for .pdbrc ___ Python tracker <https://bugs.python

[issue43084] curses.window.enclose() should return bool

2021-04-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset b1dc1aacf8b0f319024a1a3ce91d395956537c11 by Serhiy Storchaka in branch 'master': bpo-43084: Return bool instead of int from curses.window.enclose() (GH-24398) https://github.com/python/cpython/commit/b1dc1aacf8b0f319024a1a3ce91d39

[issue43084] curses.window.enclose() should return bool

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

[issue43693] Logically merge cell and locals array. They are already contiguous in memory

2021-04-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: LGTM. -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue43693> ___ ___ Python-bugs-list mailin

[issue43599] Setting long domain of locale.dgettext() crashes Python interpreter

2021-04-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: __dcigettext() contains: domainname_len = strlen (domainname); xdomainname = (char *) alloca (strlen (categoryname) + domainname_len + 5); It tries to allocate a buffer on stack, and for domain name causes stack

[issue43664] Long computations in pdb.run() lead to segfault

2021-04-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It is an old known issue, it is not specific to pdb, but happens with compile(), and it is not fixed yet. >>> compile("+0"*100, '?', 'eval') Segmentation fault (core dumped) Stack overflow in recursive call of

[issue43664] Compiling long expression leads to segfault (again)

2021-04-06 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- title: Long computations in pdb.run() lead to segfault -> Compiling long expression leads to segfault (again) versions: +Python 3.10, Python 3.8 ___ Python tracker <https://bugs.python.org/issu

[issue43737] Documentation of modulo operator should document behaviour clearly when second operator is negative

2021-04-06 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- nosy: +lemburg, mark.dickinson, rhettinger, stutzbach ___ Python tracker <https://bugs.python.org/issue43737> ___ ___ Python-bug

[issue43738] Clarify public name of curses.window

2021-04-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: It could help also in help(). -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue43738> ___ ___

[issue43684] Add combined opcodes

2021-04-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Interesting. What code did you use to collect statistics? I used patches in issue27255. Perhaps it is worth to add an optionally compiled code for collecting dynamic opcode statistics permanently. We have around 125 opcodes, so 0.5% looks too small. But

[issue43748] Inconsistent grammar in new error message (introduced in 3.10.0a7)

2021-04-06 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Not all "can't" in error messages were replaced by "cannot". $ find Parser Python Objects Modules -name '*.[ch]' | xargs egrep '".*[Cc]an'\''t.*"' | wc -l 181 $ find Parser Python Objec

[issue43716] curses.pair_number() function incorrect value under Windows

2021-04-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The curses module is not supported on Windows. windows-curses is a third-party library. Use the corresponding bug tracker to report an issue with windows-curses. -- nosy: +serhiy.storchaka resolution: -> third party stage: -> resolved

[issue42998] pathlib.Path: add `username` argument to `home()`

2021-04-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: os.path.expanduser() has flaws. 1. It can return an argument unchanged if failed to determine the home directory. 2. On Unix it does not work for users not found in the local password database. 3. On Windows it only guess the home directory for other users

[issue39899] `pathlib.Path.expanduser()` does not call `os.path.expanduser()`

2021-04-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: AFAIK you can set arbitrary path as user home directory. So home directories of different users can even not be on the same disk, and the last component of the path can be different from the user name. os.path.expanduser() has many flaws, and it just

[issue43775] JSON Parsing Alarm: Requests + Json = JSONDecodeError

2021-04-08 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: JSON is not HTML. If response.text contains HTML, it is expected that json.loads() cannot parse it. -- nosy: +serhiy.storchaka ___ Python tracker <https://bugs.python.org/issue43

[issue43682] Make static methods created by @staticmethod callable

2021-04-09 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Currently pydoc on X.sm gives: --- sm(x, y) A static method --- I concur with Mark Shannon. The root problem is that Python functions and built-in functions have different behavior when assigned as class attribute. The former became an instance

<    6   7   8   9   10   11   12   13   14   15   >