Skip to content

Conversation

antonio-rojas
Copy link
Contributor

@antonio-rojas antonio-rojas commented May 24, 2025

In Cython 3.1 binary operations are no longer wrappers, but methods. This breaks wrapperdescr_fastcall.

Since this was rather hackish anyway, we replace its few uses by explicit coercions.

We also switch some modules to compile with binding=True, this fixes many errors with 3.1.

In Cython 3.1 binary operations are no longer wrappers, but methods. This breaks wrapperdescr_fastcall.

Since this was rather hackish anyway, we replace its few uses by explicit coercions.
@antonio-rojas antonio-rojas changed the title Drop wrapperdescr_fastcall usage for Cython 3.1 compatibility Support Cython 3.11 May 26, 2025
@antonio-rojas antonio-rojas changed the title Support Cython 3.11 Support Cython 3.1 May 26, 2025
@dimpase
Copy link
Member

dimpase commented May 27, 2025

Does this mean we cannot use Cython 3.0 any more? If so, this has to be reflected in build/pkgs/cython/

@antonio-rojas
Copy link
Contributor Author

Does this mean we cannot use Cython 3.0 any more? If so, this has to be reflected in build/pkgs/cython/

No, this should work just fine with 3.0 (all the conda CIs are green and they use 3.0 AFAIK)

@dimpase
Copy link
Member

dimpase commented May 27, 2025

OK

vbraun pushed a commit to vbraun/sage that referenced this pull request May 28, 2025
sagemathgh-40156: Support Cython 3.1
    
In Cython 3.1 binary operations are no longer wrappers, but methods.
This breaks wrapperdescr_fastcall.

Since this was rather hackish anyway, we replace its few uses by
explicit coercions.

We also switch some modules to compile with `binding=True`, this fixes
many errors with 3.1.
    
URL: sagemath#40156
Reported by: Antonio Rojas
Reviewer(s): Dima Pasechnik
@vbraun vbraun merged commit 5ea8db2 into sagemath:develop Jun 1, 2025
15 of 24 checks passed
@antonio-rojas antonio-rojas deleted the cython-3.1 branch June 2, 2025 06:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants