REF: set language level in cythonize options in setup.py (#2241)

This commit is contained in:
Alan D. Snow 2021-07-19 15:43:18 -05:00 committed by GitHub
parent 112df9bab9
commit e16206791d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
19 changed files with 7 additions and 29 deletions

View File

@ -1,5 +1,3 @@
# cython: language_level=3
include "gdal.pxi"

View File

@ -1,4 +1,4 @@
# cython: language_level=3, boundscheck=False, c_string_type=unicode, c_string_encoding=utf8"""
# cython: boundscheck=False, c_string_type=unicode, c_string_encoding=utf8"""
"""Numpy-free base classes."""

View File

@ -1,5 +1,3 @@
# cython: language_level=3
include "gdal.pxi"

View File

@ -1,4 +1,4 @@
# cython: language_level=3, boundscheck=False
# cython: boundscheck=False
"""Coordinate reference systems, class and functions.
"""

View File

@ -1,6 +1,6 @@
# cython: language_level=3
include "gdal.pxi"
cdef class ConfigEnv:
cdef public object options

View File

@ -1,4 +1,4 @@
# cython: language_level=3, c_string_type=unicode, c_string_encoding=utf8
# cython: c_string_type=unicode, c_string_encoding=utf8
"""GDAL and OGR driver and configuration management

View File

@ -1,5 +1,3 @@
# cython: language_level=3
include "gdal.pxi"
from libc.stdio cimport *

View File

@ -1,5 +1,3 @@
# cython: language_level=3
"""rasterio._err
Exception-raising wrappers for GDAL API functions.

View File

@ -1,5 +1,3 @@
# cython: language_level=3
include "gdal.pxi"

View File

@ -1,5 +1,3 @@
# cython: language_level=3
"""Feature extraction"""
import logging

View File

@ -1,4 +1,3 @@
# cython: language_level=3
# distutils: language = c++
"""Raster fill."""

View File

@ -1,5 +1,3 @@
# cython: language_level=3
include "gdal.pxi"
cimport numpy as np

View File

@ -1,4 +1,4 @@
# cython: language_level=3, boundscheck=False
# cython: boundscheck=False
"""Rasterio input/output."""

View File

@ -1,4 +1,4 @@
# cython: language_level=3, boundscheck=False, c_string_type=unicode, c_string_encoding=utf8
# cython: boundscheck=False, c_string_type=unicode, c_string_encoding=utf8
"""Transforms."""

View File

@ -1,5 +1,3 @@
# cython: language_level=3
from rasterio._io cimport DatasetReaderBase
include "gdal.pxi"

View File

@ -1,4 +1,3 @@
# cython: language_level=3
# distutils: language = c++
"""Raster and vector warping and reprojection."""

View File

@ -1,5 +1,3 @@
# cython: language_level=3
# GDAL API definitions.
from libc.stdio cimport FILE

View File

@ -1,5 +1,3 @@
# cython: language_level=3
"""Raster file management."""
include "gdal.pxi"

View File

@ -210,7 +210,7 @@ if (gdal_major_version, gdal_minor_version) >= (2, 3):
cpp_ext_options['extra_compile_args'] = eca
# Configure optional Cython coverage.
cythonize_options = {}
cythonize_options = {"language_level": sys.version_info[0]}
if os.environ.get('CYTHON_COVERAGE'):
cythonize_options['compiler_directives'] = {'linetrace': True}
cythonize_options['annotate'] = True