Victor Stinner

Results 702 comments of Victor Stinner

@ambv: Do you have an idea on how to fix mypy?

> @vstinner Using from . import _CAN_USE_PYREPL instead of import _pyrepl seems to work. In that case, `_CAN_USE_PYREPL = False` only sets the variable in ``__main__.py``, not in ``__init__.py``.

I rewrote the fix to please the typing gods.

Sorry, I didn't retest functionally after fixing mypy 😬

Please check my second fix: PR gh-119332.

The private `_PyHASH_MULTIPLIER` constant was removed in Python 3.13 alpha 1, but [had to be reverted](https://github.com/python/cpython/pull/112115) since it broke too many projects. A code search on PyPI top 7,500 projects...

> This makes sense, no harm in this being public even if I think it is odd that anyone uses it. It's a good prime number to increase to implement...

> (I'll confess that I've never seen this need in practice I don't know about the specific case of floating point objects, but the constant is used by at least...

You can already call `PyObject_CallMethod(your_list, "remove", "O", object_to_remove)`. I don't think that such function call is common enough to justify adding a C API for it. I close the issue...