diff --git a/django/contrib/gis/gdal/__init__.py b/django/contrib/gis/gdal/__init__.py index de41df90ff..c33fbcb97a 100644 --- a/django/contrib/gis/gdal/__init__.py +++ b/django/contrib/gis/gdal/__init__.py @@ -37,7 +37,7 @@ try: from django.contrib.gis.gdal.driver import Driver from django.contrib.gis.gdal.datasource import DataSource - from django.contrib.gis.gdal.libgdal import gdal_version, gdal_full_version, gdal_release_date, GDAL_VERSION + from django.contrib.gis.gdal.libgdal import gdal_version, gdal_full_version, GDAL_VERSION from django.contrib.gis.gdal.srs import SpatialReference, CoordTransform from django.contrib.gis.gdal.geometries import OGRGeometry HAS_GDAL = True diff --git a/django/contrib/gis/gdal/libgdal.py b/django/contrib/gis/gdal/libgdal.py index 0d2889d704..865c04d89e 100644 --- a/django/contrib/gis/gdal/libgdal.py +++ b/django/contrib/gis/gdal/libgdal.py @@ -73,19 +73,6 @@ def gdal_full_version(): "Returns the full GDAL version information." return _version_info('') -def gdal_release_date(date=False): - """ - Returns the release date in a string format, e.g, "2007/06/27". - If the date keyword argument is set to True, a Python datetime object - will be returned instead. - """ - from datetime import date as date_type - rel = _version_info('RELEASE_DATE') - yy, mm, dd = map(int, (rel[0:4], rel[4:6], rel[6:8])) - d = date_type(yy, mm, dd) - if date: return d - else: return d.strftime('%Y/%m/%d') - version_regex = re.compile(r'^(?P\d+)\.(?P\d+)(\.(?P\d+))?') def gdal_version_info(): ver = gdal_version().decode()