[issue27637] int.to_bytes(-1, ...) should automatically choose required count of bytes

2021-10-04 Thread Lorenz Panny
Lorenz Panny added the comment: I would like to express my support for making length=None to automatically use the minimal possible length. It's true that this will rarely be needed in production-grade serialization code, but this functionality is worth its weight in gold for quickly

[issue41682] [Windows] test_asyncio: Proactor test_sendfile_close_peer_in_the_middle_of_receiving failure

2021-10-04 Thread Dennis Sweeney
Change by Dennis Sweeney : -- nosy: +Dennis Sweeney nosy_count: 8.0 -> 9.0 pull_requests: +27076 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/28727 ___ Python tracker

[issue45369] Remove LibreSSL support

2021-10-04 Thread ramikg
New submission from ramikg : Python 3.10 drops support for LibreSSL (as per PEP 644), but there are still a few workarounds & mentions of LibreSSL in the source code. The related PR cleans the code of any LibreSSL workarounds or mentions. -- assignee: christian.heimes components: SSL

[issue45369] Remove LibreSSL support

2021-10-04 Thread ramikg
Change by ramikg : -- keywords: +patch pull_requests: +27075 stage: -> patch review pull_request: https://github.com/python/cpython/pull/28728 ___ Python tracker ___

[issue45368] ~(True) and ~(False) gives incorrect result

2021-10-04 Thread Narendra Madurkar
Narendra Madurkar added the comment: True is a boolean so ~True should return False according to me. True is not the same as 1 -- ___ Python tracker ___

[issue45368] ~(True) and ~(False) gives incorrect result

2021-10-04 Thread Eric V. Smith
Eric V. Smith added the comment: What were you expecting? I think those are correct. See: >>> ~1 -2 >>> ~0 -1 -- nosy: +eric.smith ___ Python tracker ___

[issue45368] ~(True) and ~(False) gives incorrect result

2021-10-04 Thread Narendra Madurkar
New submission from Narendra Madurkar : ~(True) returns -2 ~(False) returns -1 -- messages: 403190 nosy: nmadurkar priority: normal severity: normal status: open title: ~(True) and ~(False) gives incorrect result ___ Python tracker

[issue45366] dataclass init=False field with default works but default_factory does not

2021-10-04 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +eric.smith ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue45367] Specialize BINARY_MULTIPLY

2021-10-04 Thread Dennis Sweeney
Change by Dennis Sweeney : -- keywords: +patch pull_requests: +27074 stage: -> patch review pull_request: https://github.com/python/cpython/pull/28727 ___ Python tracker ___

[issue45367] Specialize BINARY_MULTIPLY

2021-10-04 Thread Dennis Sweeney
New submission from Dennis Sweeney : I'm having trouble setting up a rigorous benchmark (Windows doesn't want to install greenlet for pyperformance), but just running a couple of individual files, I got this: Mean +- std dev: [nbody_main] 208 ms +- 2 ms -> [nbody_specialized] 180 ms +- 2

[issue45335] Default TIMESTAMP converter in sqlite3 ignores UTC offset

2021-10-04 Thread Ian Fisher
Ian Fisher added the comment: Unfortunately fixing this will have to be considered a backwards-incompatible change, since Python doesn't allow naive and aware datetime objects to be compared, so if sqlite3 starts returning aware datetimes, existing code might break. Alternatively, perhaps

[issue45339] concurrent.future.ThreadPoolExecutor should parameterize class used for threads

2021-10-04 Thread Erick
Erick added the comment: It also occurs to me that even if `concurrent.futures` adopted an alternative Thread class, it would still be preferable to allow for composition in the manner that was originally proposed. -- ___ Python tracker

[issue45339] concurrent.future.ThreadPoolExecutor should parameterize class used for threads

2021-10-04 Thread Erick
Erick added the comment: > What are examples of your some_important_context()? Is it important to call > some code before destroying the thread? To be honest, pulled a context manager example out of thin air to illustrate the point. But sure, I want to allocate a resource before the thread

[issue45335] Default TIMESTAMP converter in sqlite3 ignores time zone

2021-10-04 Thread Erlend E. Aasland
Erlend E. Aasland added the comment: Replacing the timestamp converter with datetime.datetime.fromisoformat sounds good to me. -- ___ Python tracker ___

[issue45358] Bogus cookie generated after invalid cookie attribute is input

2021-10-04 Thread greob
Change by greob : -- keywords: +patch pull_requests: +27072 stage: -> patch review pull_request: https://github.com/python/cpython/pull/28726 ___ Python tracker ___

[issue32307] Bad assumption on thread stack size makes python crash with musl libc

2021-10-04 Thread Gregory P. Smith
Gregory P. Smith added the comment: I left some comments on the PR. We can at least make it detect musl libc and improve its default behavior there. FWIW CPython's recursionlimit and the C stack have long been a thorn in the side of many things. Even when Python's thread_pthread.h is

[issue32307] Bad assumption on thread stack size makes python crash with musl libc

2021-10-04 Thread Gregory P. Smith
Change by Gregory P. Smith : -- nosy: +gregory.p.smith ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue45089] [sqlite3] the trace callback does not raise exceptions on error

2021-10-04 Thread Erlend E. Aasland
Change by Erlend E. Aasland : -- resolution: wont fix -> fixed ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue45366] dataclass init=False field with default works but default_factory does not

2021-10-04 Thread simple_coder878
simple_coder878 added the comment: Also wanted to add that I did try another variation of the first example where I set the default_factory field's init value to False and I got the same error. from dataclasses import dataclass, field @dataclass(init=False) class TestObject(object): m:

[issue45366] dataclass init=False field with default works but default_factory does not

2021-10-04 Thread simple_coder878
New submission from simple_coder878 : Simple example from dataclasses import dataclass, field @dataclass(init=False) class TestObject(object): m: str = field(default='hi') k: list = field(default_factory=list) def test(self): print(f'm is {self.m} ') print(f'k is

[issue45356] Calling `help` executes @classmethod @property decorated methods

2021-10-04 Thread wim glenn
Change by wim glenn : -- nosy: +wim.glenn ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44182] python-config.sh vs python-config.py inconsistency

2021-10-04 Thread Isuru Fernando
Change by Isuru Fernando : -- keywords: +patch pull_requests: +27071 stage: -> patch review pull_request: https://github.com/python/cpython/pull/28725 ___ Python tracker ___

[issue45365] concurrent.futures.Future should be suitable for use outside of executors

2021-10-04 Thread Xavier Morel
New submission from Xavier Morel : concurrent.futures.Future currently has the note: > Future instances are created by Executor.submit() and should not be created > directly except for testing. That seems like a shame as futures are useful concurrency construct and having to rebuild them

[issue45246] the sorted() documentation should refer to operator

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 2e4d66d2e71d36de394e0e7a4e60ed7b6a539933 by Pablo Galindo (Łukasz Langa) in branch '3.10': [3.10] bpo-45246: Document that sorted() only uses "<" comparisons (GH-28494) (GH-28502)

[issue45121] Calling super().__init__ in subclasses of typing.Protocol raises RecursionError

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset db762a9b21a8af6f2ee94a6e49144dd1a1a62333 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45121: Fix RecursionError when calling Protocol.__init__ from a subclass' __init__ (GH-28206) (GH-28232)

[issue4356] Add "key" argument to "bisect" module functions

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 7128864885340e0d75ddfe32887257e245d9c1f7 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-4356: Mention the new key arguments for the bisect module APIs in the 3.10 What's new (GH-28339) (GH-28340)

[issue43219] shutil.copy raises IsADirectoryError when the directory does not actually exist

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset e0b61b28641bdd20cfeff6d9878f1318b711ca19 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45234: Fix FileNotFound exception raised instead of IsADirectoryError in shutil.copyfile() (GH-28421) (GH-28508)

[issue23864] doc: issubclass without registration only works for "one-trick pony" collections ABCs.

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 9d8a64a7ccebb288094d4e9da66f30d2ada9a973 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45024 and bpo-23864: Document how interface testing works with the collections ABCs (GH-28218) (GH-28266)

[issue44964] Semantics of PyCode_Addr2Line() changed

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 490a7427dce1cba55a9fbdbccd092e4c8ffae05f by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-44964: Correct the note about the f_lasti field (GH-28208) (GH-28276)

[issue45067] Failed to build _curses on CentOS 7

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset dfccba47339722ff082a05a190593be9e443cb0e by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45067 - Verify the version of ncurses for extended color support feature usage. (GH-28260)

[issue45350] configure incorrectly ignores pkg-config information for libffi and Tcl/Tk in 3.10

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 2c47b8080b030ad9cdae96a02fa1e533806eb22a by Pablo Galindo (Pablo Galindo Salgado) in branch '3.10': bpo-45350: Rerun autoreconf with the pkg-config macros (GH-28707)

[issue38623] Python documentation should mention how to find site-packages

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset cdfbe581bae1b33d4eb135597cd27b0f3782e97e by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-38623: Add note about site module (site-packages) (GH-16974) (GH-28536)

[issue45277] typo in codecs documentation

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 0b568530ecb6ccc696771acf8018ec6fff1a0a5f by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45277: Fix typo in codecs doc (GH-28555) https://github.com/python/cpython/commit/0b568530ecb6ccc696771acf8018ec6fff1a0a5f

[issue45346] Some "truthy" crept in

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 49fac92173d2c6cc3bd42a2355824e13272a3a7d by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45346: Keep docs consistent regarding true and false values (GH-28697) (GH-28698)

[issue45198] __set_name__ documentation not clear about its usage with non-descriptor classes

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset aac54ef2b30eb27f6756bbf0cdb8be2e64f2cce0 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45198: __set_name__ documentation not clear about its usage with non-descriptor classes (GH-28439)

[issue45216] Remove redundant information from difflib docstrings

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset e1eb03d15fa543ea7e3275b213fdb2c649b5968e by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45216: Remove extraneous method docs from `difflib` (GH-28445) (GH-28505)

[issue45089] [sqlite3] the trace callback does not raise exceptions on error

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 6fc66d6b9d39fa7a5a8692062d54b5a6a1aa0283 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45089: Improve sqlite3 trace callback docs (GH-28238) (GH-28371)

[issue43914] Highlight invalid ranges in SyntaxErrors

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 0eb57c3be47e45b10124428ab45827467cd2d58e by Pablo Galindo (Łukasz Langa) in branch '3.10': [3.10] bpo-43914: What's New 3.10: add new SyntaxError attributes (GH-28558) (GH-28562)

[issue45310] test_multiprocessing_forkserver: test_shared_memory_basics() failed with FileExistsError: [Errno 17] File exists: '/test01_tsmb'

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset bc4c705869d4a24fc137a81df913869aa51d60d2 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45310: Fix parrallel shared memory tests (GH-28661) https://github.com/python/cpython/commit/bc4c705869d4a24fc137a81df913869aa51d60d2

[issue45217] ConfigParser does not accept "No value" reversely to the doc

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset c4e9ef1f1d3bb7aca09f3ac6691a78d1341d7fcb by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45217: adds note that `allow_no_value` in `configparser` is optional (GH-28396) (GH-28418)

[issue45118] regrtest no longer lists "re-run tests" in the second summary

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 6ae97bbf4e6540a8287c47d098cfe703260b5fa2 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45118: Fix regrtest second summary for re-run tests (GH-28183) (GH-28214)

[issue41203] Replace references to OS X in documentation with macOS

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset db3ac483271c1c21432dea97de8ae5df5b9d by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-41203: Replace Mac OS X and OS X with macOS (GH-28515) (GH-28523)

[issue45249] Update doctect SyntaxErrors for location range

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 1e2058214fffcb3919e0e127145106ade40a0420 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45249: Ensure the traceback module prints correctly syntax errors with ranges (GH-28575)

[issue45234] copy_file raises FileNotFoundError when src is a directory

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset e0b61b28641bdd20cfeff6d9878f1318b711ca19 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45234: Fix FileNotFound exception raised instead of IsADirectoryError in shutil.copyfile() (GH-28421) (GH-28508)

[issue44860] sysconfig's posix_user scheme has different platlib value to distutils's unix_user

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 01be51833db23414b5dc766f9c92953d838d82c3 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-44860: Update test_sysconfig for posix_user platlib (GH-28235) (GH-28251)

[issue45307] Removal of _PyImport_FindExtensionObject() in 3.10 limits custom extension module loaders

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 2ca4ab8031107f9e474e2ce26561ab9ad51faf9c by Pablo Galindo (Serhiy Storchaka) in branch '3.10': [3.10] bpo-45307: Restore private C API function _PyImport_FindExtensionObject() (GH-28594)

[issue30951] Documentation error in inspect module

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 7d652c1b7a56524fec42f65d9be28c17888075ab by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-30951: Correct co_names docstring in inspect module (GH-2743) (GH-28543)

[issue45291] Some instructions in the "Using Python on Unix platforms" document do no work on CentOS 7

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 63c4d42e6ea68104561c853b065c004b200eba68 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45291: Explicitly set --libdir=lib when configure OpenSSL (GH-28566) (GH-28616)

[issue43760] The DISPATCH() macro is not as efficient as it could be (move PyThreadState.use_tracing)

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 78184fa6b0e6129203673e425718e08f5edb6e2e by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-43760: Document PyThreadState.use_tracing removal (GH-28527) (GH-28529)

[issue45128] test_multiprocessing_fork fails if run sequentially after test_genericalias and test_logging

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 76611038bc3d2aa643dce45448f5c7044dd4fd06 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45128: fixes `test_multiprocessing_fork` mysterious crash (GH-28387)

[issue45341] Update "Python Package Index" in Docs

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 18bf0c10ec7b98e6e1514dc08e5bb7228840316e by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45341: Replace 'Packaging' with 'Package' in "Python P... Index" (GH-28687)

[issue45024] Cannot extend collections ABCs with protocol

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 9d8a64a7ccebb288094d4e9da66f30d2ada9a973 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45024 and bpo-23864: Document how interface testing works with the collections ABCs (GH-28218) (GH-28266)

[issue44640] Fix punctuation in isinstance() error message

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 39c4fe5e2b2ae5ac45c380b0a83e86bac3d7129c by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-44640: Improve punctuation consistency in isinstance/issubclass error messages (GH-27144) (GH-28436)

[issue42038] Tracemalloc's format() doc contradictory

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 84d56ec4bc0cb44629ba898a30eece48546828d2 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-42038: fix description of returned list of lines (GH-27529) (GH-28428)

[issue30637] Syntax error reported on compile(...), but not on compile(..., ast.PyCF_ONLY_AST)

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset f025ea23210173b42303360aca05132e4ffdfed3 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-30637: Improve the docs of ast.parse regarding differences with compile() (GH-28459)

[issue9811] strftime strips '%' from unknown format codes on OS X

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset b1873d1e24ed5ef39f37ca3090c2f0c2b34ce23f by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-9811: [doc] strftime handling of unsupported format specifiers is platform dependent (GH-28264) (GH-28277)

[issue45193] IDLE Show completions pop-up not working on Ubuntu Linux

2021-10-04 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 7f2d049cce6dc749a589424d4fb62ffca0b85b32 by Pablo Galindo (Miss Islington (bot)) in branch '3.10': bpo-45193: Restore IDLE completion boxes on Ubuntu (GH-28343)

[issue45354] test_winconsoleio fails on Windows 11

2021-10-04 Thread Eryk Sun
Eryk Sun added the comment: > This will be the change to make "special" filenames only be > special when used on their own, and not as part of a path For some reason, Windows 11 still reserves case-insensitive "nul" in qualified paths, but none of the other DOS device names. Thankfully it's

[issue45339] concurrent.future.ThreadPoolExecutor should parameterize class used for threads

2021-10-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: You can call __enter__ in the initializer. Seems there is no easy way to call __exit__ at shutting down the thread, perhaps something like per-thread atexit could help. As an example, you can save the context manager in thread locals and manually

[issue45352] Move documentation for typed generic forms of standard collections to collections.abc

2021-10-04 Thread Guido van Rossum
Guido van Rossum added the comment: I'm not against additional tutorial for typing. But the standard library manual is supposed to be a complete reference. There is enough variation between different generic types (e.g. are the parameters covariant?) that ought to be documented. I don't

[issue45354] test_winconsoleio fails on Windows 11

2021-10-04 Thread Steve Dower
Steve Dower added the comment: This will be the change to make "special" filenames only be special when used on their own, and not as part of a path (e.g. you shouldn't have any trouble with "aux" or "com" filenames either). I had expected it to roll out sooner, but I guess Windows 11 is

[issue45339] concurrent.future.ThreadPoolExecutor should parameterize class used for threads

2021-10-04 Thread Erick
Erick added the comment: > Can you apply some custom logic by specifying the initializer? Not sure that I follow; how would I use a context manager with the initializer? Of course this is just one example. In the `threading` docs, the second sentence in the description of the `Thread.run`

[issue45364] Add more documentation for ModuleSpec.loader_state.

2021-10-04 Thread Eric Snow
New submission from Eric Snow : Currently ModuleSpec.loader_state is documented briefly once in the importlib docs. [1] It should have more explanation, e.g. about when/why it should be used. It should also be mentioned meaningfully in the MetapathFinder [2] and Loader [3] docs, as well as

[issue43760] The DISPATCH() macro is not as efficient as it could be (move PyThreadState.use_tracing)

2021-10-04 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +27070 pull_request: https://github.com/python/cpython/pull/28723 ___ Python tracker ___

[issue45362] dis does not work with the new optimized ops

2021-10-04 Thread Mark Shannon
Mark Shannon added the comment: 127 and 48 aren't instructions. >>> opcode.stack_effect(48) Traceback (most recent call last): File "", line 1, in ValueError: invalid opcode or oparg So the output from dis seems correct. >If not, how would it deal with co_code being modified? The

[issue45362] dis does not work with the new optimized ops

2021-10-04 Thread Ken Jin
Ken Jin added the comment: > Will this change be reflected in co_code? No. As per PEP 659: "Once any instruction in a code object has executed a few times, that code object will be "quickened" by allocating a new array for the bytecode that can be modified at runtime, and is not

[issue45355] Use sizeof(_Py_CODEUNIT) instead of literal 2 for the size of the code unit

2021-10-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 1670d590fa6b817e0d3f091ea12aee9ae744875a by Serhiy Storchaka in branch '3.10': [3.10] bpo-45355: More use of sizeof(_Py_CODEUNIT) (GH-28720). (GH-28721) https://github.com/python/cpython/commit/1670d590fa6b817e0d3f091ea12aee9ae744875a

[issue45362] dis does not work with the new optimized ops

2021-10-04 Thread Martmists
Martmists added the comment: > Specialized instructions are a hidden implementation detail, and instead the > normal generic instruction will appear. Will this change be reflected in co_code? If yes, then I'm aware of cases where this may be used by bytecode modification libraries. If not,

[issue45362] dis does not work with the new optimized ops

2021-10-04 Thread Ken Jin
Ken Jin added the comment: Thanks Martmists for the bug report, I'll try to address some of your concerns: > The reason for this seems to be the lack of definition in `opcode.py` aside > from being mentioned in _specialized_instructions. If I understood Mark's intentions in PEP 659

[issue45352] Move documentation for typed generic forms of standard collections to collections.abc

2021-10-04 Thread Ken Jin
Ken Jin added the comment: > I think those should go with the individual types as well The list[] and dict[] stdtypes are in a different document from collections.abc.*. While this helps logical separation, I feel like it'd be tougher searching for type information compared to our current

[issue45363] Use instruction offsets in co_lnotab

2021-10-04 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +27069 stage: -> patch review pull_request: https://github.com/python/cpython/pull/28722 ___ Python tracker

[issue44182] python-config.sh vs python-config.py inconsistency

2021-10-04 Thread STINNER Victor
STINNER Victor added the comment: Maybe unit tests can be written on python-config.sh and python-config.py commands. -- nosy: +vstinner ___ Python tracker ___

[issue45302] 10 built-in functions need non-None .__text_signature__

2021-10-04 Thread xloem
xloem <0xl...@gmail.com> added the comment: Thanks for your time. Just a note that this is likely a docs issue if nothing else. I may never have opened this issue if the missing functions were listed in the inspect module documentation. -- ___

[issue45362] dis does not work with the new optimized ops

2021-10-04 Thread Dong-hee Na
Change by Dong-hee Na : -- nosy: +Mark.Shannon, kj ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue45355] Use sizeof(_Py_CODEUNIT) instead of literal 2 for the size of the code unit

2021-10-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset b5499784ec0aa24c8f0d91f2317cc53b7743ada9 by Serhiy Storchaka in branch '3.10': [3.10] bpo-45355: Use sizeof(_Py_CODEUNIT) instead of literal 2 for the size of the code unit (GH-28711). (GH-28718)

[issue45355] Use sizeof(_Py_CODEUNIT) instead of literal 2 for the size of the code unit

2021-10-04 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +27068 pull_request: https://github.com/python/cpython/pull/28721 ___ Python tracker ___

[issue45362] dis does not work with the new optimized ops

2021-10-04 Thread Dong-hee Na
Change by Dong-hee Na : -- nosy: +corona10 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue45355] Use sizeof(_Py_CODEUNIT) instead of literal 2 for the size of the code unit

2021-10-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 252b7bcb236dc261f3af1275bc90f9a303d9648f by Serhiy Storchaka in branch 'main': bpo-45355: More use of sizeof(_Py_CODEUNIT) (GH-28720) https://github.com/python/cpython/commit/252b7bcb236dc261f3af1275bc90f9a303d9648f --

[issue45363] Use instruction offsets in co_lnotab

2021-10-04 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : It was a part of the original patch for issue27129. As well as in jumping instructions we can use instruction offsets instead of bytes offset in co_lnotab. It increases the range of offsets which can be encoded with a single byte, and therefore reduce

[issue28206] signal.Signals not documented

2021-10-04 Thread Julien Palard
Julien Palard added the comment: New changeset 9be930f9b169fb3d92693670ae069df902709b83 by Bibo-Joshi in branch 'main': bpo-28206: Document signals Handlers, Sigmasks and Signals enums (GH-28628) https://github.com/python/cpython/commit/9be930f9b169fb3d92693670ae069df902709b83 --

[issue45360] xml.etree.ElementTree: add feature in write to create directories also like mkdir -p

2021-10-04 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: open() does not create parent directories either. And no any function in the stdlib which creates a file does it. It would be rather error-prone if they do, because you can create a file at wrong place. So just create a directory if you need to, and let

[issue45362] dis does not work with the new optimized ops

2021-10-04 Thread Martmists
Martmists added the comment: Another thing I found to be quite odd is JUMP_ABSOLUTE_QUICK, which is set as 40, but as it's derived from JUMP_ABSOLUTE it still requires an argument. This makes HAVE_ARGUMENT useless as there's an op that doesn't follow the convention. --

[issue45362] dis does not work with the new optimized ops

2021-10-04 Thread Martmists
New submission from Martmists : Python 3.11.0a0 (heads/main:e6d1aa1, Oct 4 2021, 10:33:36) [GCC 11.1.0] on linux Type "help", "copyright", "credits" or "license" for more information. >>> import dis >>> c = bytes([127, 1, 0, 2]) # LOAD_FAST__LOAD_FAST (1, 2) >>> dis.dis(c) 0 <127>

[issue45335] Default TIMESTAMP converter in sqlite3 ignores time zone

2021-10-04 Thread Florian Obersteiner
Change by Florian Obersteiner : -- nosy: +MrFuppes ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue45355] Use sizeof(_Py_CODEUNIT) instead of literal 2 for the size of the code unit

2021-10-04 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +27067 pull_request: https://github.com/python/cpython/pull/28720 ___ Python tracker ___

[issue44831] Inconsistency between datetime.now() and datetime.fromtimestamp(time.time(), None)

2021-10-04 Thread STINNER Victor
STINNER Victor added the comment: > Since that time, I wrote a lot of time I wrote a lot of *code* :-) -- ___ Python tracker ___

[issue44831] Inconsistency between datetime.now() and datetime.fromtimestamp(time.time(), None)

2021-10-04 Thread STINNER Victor
STINNER Victor added the comment: > Presumably if we change these two to be consistent, this issue will go away. > I am not entirely sure if anyone is relying on a particular rounding behavior > for one or both of these, and I'm not sure which one is the right one to > harmonize on. We

[issue45355] Use sizeof(_Py_CODEUNIT) instead of literal 2 for the size of the code unit

2021-10-04 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +27066 pull_request: https://github.com/python/cpython/pull/28718 ___ Python tracker ___

[issue45356] Calling `help` executes @classmethod @property decorated methods

2021-10-04 Thread Dong-hee Na
Change by Dong-hee Na : -- nosy: +corona10 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue41197] Async magic methods in contextlib.closing

2021-10-04 Thread Nathaniel Smith
Change by Nathaniel Smith : -- resolution: -> duplicate stage: -> resolved status: open -> closed ___ Python tracker ___ ___

[issue44594] AsyncExitStack.enter_async_context() is mishandling exception __context__

2021-10-04 Thread Nathaniel Smith
Nathaniel Smith added the comment: New changeset e6d1aa1ac65b6908fdea2c70ec3aa8c4f1dffcb5 by John Belmonte in branch 'main': bpo-44594: fix (Async)ExitStack handling of __context__ (gh-27089) https://github.com/python/cpython/commit/e6d1aa1ac65b6908fdea2c70ec3aa8c4f1dffcb5 --

[issue45361] Provide a more convenient way to set an exception as "active", from Python code

2021-10-04 Thread Nathaniel Smith
Nathaniel Smith added the comment: Ugh, the gnarly ExitStack bug is bpo-44594, not whatever I wrote above -- ___ Python tracker ___

[issue45361] Provide a more convenient way to set an exception as "active", from Python code

2021-10-04 Thread Nathaniel Smith
New submission from Nathaniel Smith : Inside 'except' and 'finally' blocks, the interpreter keeps track of the 'active exception in the thread-state. It can be introspected via `sys.exc_info()`, it enables bare `raise`, and it triggers implicit context propagation. In an odd bit of

[issue45360] xml.etree.ElementTree: add feature in write to create directories also like mkdir -p

2021-10-04 Thread Terunobu Inaba
New submission from Terunobu Inaba : In the xml.etree.ElementTree module, the function "write(args)" (https://docs.python.org/ja/3/library/xml.etree.elementtree.html) does not seem to have a function like "-p" in "mkdir -p" in UNIX system, i.e., it will raise an error when some directories