mirror of https://github.com/django/django.git
Fixed #33577 -- Confirmed support for GDAL 3.4.
This commit is contained in:
parent
3b3f38b3b0
commit
970f5bf503
|
@ -22,6 +22,7 @@ if lib_path:
|
|||
elif os.name == "nt":
|
||||
# Windows NT shared libraries
|
||||
lib_names = [
|
||||
"gdal304",
|
||||
"gdal303",
|
||||
"gdal302",
|
||||
"gdal301",
|
||||
|
@ -35,6 +36,7 @@ elif os.name == "posix":
|
|||
lib_names = [
|
||||
"gdal",
|
||||
"GDAL",
|
||||
"gdal3.4.0",
|
||||
"gdal3.3.0",
|
||||
"gdal3.2.0",
|
||||
"gdal3.1.0",
|
||||
|
|
|
@ -5,16 +5,16 @@ Installing Geospatial libraries
|
|||
GeoDjango uses and/or provides interfaces for the following open source
|
||||
geospatial libraries:
|
||||
|
||||
======================== ==================================== ================================ =================================
|
||||
======================== ==================================== ================================ ======================================
|
||||
Program Description Required Supported Versions
|
||||
======================== ==================================== ================================ =================================
|
||||
======================== ==================================== ================================ ======================================
|
||||
:doc:`GEOS <../geos>` Geometry Engine Open Source Yes 3.10, 3.9, 3.8, 3.7, 3.6
|
||||
`PROJ`_ Cartographic Projections library Yes (PostgreSQL and SQLite only) 8.x, 7.x, 6.x, 5.x, 4.x
|
||||
:doc:`GDAL <../gdal>` Geospatial Data Abstraction Library Yes 3.3, 3.2, 3.1, 3.0, 2.4, 2.3, 2.2
|
||||
:doc:`GDAL <../gdal>` Geospatial Data Abstraction Library Yes 3.4, 3.3, 3.2, 3.1, 3.0, 2.4, 2.3, 2.2
|
||||
:doc:`GeoIP <../geoip2>` IP-based geolocation library No 2
|
||||
`PostGIS`__ Spatial extensions for PostgreSQL Yes (PostgreSQL only) 3.2, 3.1, 3.0, 2.5, 2.4
|
||||
`SpatiaLite`__ Spatial extensions for SQLite Yes (SQLite only) 5.0, 4.3
|
||||
======================== ==================================== ================================ =================================
|
||||
======================== ==================================== ================================ ======================================
|
||||
|
||||
Note that older or more recent versions of these libraries *may* also work
|
||||
totally fine with GeoDjango. Your mileage may vary.
|
||||
|
@ -33,6 +33,7 @@ totally fine with GeoDjango. Your mileage may vary.
|
|||
GDAL 3.1.0 2020-05-07
|
||||
GDAL 3.2.0 2020-11-02
|
||||
GDAL 3.3.0 2021-05-03
|
||||
GDAL 3.4.0 2021-11-04
|
||||
PostGIS 2.4.0 2017-09-30
|
||||
PostGIS 2.5.0 2018-09-23
|
||||
PostGIS 3.0.0 2019-10-20
|
||||
|
|
|
@ -807,8 +807,13 @@ class GDALBandTests(SimpleTestCase):
|
|||
band = rs.bands[0]
|
||||
|
||||
# Setting attributes in write mode raises exception in the _flush method
|
||||
with self.assertRaises(GDALException):
|
||||
setattr(band, "nodata_value", 10)
|
||||
try:
|
||||
with self.assertRaises(GDALException):
|
||||
setattr(band, "nodata_value", 10)
|
||||
finally:
|
||||
pam_file = self.rs_path + ".aux.xml"
|
||||
if os.path.isfile(pam_file):
|
||||
os.remove(pam_file)
|
||||
|
||||
def test_band_data_setters(self):
|
||||
# Create in-memory raster and get band
|
||||
|
|
|
@ -143,8 +143,8 @@ class OGRInspectTest(SimpleTestCase):
|
|||
|
||||
# The ordering of model fields might vary depending on several factors
|
||||
# (version of GDAL, etc.).
|
||||
if connection.vendor == "sqlite":
|
||||
# SpatiaLite introspection is somewhat lacking (#29461).
|
||||
if connection.vendor == "sqlite" and GDAL_VERSION < (3, 4):
|
||||
# SpatiaLite introspection is somewhat lacking on GDAL < 3.4 (#29461).
|
||||
self.assertIn(" f_decimal = models.CharField(max_length=0)", model_def)
|
||||
else:
|
||||
self.assertIn(
|
||||
|
@ -156,7 +156,7 @@ class OGRInspectTest(SimpleTestCase):
|
|||
# Probably a bug between GDAL and MariaDB on time fields.
|
||||
self.assertIn(" f_datetime = models.DateTimeField()", model_def)
|
||||
self.assertIn(" f_time = models.TimeField()", model_def)
|
||||
if connection.vendor == "sqlite":
|
||||
if connection.vendor == "sqlite" and GDAL_VERSION < (3, 4):
|
||||
self.assertIn(" f_float = models.CharField(max_length=0)", model_def)
|
||||
else:
|
||||
self.assertIn(" f_float = models.FloatField()", model_def)
|
||||
|
|
Loading…
Reference in New Issue