Projects
Eulaceura:Factory
python-h5py
_service:obs_scm:Fix-compiling-fileobj-file-dri...
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File _service:obs_scm:Fix-compiling-fileobj-file-driver-with-Cython-3.0.patch of Package python-h5py
From b8cc539ce501f95b7f9720b318c54672c512ec16 Mon Sep 17 00:00:00 2001 From: Thomas Kluyver <thomas@kluyver.me.uk> Date: Thu, 5 Oct 2023 12:44:12 +0100 Subject: [PATCH] Fix compiling fileobj file driver with Cython 3.0 --- h5py/api_types_hdf5.pxd | 24 ++++++++++++------------ h5py/h5fd.pyx | 4 ++-- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/h5py/api_types_hdf5.pxd b/h5py/api_types_hdf5.pxd index f3d537c4..a1369e8a 100644 --- a/h5py/api_types_hdf5.pxd +++ b/h5py/api_types_hdf5.pxd @@ -257,27 +257,27 @@ cdef extern from "hdf5.h": herr_t (*sb_encode)(H5FD_t *file, char *name, unsigned char *p) herr_t (*sb_decode)(H5FD_t *f, const char *name, const unsigned char *p) size_t fapl_size - void * (*fapl_get)(H5FD_t *file) - void * (*fapl_copy)(const void *fapl) - herr_t (*fapl_free)(void *fapl) + void * (*fapl_get)(H5FD_t *file) except * + void * (*fapl_copy)(const void *fapl) except * + herr_t (*fapl_free)(void *fapl) except * size_t dxpl_size void * (*dxpl_copy)(const void *dxpl) herr_t (*dxpl_free)(void *dxpl) - H5FD_t *(*open)(const char *name, unsigned flags, hid_t fapl, haddr_t maxaddr) - herr_t (*close)(H5FD_t *file) + H5FD_t *(*open)(const char *name, unsigned flags, hid_t fapl, haddr_t maxaddr) except * + herr_t (*close)(H5FD_t *file) except * int (*cmp)(const H5FD_t *f1, const H5FD_t *f2) herr_t (*query)(const H5FD_t *f1, unsigned long *flags) herr_t (*get_type_map)(const H5FD_t *file, H5FD_mem_t *type_map) haddr_t (*alloc)(H5FD_t *file, H5FD_mem_t type, hid_t dxpl_id, hsize_t size) herr_t (*free)(H5FD_t *file, H5FD_mem_t type, hid_t dxpl_id, haddr_t addr, hsize_t size) - haddr_t (*get_eoa)(const H5FD_t *file, H5FD_mem_t type) - herr_t (*set_eoa)(H5FD_t *file, H5FD_mem_t type, haddr_t addr) - haddr_t (*get_eof)(const H5FD_t *file, H5FD_mem_t type) + haddr_t (*get_eoa)(const H5FD_t *file, H5FD_mem_t type) except * + herr_t (*set_eoa)(H5FD_t *file, H5FD_mem_t type, haddr_t addr) except * + haddr_t (*get_eof)(const H5FD_t *file, H5FD_mem_t type) except * herr_t (*get_handle)(H5FD_t *file, hid_t fapl, void**file_handle) - herr_t (*read)(H5FD_t *file, H5FD_mem_t type, hid_t dxpl, haddr_t addr, size_t size, void *buffer) - herr_t (*write)(H5FD_t *file, H5FD_mem_t type, hid_t dxpl, haddr_t addr, size_t size, const void *buffer) - herr_t (*flush)(H5FD_t *file, hid_t dxpl_id, hbool_t closing) - herr_t (*truncate)(H5FD_t *file, hid_t dxpl_id, hbool_t closing) + herr_t (*read)(H5FD_t *file, H5FD_mem_t type, hid_t dxpl, haddr_t addr, size_t size, void *buffer) except * + herr_t (*write)(H5FD_t *file, H5FD_mem_t type, hid_t dxpl, haddr_t addr, size_t size, const void *buffer) except * + herr_t (*flush)(H5FD_t *file, hid_t dxpl_id, hbool_t closing) except * + herr_t (*truncate)(H5FD_t *file, hid_t dxpl_id, hbool_t closing) except * herr_t (*lock)(H5FD_t *file, hbool_t rw) herr_t (*unlock)(H5FD_t *file) H5FD_mem_t fl_map[<int>H5FD_MEM_NTYPES] diff --git a/h5py/h5fd.pyx b/h5py/h5fd.pyx index e9746057..f1b4aade 100644 --- a/h5py/h5fd.pyx +++ b/h5py/h5fd.pyx @@ -144,10 +144,10 @@ cdef herr_t H5FD_fileobj_close(H5FD_fileobj_t *f) except -1 with gil: stdlib_free(f) return 0 -cdef haddr_t H5FD_fileobj_get_eoa(const H5FD_fileobj_t *f, H5FD_mem_t type): +cdef haddr_t H5FD_fileobj_get_eoa(const H5FD_fileobj_t *f, H5FD_mem_t type) noexcept nogil: return f.eoa -cdef herr_t H5FD_fileobj_set_eoa(H5FD_fileobj_t *f, H5FD_mem_t type, haddr_t addr): +cdef herr_t H5FD_fileobj_set_eoa(H5FD_fileobj_t *f, H5FD_mem_t type, haddr_t addr) noexcept nogil: f.eoa = addr return 0 -- 2.40.1
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.
浙ICP备2022010568号-2