What does HackerNews think of hpy?

HPy: a better API for Python

Language: Python

Now could be a good time to make this change, in coordination with HPy: https://github.com/hpyproject/hpy

I agree though — it’s tempting to keep extending and stretching the language to be something it was never designed for; but at some point it’s been stretched so far it loses the properties that made it attractive to start with. I like Python, but some of the things people are using it for now, they should really consider another language instead, and write a Python wrapper on top of that if they must use it from Python.

There are projects[1] that are abstracting away the C extension interface in order to standardize C extensions across implementations and prevent breaking changes.

[1] https://github.com/hpyproject/hpy

> I think one could radically change the way Python objects work internally, and have the C foreign function interface (FFI) wrap every object passed to a C extension in an API/ABI-preserving facade

HPy is building an API abstraction layer which is designed to be used with both the CPython API and JITs. However, IIUC they are not proposing any changes to CPython itself, but rather to provide a smaller API surface and fewer JIT impedance mismatches when extensions are built against something other than CPython. The lead developer is a longtime PyPy developer.

https://hpyproject.org/ (https://github.com/hpyproject/hpy)

Projects that depend on CPython C extensions should consider migrating to HPy[1] for C extension compatibility across Python implementations.

[1] https://github.com/hpyproject/hpy

> not fully compatible

It's really quite close, and https://github.com/hpyproject/hpy is intended to make them even closer.

He, Inada Naoki and Victor Stinner on the optimization front are some developers that are capable of pulling a JIT of CPython.

This is something that I feel that Python need to do to keep the relevance. .Net Core, Rust and GoLang are examples of modern languages that deliver on the performance front.

I love Python and it is what use everyday. But very often I feel the need to a better code generation. Numba and Cython feels like a glue. PyPy it is slow with extensions, and this is a huge part of Python ecosystem. Although HPy (https://github.com/hpyproject/hpy) is trying to change this.

I feel that this is a must to Python, and would love to contribute money to this task.