Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Removed unused and undocumented gdal_release_date function

  • Loading branch information...
commit 0ad6d7e61294befd5868c5ab422669d9ef3db52f 1 parent a1a5c08
@claudep claudep authored
View
2  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
View
13 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<major>\d+)\.(?P<minor>\d+)(\.(?P<subminor>\d+))?')
def gdal_version_info():
ver = gdal_version().decode()
Please sign in to comment.
Something went wrong with that request. Please try again.