Victor Stinner
Victor Stinner
PR rebased on main to fix a merge conflict.
I created a C API Working Group issue: https://github.com/capi-workgroup/decisions/issues/39
Microbenchmark comparing bytearray to PyBytesWriter API: * [bench.patch](https://github.com/user-attachments/files/16521467/bench.patch.txt) * [bench.py](https://github.com/user-attachments/files/16521471/bench.py.txt) Result: ``` $ env/bin/python bench.py bytearray: Mean +- std dev: 93.0 ns +- 1.4 ns byteswriter: Mean +- std dev:...
> min_size -> unused: the user can be track this separately It's used if you call Prepare() multiple times. > use_small_buffer, small_buffer - unused: small buffer is just an initial...
I decided to reject this API for now. It's too low-level and too error prone: https://github.com/capi-workgroup/decisions/issues/39#issuecomment-2396888574
> I see the above and a failure in test_exposed_globals_in_repl on M1 Mac and my old Dell running Ubuntu. Happy to provide more details if needed, but it sounds like...
Fixed by change https://github.com/python/cpython/commit/68e279b37aae3019979a05ca55f462b11aac14be.
A code search on `_PyArg_Parser` in PyPI top 8,000 projects (2023-11-15) found 5 projects: * multidict (6.0.4) * multiprocess (0.70.15) * mypy (1.7.0) * orjson (3.9.10) * pickle5 (0.0.12)
What I'm trying to do here is to list projects using these projects, see how they use the API, and which public API is needed. > Anecdotally, we make extensive...
@AdamWill: > blender also uses _PyArg_Parser extensively: https://projects.blender.org/blender/blender/search?q=_PyArg_Parser . I am not enough of a C coder to know how easy it would be to port all those uses to...