mirror of
https://github.com/simonw/datasette.git
synced 2025-12-10 16:51:24 +01:00
Build Dockerfile with recent Sqlite + Spatialite (#280)
Closes #278 ```bash $ docker run --rm -it datasette spatialite SpatiaLite version ..: 4.4.0-RC0 Supported Extensions: - 'VirtualShape' [direct Shapefile access] - 'VirtualDbf' [direct DBF access] - 'VirtualXL' [direct XLS access] - 'VirtualText' [direct CSV/TXT access] - 'VirtualNetwork' [Dijkstra shortest path] - 'RTree' [Spatial Index - R*Tree] - 'MbrCache' [Spatial Index - MBR cache] - 'VirtualSpatialIndex' [R*Tree metahandler] - 'VirtualElementary' [ElemGeoms metahandler] - 'VirtualKNN' [K-Nearest Neighbors metahandler] - 'VirtualXPath' [XML Path Language - XPath] - 'VirtualFDO' [FDO-OGR interoperability] - 'VirtualGPKG' [OGC GeoPackage interoperability] - 'VirtualBBox' [BoundingBox tables] - 'SpatiaLite' [Spatial SQL - OGC] PROJ.4 version ......: Rel. 4.9.3, 15 August 2016 GEOS version ........: 3.5.1-CAPI-1.9.1 r4246 TARGET CPU ..........: x86_64-linux-gnu the SPATIAL_REF_SYS table already contains some row(s) SQLite version ......: 3.23.1 Enter ".help" for instructions SQLite version 3.23.1 2018-04-10 17:39:29 Enter ".help" for instructions Enter SQL statements terminated with a ";" spatialite> ``` ```bash $ docker run --rm -it datasette python -c "import sqlite3; print(sqlite3.sqlite_version)" 3.23.1 ``` Also updates the query used to check for FTS5 as the old version wasn't detecting FTS5 for some reason.
This commit is contained in:
parent
5d62527882
commit
bd30c696e1
2 changed files with 27 additions and 6 deletions
|
|
@ -256,7 +256,7 @@ class Datasette:
|
|||
for fts in ("FTS5", "FTS4", "FTS3"):
|
||||
try:
|
||||
conn.execute(
|
||||
"CREATE VIRTUAL TABLE v{fts} USING {fts} (t TEXT)".format(fts=fts)
|
||||
"CREATE VIRTUAL TABLE v{fts} USING {fts} (data)".format(fts=fts)
|
||||
)
|
||||
fts_versions.append(fts)
|
||||
except sqlite3.OperationalError:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue