Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
django
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
django
Commits
fd866c25
Kaydet (Commit)
fd866c25
authored
Eyl 30, 2017
tarafından
Tim Graham
Kaydeden (comit)
GitHub
Eyl 30, 2017
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fixed #28654 -- Dropped support for SpatiaLite 4.0.
üst
dd82f332
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
13 additions
and
18 deletions
+13
-18
base.py
django/contrib/gis/db/backends/spatialite/base.py
+1
-2
features.py
django/contrib/gis/db/backends/spatialite/features.py
+0
-7
introspection.py
django/contrib/gis/db/backends/spatialite/introspection.py
+3
-3
operations.py
django/contrib/gis/db/backends/spatialite/operations.py
+2
-3
geolibs.txt
docs/ref/contrib/gis/install/geolibs.txt
+1
-2
index.txt
docs/ref/contrib/gis/install/index.txt
+1
-1
2.1.txt
docs/releases/2.1.txt
+5
-0
No files found.
django/contrib/gis/db/backends/spatialite/base.py
Dosyayı görüntüle @
fd866c25
...
...
@@ -61,5 +61,4 @@ class DatabaseWrapper(SQLiteDatabaseWrapper):
with
self
.
cursor
()
as
cursor
:
cursor
.
execute
(
"PRAGMA table_info(geometry_columns);"
)
if
cursor
.
fetchall
()
==
[]:
arg
=
"1"
if
self
.
features
.
supports_initspatialmetadata_in_one_transaction
else
""
cursor
.
execute
(
"SELECT InitSpatialMetaData(
%
s)"
%
arg
)
cursor
.
execute
(
"SELECT InitSpatialMetaData(1)"
)
django/contrib/gis/db/backends/spatialite/features.py
Dosyayı görüntüle @
fd866c25
...
...
@@ -8,13 +8,6 @@ from django.utils.functional import cached_property
class
DatabaseFeatures
(
BaseSpatialFeatures
,
SQLiteDatabaseFeatures
):
supports_3d_storage
=
True
@cached_property
def
supports_initspatialmetadata_in_one_transaction
(
self
):
# SpatiaLite 4.1+ support initializing all metadata in one transaction
# which can result in a significant performance improvement when
# creating the database.
return
self
.
connection
.
ops
.
spatial_version
>=
(
4
,
1
,
0
)
@cached_property
def
supports_area_geodetic
(
self
):
return
bool
(
self
.
connection
.
ops
.
lwgeom_version
())
django/contrib/gis/db/backends/spatialite/introspection.py
Dosyayı görüntüle @
fd866c25
...
...
@@ -41,9 +41,9 @@ class SpatiaLiteIntrospection(DatabaseIntrospection):
# from OGC geom type name to Django field.
ogr_type
=
row
[
2
]
if
isinstance
(
ogr_type
,
int
)
and
ogr_type
>
1000
:
# SpatiaLite
versions >= 4 use the new SFSQL 1.2 offsets
#
1000 (Z), 2000 (M), and 3000 (ZM) to indicate the presence of
#
higher dimensional
coordinates (M not yet supported by Django).
# SpatiaLite
uses SFSQL 1.2 offsets 1000 (Z), 2000 (M), and
#
3000 (ZM) to indicate the presence of higher dimensional
# coordinates (M not yet supported by Django).
ogr_type
=
ogr_type
%
1000
+
OGRGeomType
.
wkb25bit
field_type
=
OGRGeomType
(
ogr_type
)
.
django
...
...
django/contrib/gis/db/backends/spatialite/operations.py
Dosyayı görüntüle @
fd866c25
"""
SQL functions reference lists:
https://web.archive.org/web/20130407175746/https://www.gaia-gis.it/gaia-sins/spatialite-sql-4.0.0.html
https://www.gaia-gis.it/gaia-sins/spatialite-sql-4.2.1.html
"""
from
django.contrib.gis.db.backends.base.operations
import
(
...
...
@@ -96,8 +95,8 @@ class SpatiaLiteOperations(BaseSpatialOperations, DatabaseOperations):
self
.
connection
.
settings_dict
[
'NAME'
],
)
)
from
exc
if
version
<
(
4
,
0
,
0
):
raise
ImproperlyConfigured
(
'GeoDjango only supports SpatiaLite versions 4.
0
.0 and above.'
)
if
version
<
(
4
,
1
,
0
):
raise
ImproperlyConfigured
(
'GeoDjango only supports SpatiaLite versions 4.
1
.0 and above.'
)
return
version
def
convert_extent
(
self
,
box
):
...
...
docs/ref/contrib/gis/install/geolibs.txt
Dosyayı görüntüle @
fd866c25
...
...
@@ -13,7 +13,7 @@ Program Description Required
:doc:`GDAL <../gdal>` Geospatial Data Abstraction Library Yes 2.2, 2.1, 2.0, 1.11, 1.10, 1.9
:doc:`GeoIP <../geoip2>` IP-based geolocation library No 2
`PostGIS`__ Spatial extensions for PostgreSQL Yes (PostgreSQL only) 2.3, 2.2, 2.1
`SpatiaLite`__ Spatial extensions for SQLite Yes (SQLite only) 4.3, 4.2, 4.1
, 4.0
`SpatiaLite`__ Spatial extensions for SQLite Yes (SQLite only) 4.3, 4.2, 4.1
======================== ==================================== ================================ ===================================
Note that older or more recent versions of these libraries *may* also work
...
...
@@ -32,7 +32,6 @@ totally fine with GeoDjango. Your mileage may vary.
PostGIS 2.1.0 2013-08-17
PostGIS 2.2.0 2015-10-17
PostGIS 2.3.0 2016-09-26
SpatiaLite 4.0.0 2012-11-25
SpatiaLite 4.1.0 2013-06-04
SpatiaLite 4.2.0 2014-07-25
SpatiaLite 4.3.0 2015-09-07
...
...
docs/ref/contrib/gis/install/index.txt
Dosyayı görüntüle @
fd866c25
...
...
@@ -61,7 +61,7 @@ Database Library Requirements Supported Versions Notes
PostgreSQL GEOS, GDAL, PROJ.4, PostGIS 9.4+ Requires PostGIS.
MySQL GEOS, GDAL 5.6+ Not OGC-compliant; :ref:`limited functionality <mysql-spatial-limitations>`.
Oracle GEOS, GDAL 12.1+ XE not supported.
SQLite GEOS, GDAL, PROJ.4, SpatiaLite 3.6.+ Requires SpatiaLite 4.
0
+
SQLite GEOS, GDAL, PROJ.4, SpatiaLite 3.6.+ Requires SpatiaLite 4.
1
+
================== ============================== ================== =========================================
See also `this comparison matrix`__ on the OSGeo Wiki for
...
...
docs/releases/2.1.txt
Dosyayı görüntüle @
fd866c25
...
...
@@ -200,6 +200,11 @@ Database backend API
* ...
:mod:`django.contrib.gis`
-------------------------
* Support for SpatiaLite 4.0 is removed.
Dropped support for MySQL 5.5
-----------------------------
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment