4 ms·
It'd be nice if Datasette provided support for other file formats than SQLite. I made https://github.com/pytables/datasette-connectors https://github.com/pytabl
by jsancho 6y ago
It'd be nice if Datasette provided support for other file formats than SQLite. I made https://github.com/pytables/datasette-connectors https://github.com/pytables/datasette-connectors that gives a simple API for making "connectors" for other formats by monkey patching Datasette, but it'd be more efficient if Datasette included that API (or something similar) directly.
For example, https://github.com/pytables/datasette-pytables https://github.com/pytables/datasette-pytables implements a connector for HDF5 files. You can read how to make a connector for your favorite file format in https://github.com/PyTables/datasette-connectors/blob/master/DEVELOPERS.md https://github.com/PyTables/datasette-connectors/blob/master...
Currently, datasette-connectors supports Datasette 0.51.1 but every few months an update is needed in order to be compatible with last versions.
I wonder if it'd be possible to merge datasette-connectors into Datasette. Then, "connectors" could be like other plugins and people could publish their data in a wider variety of ways.
- simonw 6y agoI'm coming around to this idea now - originally I avoided having Datasette work with anything other than SQLite because maintaining a database abstraction layer is an enormous amount of work, but now that I have a couple of years experience with Datasette plugins I'm thinking it may be possible to delegate that complexity to plugins and still keep Datasette's core relative clean and straight-forward to maintain. I'll absolutely let you know if this starts to come together. I'm planning to target PostgreSQL as the first plugin to help flesh out the integration points.