[issue44256] _functools._lru_list_elem is exposed unintentionally.

2021-05-27 Thread Inada Naoki
Inada Naoki added the comment: New changeset 28be3191a9db2769ed05e55c6bcbccdd029656dd by Inada Naoki in branch 'main': bpo-44256: Do not expose _functools._list_elem_type (GH-26416) https://github.com/python/cpython/commit/28be3191a9db2769ed05e55c6bcbccdd029656dd

[issue44256] _functools._lru_list_elem is exposed unintentionally.

2021-05-27 Thread Inada Naoki
Change by Inada Naoki : -- keywords: +patch pull_requests: +25010 stage: -> patch review pull_request: https://github.com/python/cpython/pull/26416 ___ Python tracker <https://bugs.python.org/issu

[issue44256] _functools._lru_list_elem is exposed unintentionally.

2021-05-27 Thread Inada Naoki
Inada Naoki added the comment: Ref: GH-23405. -- ___ Python tracker <https://bugs.python.org/issue44256> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44256] _functools._lru_list_elem is exposed unintentionally.

2021-05-27 Thread Inada Naoki
New submission from Inada Naoki : _lru_list_elem is internal data strucuture. It is intended to be used only in _lru_cache_wrapper. Until Python 3.9, it is not exposed. But it is exposed by dd3912 accidentally. -- components: Extension Modules keywords: 3.10regression messages: 394626

[issue37596] Reproducible pyc: frozenset is not serialized in a deterministic order

2021-05-26 Thread Inada Naoki
Inada Naoki added the comment: > If that's the case, then the argument Raymond provided against preserving > order does not seem that relevant, as we would only need to preserve the > order in the creation operation. Note that PYC files are marshalled from code objects including

[issue37596] Reproducible pyc: frozenset is not serialized in a deterministic order

2021-05-26 Thread Inada Naoki
Inada Naoki added the comment: > What about normal sets? pyc files don't contain a regular set. So it is out of scope of this issue. -- nosy: +methane ___ Python tracker <https://bugs.python.org/issu

[issue5758] fileinput.hook_compressed returning bytes from gz file

2021-05-25 Thread Inada Naoki
Inada Naoki added the comment: > I did consider and confirm that mode="rb" does also provide a uniform > solution, but it also regresses the behavior of uncompressed inputs, making > them bytes where they were text. Of course, I suggested to use "rb" when yo

[issue44206] Add a version number to dict keys.

2021-05-25 Thread Inada Naoki
Inada Naoki added the comment: For class dict, there is a method cache. For instance dict, there is a LOAD_ATTR optimization. https://github.com/python/cpython/blob/b11a951f16f0603d98de24fee5c023df83ea552c/Python/ceval.c#L3458 So I want to see the performance gain of the optimization using

[issue5758] fileinput.hook_compressed returning bytes from gz file

2021-05-24 Thread Inada Naoki
Inada Naoki added the comment: > I'm struggling with how to adapt the code to provide a uniform interface on > Python 3.6+. It's easy. Just passing `mode="rb"`. ``` FileInput(filelist, mode="rb", openhook=fileinput.hook_compressed) ``` This is better than

[issue44214] PyArg_Parse* for vectorcall?

2021-05-24 Thread Inada Naoki
Change by Inada Naoki : -- nosy: +methane ___ Python tracker <https://bugs.python.org/issue44214> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44117] [C API] Remove deprecated PyEval_InitThreads()

2021-05-14 Thread Inada Naoki
Inada Naoki added the comment: It seems they are stable ABI. https://github.com/python/cpython/blob/56b8ea65d28bd865e2363e10e9f1c2ca3433ffc2/Misc/stable_abi.txt#L604 https://github.com/python/cpython/blob/56b8ea65d28bd865e2363e10e9f1c2ca3433ffc2/Misc/stable_abi.txt#L614 We may need to keep

[issue44114] Incorrect function signatures in dictobject.c

2021-05-13 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +24739 pull_request: https://github.com/python/cpython/pull/26098 ___ Python tracker <https://bugs.python.org/issue44

[issue44094] Remove PyErr_Set...WithUnicodeFilename APIs

2021-05-09 Thread Inada Naoki
Change by Inada Naoki : -- keywords: +patch pull_requests: +24661 stage: -> patch review pull_request: https://github.com/python/cpython/pull/26011 ___ Python tracker <https://bugs.python.org/issu

[issue44094] Remove PyErr_Set...WithUnicodeFilename APIs

2021-05-09 Thread Inada Naoki
New submission from Inada Naoki : These APIs are deprecated since Python 3.3. They are not documented too. ``` #ifdef MS_WINDOWS Py_DEPRECATED(3.3) PyAPI_FUNC(PyObject *) PyErr_SetFromErrnoWithUnicodeFilename( PyObject *, const Py_UNICODE *); /* XXX redeclare to use WSTRING

[issue41692] Deprecate immortal interned strings: PyUnicode_InternImmortal()

2021-05-09 Thread Inada Naoki
Inada Naoki added the comment: For the record, I noticed PyUnicode_InternImmortal() is a stable ABI. We may need to keep the function to avoid dynamic link errors. But we can still change its implementation to just raise an exception

[issue44029] PEP 624: Remove Py_UNICODE APIs

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

[issue40943] PEP 353: Drop support for PyArg_ParseTuple() "#" formats when PY_SSIZE_T_CLEAN is not defined

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

[issue40943] PEP 353: Drop support for PyArg_ParseTuple() "#" formats when PY_SSIZE_T_CLEAN is not defined

2021-05-06 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +24605 stage: resolved -> patch review pull_request: https://github.com/python/cpython/pull/25937 ___ Python tracker <https://bugs.python.org/issu

[issue40943] PEP 353: Drop support for PyArg_ParseTuple() "#" formats when PY_SSIZE_T_CLEAN is not defined

2021-05-06 Thread Inada Naoki
Inada Naoki added the comment: >Why PR 20784 has been merged? Was not the plan to emit a deprecation warning >first? We had been emitted DeprecationWarning since Python 3.8. See GH-12473. GH-20784 changed the DeprecationWarning to Syste

[issue40943] PEP 353: Drop support for PyArg_ParseTuple() "#" formats when PY_SSIZE_T_CLEAN is not defined

2021-05-06 Thread Inada Naoki
Inada Naoki added the comment: There is a still warning, not error. https://github.com/python/cpython/blob/985ac016373403e8ad41f8d563c4355ffa8d49ff/Python/getargs.c#L2535-L2542 -- resolution: fixed -> status: closed -> open ___ Python t

[issue44029] PEP 624: Remove Py_UNICODE APIs

2021-05-04 Thread Inada Naoki
Change by Inada Naoki : -- keywords: +patch pull_requests: +24556 stage: -> patch review pull_request: https://github.com/python/cpython/pull/25881 ___ Python tracker <https://bugs.python.org/issu

[issue44029] PEP 624: Remove Py_UNICODE APIs

2021-05-04 Thread Inada Naoki
New submission from Inada Naoki : Ref: https://www.python.org/dev/peps/pep-0624/ -- components: C API messages: 392862 nosy: methane priority: normal severity: normal status: open title: PEP 624: Remove Py_UNICODE APIs versions: Python 3.11

[issue43733] PEP 597: netrc uses locale encoding.

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

[issue43733] PEP 597: netrc uses locale encoding.

2021-05-01 Thread Inada Naoki
Inada Naoki added the comment: New changeset fd0bc7e7f4f2c7de98a1ebc7ad1ef65b8f8f7ad6 by Inada Naoki in branch 'master': bpo-43733: netrc try to use UTF-8 before using locale encoding. (GH-25781) https://github.com/python/cpython/commit/fd0bc7e7f4f2c7de98a1ebc7ad1ef65b8f8f7ad6

[issue43733] PEP 597: netrc uses locale encoding.

2021-05-01 Thread Inada Naoki
Change by Inada Naoki : -- keywords: +patch pull_requests: +24472 stage: -> patch review pull_request: https://github.com/python/cpython/pull/25781 ___ Python tracker <https://bugs.python.org/issu

[issue14243] tempfile.NamedTemporaryFile not particularly useful on Windows

2021-04-30 Thread Inada Naoki
Inada Naoki added the comment: +1 to Eryk. > Hence my newbie questions are: 1) What problem are you trying to solve by this "unlinking trick"? Same to TempoaryFile in Unix. 2) Do we need to have a separate issue raised for this problem? I don't think so. We didn't unlink beca

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-29 Thread Inada Naoki
Inada Naoki added the comment: New changeset 53dd6c99b39d90935c00bc1558582e494641248e by Inada Naoki in branch 'master': bpo-43651: Fix test_logging (GH-25715) https://github.com/python/cpython/commit/53dd6c99b39d90935c00bc1558582e494641248e

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-29 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +24405 pull_request: https://github.com/python/cpython/pull/25715 ___ Python tracker <https://bugs.python.org/issue43

[issue41139] cgi uses the locale encoding for log files

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

[issue41139] cgi uses the locale encoding for log files

2021-04-28 Thread Inada Naoki
Inada Naoki added the comment: New changeset e52ab42cedd2a5ef4c3c1a47d0cf96a8f06d051f by Inada Naoki in branch 'master': bpo-41139: Deprecate `cgi.log()` (GH-25625) https://github.com/python/cpython/commit/e52ab42cedd2a5ef4c3c1a47d0cf96a8f06d051f

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-28 Thread Inada Naoki
Inada Naoki added the comment: New changeset a69256527f93d2aa32e76658deab829e324d97b6 by Inada Naoki in branch 'master': bpo-43651: Fix EncodingWarning in `os.fdopen()` and test_os (GH-25654) https://github.com/python/cpython/commit/a69256527f93d2aa32e76658deab829e324d97b6

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-28 Thread Inada Naoki
Inada Naoki added the comment: New changeset fa51c0c448aca9fe5d4e8bc02e71de528931778b by Inada Naoki in branch 'master': bpo-43651: Fix EncodingWarning in tests. (GH-25655) https://github.com/python/cpython/commit/fa51c0c448aca9fe5d4e8bc02e71de528931778b

[issue24275] lookdict_* give up too soon

2021-04-28 Thread Inada Naoki
Change by Inada Naoki : -- resolution: remind -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue24275] lookdict_* give up too soon

2021-04-28 Thread Inada Naoki
Inada Naoki added the comment: New changeset 8557edbfa8f74514de82feea4c62f5963e4e0aa7 by Hristo Venev in branch 'master': bpo-24275: Don't downgrade unicode-only dicts to mixed on lookups (GH-25186) https://github.com/python/cpython/commit/8557edbfa8f74514de82feea4c62f5963e4e0aa7

[issue43954] Possible missing word on unittest doc

2021-04-28 Thread Inada Naoki
Inada Naoki added the comment: I propose to remove the namespace package support entirely. * No user (since it has been broken from Python 3.7) * Hard to maintain (we haven't noted it) * Hard to explain (need to specify the top directory. don't search recursively. See bpo-23882

[issue37751] In codecs, function 'normalizestring' should convert both spaces and hyphens to underscores.

2021-04-27 Thread Inada Naoki
Inada Naoki added the comment: New changeset cf9d65c5af7905d9e9945a297dbbf15d3bcace15 by Miss Islington (bot) in branch '3.9': bpo-37751: Update `codecs.register()` doc. (GH-25643) https://github.com/python/cpython/commit/cf9d65c5af7905d9e9945a297dbbf15d3bcace15

[issue37751] In codecs, function 'normalizestring' should convert both spaces and hyphens to underscores.

2021-04-27 Thread Inada Naoki
Inada Naoki added the comment: New changeset 5c84bb506aaca01f5f750116d8f7a41d41f8124d by Inada Naoki in branch 'master': bpo-37751: Update `codecs.register()` doc. (GH-25643) https://github.com/python/cpython/commit/5c84bb506aaca01f5f750116d8f7a41d41f8124d

[issue43954] Possible missing word on unittest doc

2021-04-27 Thread Inada Naoki
Inada Naoki added the comment: namespace package support is broken since Python 3.7. See https://bugs.python.org/issue23882#msg387549 We can not use namespace package even if top level directory is specified. -- ___ Python tracker <ht

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-27 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +24346 pull_request: https://github.com/python/cpython/pull/25655 ___ Python tracker <https://bugs.python.org/issue43

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-27 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +24345 pull_request: https://github.com/python/cpython/pull/25654 ___ Python tracker <https://bugs.python.org/issue43

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-27 Thread Inada Naoki
Inada Naoki added the comment: New changeset 878bc8b6c2051cf344c594636fa957ce6c9d2188 by Inada Naoki in branch 'master': bpo-43651: Fix EncodingWarning in fileinput and its test (GH-25648) https://github.com/python/cpython/commit/878bc8b6c2051cf344c594636fa957ce6c9d2188

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-27 Thread Inada Naoki
Inada Naoki added the comment: New changeset caae717c2903fff4704b59714bc0c65d60108321 by Inada Naoki in branch 'master': bpo-43651: Fix EncodingWarning in zipfile (GH-25650) https://github.com/python/cpython/commit/caae717c2903fff4704b59714bc0c65d60108321

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-26 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +24341 pull_request: https://github.com/python/cpython/pull/25650 ___ Python tracker <https://bugs.python.org/issue43

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-26 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +24339 pull_request: https://github.com/python/cpython/pull/25648 ___ Python tracker <https://bugs.python.org/issue43

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-26 Thread Inada Naoki
Inada Naoki added the comment: New changeset cfe523b49280cdc8c239c807121ad3f33552f638 by Inada Naoki in branch 'master': bpo-43651: PEP 597: Fix `socket.makefile()` (GH-25645) https://github.com/python/cpython/commit/cfe523b49280cdc8c239c807121ad3f33552f638

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-26 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +24338 pull_request: https://github.com/python/cpython/pull/25645 ___ Python tracker <https://bugs.python.org/issue43

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-26 Thread Inada Naoki
Inada Naoki added the comment: New changeset 9dfefbe3e2dc548ad306870b56cc0cb475aa20a2 by Inada Naoki in branch 'master': bpo-43651: Fix EncodingWarning in `pydoc`. (GH-25644) https://github.com/python/cpython/commit/9dfefbe3e2dc548ad306870b56cc0cb475aa20a2

[issue43651] PEP 597: Fix EncodingWarning warnings in the Python stdlib

2021-04-26 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +24337 pull_request: https://github.com/python/cpython/pull/25644 ___ Python tracker <https://bugs.python.org/issue43

[issue37751] In codecs, function 'normalizestring' should convert both spaces and hyphens to underscores.

2021-04-26 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +24336 pull_request: https://github.com/python/cpython/pull/25643 ___ Python tracker <https://bugs.python.org/issue37

[issue43817] Add inspect.get_annotations()

2021-04-26 Thread Inada Naoki
Inada Naoki added the comment: > Just to be clear: I would *not* want this new mode to be the *default* > behavior. So far I think ONLY_IF_STRINGIZED is the best compromise for > default behavior. I don't think ONLY_IF_STRINGIZED is the best compromise. I don't think it solve

[issue41139] cgi uses the locale encoding for log files

2021-04-26 Thread Inada Naoki
Change by Inada Naoki : -- keywords: +patch pull_requests: +24324 stage: -> patch review pull_request: https://github.com/python/cpython/pull/25625 ___ Python tracker <https://bugs.python.org/issu

[issue43817] Add inspect.get_annotations()

2021-04-24 Thread Inada Naoki
Inada Naoki added the comment: > > The difference between eval_str=True and eval_str=ONLY_IF_STRINGIZED: > > def foo(a:int, b:"howdy howdy"): ... > > inspect.get_annotations(foo, eval_str=True) throws an exception. > inspect.get_annotations(foo, eval_str=ONLY_I

[issue43817] Add inspect.get_annotations()

2021-04-24 Thread Inada Naoki
Inada Naoki added the comment: > I think Pydantic would prefer it, because Pydantic wants to see the real > objects at runtime, rather than the stringized annotations. If so, why don't they use `eval_str=True`? I can not find any use cases where `eval_str= ONLY_IF_ALL_STR` is bette

[issue43817] Add inspect.get_annotations()

2021-04-24 Thread Inada Naoki
Inada Naoki added the comment: I'm not sure `ONLY_IF_ALL_STR` is worth enough. Will anyone use it after Python 3.10? inspect.signature()? Pydantic? -- ___ Python tracker <https://bugs.python.org/issue43

[issue43856] Docs for importlib.metadata should mention Python version

2021-04-23 Thread Inada Naoki
Inada Naoki added the comment: New changeset faad2bd87f9e1c24837dd772f0597f4ab9416c66 by Jason R. Coombs in branch '3.8': bpo-43856: Add a versionadded directive to the importlib.metadata docs (GH-25445) https://github.com/python/cpython/commit/faad2bd87f9e1c24837dd772f0597f4ab9416c66

[issue43856] Docs for importlib.metadata should mention Python version

2021-04-23 Thread Inada Naoki
Inada Naoki added the comment: New changeset d4fff1f580aed5d26b9b501d0e626f50da9f7bb7 by Jason R. Coombs in branch '3.9': bpo-43856: Add a versionadded directive to the importlib.metadata docs (GH-25445) https://github.com/python/cpython/commit/d4fff1f580aed5d26b9b501d0e626f50da9f7bb7

[issue37751] In codecs, function 'normalizestring' should convert both spaces and hyphens to underscores.

2021-04-22 Thread Inada Naoki
Inada Naoki added the comment: codecs.register() was added in this commit. https://github.com/python/cpython/commit/e2d67f98d1aade1059b2ff3278672b2ffbaf180e And its docstring has been added in this commit. https://github.com/python/cpython/commit/0ae2981dec3de96a1f7d63b0535992cf1462ac92 Both

[issue37751] In codecs, function 'normalizestring' should convert both spaces and hyphens to underscores.

2021-04-22 Thread Inada Naoki
Inada Naoki added the comment: I think it is too late. Python 3.9 has been released already. Reverting the change is also breaking change. PEP 100 says: "Search functions are expected to take one argument, the encoding name in all lower case letters and with hyphens and spaces conv

[issue28724] Add method send_io, recv_io to the socket module.

2021-04-21 Thread Inada Naoki
Change by Inada Naoki : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: +Python 3.9 -Python 3.7 ___ Python tracker <https://bugs.python.or

[issue28724] Add method send_io, recv_io to the socket module.

2021-04-21 Thread Inada Naoki
Inada Naoki added the comment: New changeset 660592f67c0d825b06eb4a38ccc04b34a1f01f00 by Saiyang Gou in branch 'master': bpo-28724: Doc: Move socket.send_fds and socket.recv_fds docs to right section (GH-22608) https://github.com/python/cpython/commit

[issue30800] zlib.compressobj took too much memory on window

2021-04-21 Thread Inada Naoki
Change by Inada Naoki : -- stage: -> resolved status: pending -> closed ___ Python tracker <https://bugs.python.org/issue30800> ___ ___ Python-bugs-list

[issue43817] Add typing.get_annotations()

2021-04-16 Thread Inada Naoki
Inada Naoki added the comment: Should this feature implemented in typing module? How about inspect module? Additionally, how about adding `get_annotation_str()`, which returns str always? Some use cases (e.g. `help(f)`) need just string. I want to skip eval() in it. -- nosy: +methane

[issue41323] Perform "peephole" optimization directly on control-flow graph.

2021-04-15 Thread Inada Naoki
Inada Naoki added the comment: New changeset 8a232c7b17a2e41ae14d8bb7937ddfea69301dce by Inada Naoki in branch 'master': bpo-41323: compiler: Reuse tuple in constant tuple folding (GH-25419) https://github.com/python/cpython/commit/8a232c7b17a2e41ae14d8bb7937ddfea69301dce

[issue41323] Perform "peephole" optimization directly on control-flow graph.

2021-04-14 Thread Inada Naoki
Change by Inada Naoki : -- nosy: +methane nosy_count: 4.0 -> 5.0 pull_requests: +24150 pull_request: https://github.com/python/cpython/pull/25419 ___ Python tracker <https://bugs.python.org/issu

[issue43733] PEP 597: netrc uses locale encoding.

2021-04-14 Thread Inada Naoki
Inada Naoki added the comment: I googled "netrc UnicodeDecodeError". It is very rare, but I found two cases. * https://stackoverflow.com/questions/54748450/macos-python-3-netrc-operations-end-up-with-unicodedecodeerror This user uses macOS and Python tried UTF-8. But .netrc was

[issue43777] Remove description of "pip search" command from tutorial

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

[issue43733] PEP 597: netrc uses locale encoding.

2021-04-13 Thread Inada Naoki
Change by Inada Naoki : -- nosy: +xiang.zhang ___ Python tracker <https://bugs.python.org/issue43733> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue42578] Add tip when encountering UnicodeDecode/EncodeError in open()

2021-04-13 Thread Inada Naoki
Change by Inada Naoki : -- resolution: -> wont fix stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue42578> ___ ___

[issue41098] Deprecating PyUnicodeEncodeError_Create

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

[issue42152] Use PyDict_Contains() and PyDict_SetDefault() instead of PyDict_GetItemWithError()

2021-04-13 Thread Inada Naoki
Inada Naoki added the comment: May I close this issue? -- ___ Python tracker <https://bugs.python.org/issue42152> ___ ___ Python-bugs-list mailing list Unsub

[issue5758] fileinput.hook_compressed returning bytes from gz file

2021-04-13 Thread Inada Naoki
Change by Inada Naoki : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.o

[issue43712] PEP 597: fileinput uses locale encoding

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

[issue43712] PEP 597: fileinput uses locale encoding

2021-04-13 Thread Inada Naoki
Inada Naoki added the comment: New changeset 333d10cbb53dd5f28d76f659a49bf0735f8509d8 by Inada Naoki in branch 'master': bpo-43712 : fileinput: Add encoding parameter (GH-25272) https://github.com/python/cpython/commit/333d10cbb53dd5f28d76f659a49bf0735f8509d8

[issue43777] Remove description of "pip search" command from tutorial

2021-04-13 Thread Inada Naoki
Inada Naoki added the comment: New changeset 133705b85cc25d1e6684d32f8943ca288fadfda0 by Bob Kline in branch 'master': bpo-43777: Drop description of "pip search" command from tutorial (GH-25287) https://github.com/python/cpython/commit/133705b85cc25d1e6684d32f8943ca

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

2021-04-13 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +24128 pull_request: https://github.com/python/cpython/pull/25395 ___ Python tracker <https://bugs.python.org/issue43

[issue43682] Make static methods created by @staticmethod callable

2021-04-13 Thread Inada Naoki
Inada Naoki added the comment: Strictly speaking, adding any method is "potential" breaking change because hasattr(obj, "new_method") become from False to True. And since Python is dynamic language, any change is "potential" breaking change. But we don't treat

[issue43731] PEP 597: logging.fileConfig() uses locale encoding.

2021-04-13 Thread Inada Naoki
Inada Naoki added the comment: > Ah, so you want to emit an EncodingWarning when fileConfig(filename) is > called without specifying an encoding, right? Yes, but only when the user uses `PYTHONWARNDEFAULTENCODING`. I already added `export PYTHONWARNDEFAULTENCODING=1` in `.bashrc` in

[issue43785] Remove RLock from BZ2File

2021-04-13 Thread Inada Naoki
Inada Naoki added the comment: New changeset 695d47b51e3e197de5448a1eb2f618bef6d59ac8 by Inada Naoki in branch 'master': bpo-43785: Update bz2 document (GH-25351) https://github.com/python/cpython/commit/695d47b51e3e197de5448a1eb2f618bef6d59ac8

[issue43785] Remove RLock from BZ2File

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

[issue43731] PEP 597: logging.fileConfig() uses locale encoding.

2021-04-13 Thread Inada Naoki
Inada Naoki added the comment: If we use `encoding="locale"` by default, EncodingWarning will be not be emitted even when user omit `encoding` option. -- ___ Python tracker <https://bugs.python.o

[issue43731] PEP 597: logging.fileConfig() uses locale encoding.

2021-04-13 Thread Inada Naoki
Inada Naoki added the comment: New changeset c2b7a66b91cdb96fbfdb160f96797208ddc5e436 by Inada Naoki in branch 'master': bpo-43731: Add an `encoding` parameter to logging.fileConfig() (GH-25273) https://github.com/python/cpython/commit/c2b7a66b91cdb96fbfdb160f96797208ddc5e436

[issue43731] PEP 597: logging.fileConfig() uses locale encoding.

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

[issue43787] Optimize BZ2File, GzipFile, and LZMAFile __iter__ method.

2021-04-12 Thread Inada Naoki
Inada Naoki added the comment: New changeset d2a8e69c2c605fbaa3656a5f99aa8d295f74c80e by Inada Naoki in branch 'master': bpo-43787: Add __iter__ to GzipFile, BZ2File, and LZMAFile (GH-25353) https://github.com/python/cpython/commit/d2a8e69c2c605fbaa3656a5f99aa8d295f74c80e

[issue43787] Optimize BZ2File, GzipFile, and LZMAFile __iter__ method.

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

[issue43787] Optimize BZ2File, GzipFile, and LZMAFile __iter__ method.

2021-04-12 Thread Inada Naoki
Change by Inada Naoki : -- keywords: +patch pull_requests: +24088 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/25353 ___ Python tracker <https://bugs.python.org/issu

[issue43785] Remove RLock from BZ2File

2021-04-11 Thread Inada Naoki
Change by Inada Naoki : -- pull_requests: +24086 pull_request: https://github.com/python/cpython/pull/25351 ___ Python tracker <https://bugs.python.org/issue43

[issue43785] Remove RLock from BZ2File

2021-04-11 Thread Inada Naoki
Inada Naoki added the comment: New changeset cc2ffcdfd78df3a18edae60df81b2f1b044b1634 by Inada Naoki in branch 'master': bpo-43785: Improve BZ2File performance by removing RLock (GH-25299) https://github.com/python/cpython/commit/cc2ffcdfd78df3a18edae60df81b2f1b044b1634

[issue43787] Optimize BZ2File, GzipFile, and LZMAFile __iter__ method.

2021-04-09 Thread Inada Naoki
New submission from Inada Naoki : __iter__ method of BZ2File, GzipFile, and LZMAFile is IOBase.__iter__. It calls `readline()` for each line. Since `readline()` is defined as Python function, it is slower than C iterator. Adding custom __iter__ method that delegates to underlying buffer

[issue43785] Remove RLock from BZ2File

2021-04-09 Thread Inada Naoki
Inada Naoki added the comment: I will create a separated issue for __iter__, because it is same to gzip and lzma. -- title: bz2 performance issue. -> Remove RLock from BZ2File ___ Python tracker <https://bugs.python.org/issu

[issue43785] bz2 performance issue.

2021-04-08 Thread Inada Naoki
Change by Inada Naoki : -- keywords: +patch pull_requests: +24031 stage: -> patch review pull_request: https://github.com/python/cpython/pull/25299 ___ Python tracker <https://bugs.python.org/issu

[issue43785] bz2 performance issue.

2021-04-08 Thread Inada Naoki
Change by Inada Naoki : -- type: -> performance Added file: https://bugs.python.org/file49949/create.py ___ Python tracker <https://bugs.python.org/issu

[issue43785] bz2 performance issue.

2021-04-08 Thread Inada Naoki
New submission from Inada Naoki : The original issue is reported here. https://discuss.python.org/t/non-optimal-bz2-reading-speed/6869 1. Only BZ2File uses RLock() lzma and gzip don't use RLock(). It adds significant performance overhead. When I removed `with self._lock:`, decompression speed

[issue43682] Make static methods created by @staticmethod callable

2021-04-08 Thread Inada Naoki
Change by Inada Naoki : -- nosy: +methane ___ Python tracker <https://bugs.python.org/issue43682> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43777] Remove description of "pip search" command from tutorial

2021-04-08 Thread Inada Naoki
Inada Naoki added the comment: You are misreading the error message. > RuntimeError: PyPI's XMLRPC API is currently disabled due to unmanageable > load and will be deprecated in the near future. See > https://status.python.org/ for more information. This error message says "

[issue43731] PEP 597: logging.fileConfig() uses locale encoding.

2021-04-08 Thread Inada Naoki
Change by Inada Naoki : -- keywords: +patch pull_requests: +24009 stage: -> patch review pull_request: https://github.com/python/cpython/pull/25273 ___ Python tracker <https://bugs.python.org/issu

[issue43731] PEP 597: logging.fileConfig() uses locale encoding.

2021-04-08 Thread Inada Naoki
Inada Naoki added the comment: s/basicConfig/fileConfig/ basicConfig() is fixed by fb7869. -- title: PEP 597: logging.basicConfig() uses locale encoding. -> PEP 597: logging.fileConfig() uses locale encoding. ___ Python tracker <

[issue5758] fileinput.hook_compressed returning bytes from gz file

2021-04-07 Thread Inada Naoki
Change by Inada Naoki : -- nosy: +methane nosy_count: 5.0 -> 6.0 pull_requests: +24008 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/25272 ___ Python tracker <https://bugs.python.org/

[issue43712] PEP 597: fileinput uses locale encoding

2021-04-07 Thread Inada Naoki
Change by Inada Naoki : -- keywords: +patch pull_requests: +24007 stage: -> patch review pull_request: https://github.com/python/cpython/pull/25272 ___ Python tracker <https://bugs.python.org/issu

[issue36865] FileInput does not allow 'rt' mode, but all its existing delegates do

2021-04-07 Thread Inada Naoki
Inada Naoki added the comment: I don't think we should support "text for regular file but binary for compressed file" mode in FileInput. So no need to add 't'. We should just fix #5758. -- nosy: +methane resolution: -> duplicate stage: patch review -> resolved status

[issue5758] fileinput.hook_compressed returning bytes from gz file

2021-04-07 Thread Inada Naoki
Change by Inada Naoki : -- versions: +Python 3.10 -Python 3.2, Python 3.3 ___ Python tracker <https://bugs.python.org/issue5758> ___ ___ Python-bugs-list mailin

<    1   2   3   4   5   6   7   8   9   10   >