From 2a2261e1bb866d5fa0f77840aa71ca5b6db956e1 Mon Sep 17 00:00:00 2001 From: Patrick Donnelly Date: Tue, 4 Mar 2025 09:45:23 -0500 Subject: [PATCH] pybind/cephfs: use legacy noexcept for cdefs for cython 3.Y.Z For some newer versions of cython, it appears it requires explicitly specifying noexcept but old versions of Cython 0.29.Z do not understand that attribute. See: https://cython.readthedocs.io/en/latest/src/userguide/migrating_to_cy30.html#exception-values-and-noexcept Signed-off-by: Patrick Donnelly (cherry picked from commit 90ac7409279d103f8811cf31f3a530d8fff7ba12) --- src/pybind/cephfs/c_cephfs.pxd | 3 +++ src/pybind/cephfs/cephfs.pyx | 3 +++ 2 files changed, 6 insertions(+) diff --git a/src/pybind/cephfs/c_cephfs.pxd b/src/pybind/cephfs/c_cephfs.pxd index ddb2659a4df..30e9a246d33 100644 --- a/src/pybind/cephfs/c_cephfs.pxd +++ b/src/pybind/cephfs/c_cephfs.pxd @@ -1,3 +1,6 @@ +# cython: language_level=3 +# cython: legacy_implicit_noexcept=True + from libc.stdint cimport * from types cimport * diff --git a/src/pybind/cephfs/cephfs.pyx b/src/pybind/cephfs/cephfs.pyx index 6599beb4c27..9a4b5c778b3 100644 --- a/src/pybind/cephfs/cephfs.pyx +++ b/src/pybind/cephfs/cephfs.pyx @@ -1,3 +1,6 @@ +# cython: language_level=3 +# cython: legacy_implicit_noexcept=True + """ This module is a thin wrapper around libcephfs. """ -- 2.39.5