MCPcopy
hub / github.com/django/django / gdal_version_info

Function gdal_version_info

django/contrib/gis/gdal/libgdal.py:114–120  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

112
113
114def gdal_version_info():
115 ver = gdal_version()
116 m = re.match(rb"^(?P<major>\d+)\.(?P<minor>\d+)(?:\.(?P<subminor>\d+))?", ver)
117 if not m:
118 raise GDALException('Could not parse GDAL version string "%s"' % ver)
119 major, minor, subminor = m.groups()
120 return (int(major), int(minor), subminor and int(subminor))
121
122
123GDAL_VERSION = gdal_version_info()

Callers 1

libgdal.pyFile · 0.85

Calls 4

GDALExceptionClass · 0.90
gdal_versionFunction · 0.85
groupsMethod · 0.80
matchMethod · 0.45

Tested by

no test coverage detected