rowid,repo,release,date,body_markdown,published_at,topics 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.33,2019-12-22,"* `rowid` is now included in dropdown menus for filtering tables (#636) * Columns are now only suggested for faceting if they have at least one value with more than one record (#638) * Queries with no results now display “0 results” (#637) * Improved documentation for the `--static` option (#641) * asyncio task information is now included on the `/-/threads` debug page * Bumped Uvicorn dependency 0.11 * You can now use `--port 0` to listen on an available port * New `template_debug` setting for debugging templates, e.g. https://latest.datasette.io/fixtures/roadside_attractions?_context=1 (#654) https://datasette.readthedocs.io/en/latest/changelog.html#v0-33",2019-12-22T16:43:31Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.32,2019-11-14,"Datasette now renders templates using [Jinja async mode](https://jinja.palletsprojects.com/en/2.10.x/api/#async-support). This makes it easy for plugins to provide custom template functions that perform asynchronous actions, for example the new [datasette-template-sql](https://github.com/simonw/datasette-template-sql) plugin which allows custom templates to directly execute SQL queries and render their results. (#628) https://datasette.readthedocs.io/en/latest/changelog.html#v0-32",2019-11-14T23:42:14Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.31.2,2019-11-13,"- Fixed a bug where datasette publish heroku applications failed to start (#633) - Fix for datasette publish with just --source_url - thanks, Stanley Zheng (#572) - Deployments to Heroku now use Python 3.8.0 (#632) https://datasette.readthedocs.io/en/latest/changelog.html#v0-31-2",2019-11-13T17:38:59Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.31.1,2019-11-13,"- Deployments created using `datasette publish` now use `python:3.8` base Docker image (#629) https://datasette.readthedocs.io/en/latest/changelog.html#v0-31-1",2019-11-13T02:40:53Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.31,2019-11-13,"This version adds compatibility with Python 3.8 and breaks compatibility with Python 3.5. Full release notes: https://datasette.readthedocs.io/en/stable/changelog.html#v0-31",2019-11-13T02:16:15Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.30.2,2019-11-02,https://datasette.readthedocs.io/en/latest/changelog.html#v0-30-2,2019-11-02T23:33:13Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.30.1,2019-11-02,https://datasette.readthedocs.io/en/stable/changelog.html#v0-30-1,2019-11-02T00:06:02Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.30,2019-10-30,https://datasette.readthedocs.io/en/stable/changelog.html#v0-30,2019-10-30T18:51:30Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.29.3,2019-10-18,https://datasette.readthedocs.io/en/stable/changelog.html#v0-29-3,2019-10-18T05:24:54Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.29.2,2019-09-03,"* Bumped Uvicorn to 0.8.4, fixing a bug where the querystring was not included in the server logs. (#559) * Fixed bug where the navigation breadcrumbs were not displayed correctly on the page for a custom query. (#558) * Fixed bug where custom query names containing unicode characters caused errors. https://datasette.readthedocs.io/en/stable/changelog.html#v0-29-2",2019-09-03T00:33:35Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.29.1,2019-07-14,"- Fixed bug with static mounts using relative paths which could lead to traversal exploits (#555) - thanks Abdussamet Kocak! https://datasette.readthedocs.io/en/stable/changelog.html#v0-29-1",2019-07-14T01:43:44Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.29,2019-07-08,"ASGI, new plugin hooks, facet by date and much, much more… See [the release notes](https://datasette.readthedocs.io/en/stable/changelog.html#v0-29) for full details.",2019-07-08T03:43:13Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.28,2019-05-19,"[Datasette 0.28](https://datasette.readthedocs.io/en/stable/changelog.html#v0-28) - a salmagundi of new features! * No longer immutable! Datasette now supports [databases that change](https://datasette.readthedocs.io/en/stable/changelog.html#supporting-databases-that-change). * [Faceting improvements](https://datasette.readthedocs.io/en/stable/changelog.html#faceting-improvements-and-faceting-plugins) including facet-by-JSON-array and the ability to define custom faceting using plugins. * [datasette publish cloudrun](https://datasette.readthedocs.io/en/stable/changelog.html#datasette-publish-cloudrun) lets you publish databasese to Google's new Cloud Run hosting service. * New [register_output_renderer](https://datasette.readthedocs.io/en/stable/changelog.html#register-output-renderer-plugins) plugin hook for adding custom output extensions to Datasette in addition to the default `.json` and `.csv`. * Dozens of other smaller features and tweaks - see [the release notes](https://datasette.readthedocs.io/en/stable/changelog.html#v0-28) for full details.",2019-05-19T21:42:28Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.27,2019-02-06,https://datasette.readthedocs.io/en/stable/changelog.html#v0-27,2019-02-06T05:10:20Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.26.1,2019-01-28,Release notes: https://datasette.readthedocs.io/en/stable/changelog.html#v0-26-1,2019-01-28T01:50:45Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.26,2019-01-10,[Datasette 0.26 release notes](https://datasette.readthedocs.io/en/stable/changelog.html#v0-26),2019-01-10T21:41:00Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.25.2,2018-12-16,"* `datasette publish heroku` now uses the `python-3.6.7` runtime * Added documentation on [how to build the documentation](https://datasette.readthedocs.io/en/stable/contributing.html#editing-and-building-the-documentation) * Added documentation covering [our release process](https://datasette.readthedocs.io/en/stable/contributing.html#release-process) * Upgraded to pytest 4.0.2 ",2018-12-16T21:45:39Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.25.1,2018-12-16,"Documentation improvements plus a fix for publishing to Zeit Now. * `datasette publish now` now uses Zeit’s v1 platform, to work around the new 100MB image limit. Thanks, @slygent - closes #366. ",2018-12-16T21:44:27Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.25,2018-09-19,"New plugin hooks, improved database view support and an easier way to use more recent versions of SQLite. See full release notes here: https://datasette.readthedocs.io/en/latest/changelog.html#v0-25",2018-09-19T18:27:21Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.24,2018-07-24,"See full release notes here: http://datasette.readthedocs.io/en/latest/changelog.html#v0-24 ",2018-07-24T16:51:29Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.23.2,2018-07-08,"Minor bugfix and documentation release. * CSV export now respects `--cors`, fixes #326 * [Installation instructions](https://datasette.readthedocs.io/en/latest/installation.html) including docker image - closes #328 * Fix for row pages for tables with / in, closes #325",2018-07-08T05:41:38Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.23.1,2018-06-21,"Minor bugfix release. * Correctly display empty strings in HTML table, closes #314 * Allow “.” in database filenames, closes #302 * 404s ending in slash redirect to remove that slash, closes #309 * Fixed incorrect display of compound primary keys with foreign key references. Closes #319 * Docs + example of canned SQL query using || concatenation. Closes #321 * Correctly display facets with value of 0 - closes #318 * Default ‘expand labels’ to checked in CSV advanced export ",2018-06-21T16:02:44Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.23,2018-06-18,"This release features CSV export, improved options for foreign key expansions, new configuration settings and improved support for SpatiaLite. See full release notes here: http://datasette.readthedocs.io/en/latest/changelog.html#v0-23",2018-06-18T15:28:37Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.22.1,2018-05-23,"Bugfix release, plus we now use [versioneer](https://github.com/warner/python-versioneer) for our version numbers. - Faceting no longer breaks pagination, fixes #282 - Add ``__version_info__`` derived from `__version__` [Robert Gieseke] This might be tuple of more than two values (major and minor version) if commits have been made after a release. - Add version number support with Versioneer. [Robert Gieseke] Versioneer Licence: Public Domain (CC0-1.0) Closes #273 - Refactor inspect logic [Russ Garrett]",2018-05-23T14:04:17Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.22,2018-05-20,"The big new feature in this release is [facets](http://datasette.readthedocs.io/en/latest/facets.html). Datasette can now apply faceted browse to any column in any table. It will also suggest possible facets. See the [Datasette Facets](https://simonwillison.net/2018/May/20/datasette-facets/) announcement post for more details. In addition to the work on facets: - Added [docs for introspection endpoints](https://datasette.readthedocs.io/en/latest/introspection.html) - New `--config` option, added `--help-config`, closes #274 Removed the `--page_size=` argument to `datasette serve` in favour of: datasette serve --config default_page_size:50 mydb.db Added new help section: $ datasette --help-config Config options: default_page_size Default page size for the table view (default=100) max_returned_rows Maximum rows that can be returned from a table or custom query (default=1000) sql_time_limit_ms Time limit for a SQL query in milliseconds (default=1000) default_facet_size Number of values to return for requested facets (default=30) facet_time_limit_ms Time limit for calculating a requested facet (default=200) facet_suggest_time_limit_ms Time limit for calculating a suggested facet (default=50) - Only apply responsive table styles to `.rows-and-column` Otherwise they interfere with tables in the description, e.g. on https://fivethirtyeight.datasettes.com/fivethirtyeight/nba-elo%2Fnbaallelo - Refactored views into new `views/` modules, refs #256 - [Documentation for SQLite full-text search](http://datasette.readthedocs.io/en/latest/full_text_search.html) support, closes #253 - `/-/versions` now includes SQLite `fts_versions`, closes #252",2018-05-20T23:44:19Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.21,2018-05-05,"New JSON `_shape=` options, the ability to set table `_size=` and a mechanism for searching within specific columns. - Default tests to using a longer timelimit Every now and then a test will fail in Travis CI on Python 3.5 because it hit the default 20ms SQL time limit. Test fixtures now default to a 200ms time limit, and we only use the 20ms time limit for the specific test that tests query interruption. This should make our tests on Python 3.5 in Travis much more stable. - Support `_search_COLUMN=text` searches, closes [\#237](https://github.com/simonw/datasette/issues/237) - Show version on `/-/plugins` page, closes [\#248](https://github.com/simonw/datasette/issues/248) - `?_size=max` option, closes [\#249](https://github.com/simonw/datasette/issues/249) - Added `/-/versions` and `/-/versions.json`, closes [\#244](https://github.com/simonw/datasette/issues/244) Sample output: { ""python"": { ""version"": ""3.6.3"", ""full"": ""3.6.3 (default, Oct 4 2017, 06:09:38) \n[GCC 4.2.1 Compatible Apple LLVM 9.0.0 (clang-900.0.37)]"" }, ""datasette"": { ""version"": ""0.20"" }, ""sqlite"": { ""version"": ""3.23.1"", ""extensions"": { ""json1"": null, ""spatialite"": ""4.3.0a"" } } } - Renamed `?_sql_time_limit_ms=` to `?_timelimit`, closes [\#242](https://github.com/simonw/datasette/issues/242) - New `?_shape=array` option + tweaks to `_shape`, closes [\#245](https://github.com/simonw/datasette/issues/245) - Default is now `?_shape=arrays` (renamed from `lists`) - New `?_shape=array` returns an array of objects as the root object - Changed `?_shape=object` to return the object as the root - Updated docs - FTS tables now detected by `inspect()`, closes [\#240](https://github.com/simonw/datasette/issues/240) - New `?_size=XXX` querystring parameter for table view, closes [\#229](https://github.com/simonw/datasette/issues/229) Also added documentation for all of the `_special` arguments. Plus deleted some duplicate logic implementing `_group_count`. - If `max_returned_rows==page_size`, increment `max_returned_rows` - fixes [\#230](https://github.com/simonw/datasette/issues/230) - New `hidden: True` option for table metadata, closes [\#239](https://github.com/simonw/datasette/issues/239) - Hide `idx_*` tables if spatialite detected, closes [\#228](https://github.com/simonw/datasette/issues/228) - Added `class=rows-and-columns` to custom query results table - Added CSS class `rows-and-columns` to main table - `label_column` option in `metadata.json` - closes [\#234](https://github.com/simonw/datasette/issues/234)",2018-05-05T23:21:33Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.20,2018-04-20,"Mostly new work on the [Plugins](http://datasette.readthedocs.io/en/latest/plugins.html) mechanism: plugins can now bundle static assets and custom templates, and ``datasette publish`` has a new ``--install=name-of-plugin`` option. - Add col-X classes to HTML table on custom query page - Fixed out-dated template in documentation - Plugins can now bundle custom templates, #224 - Added /-/metadata /-/plugins /-/inspect, #225 - Documentation for --install option, refs #223 - Datasette publish/package --install option, #223 - Fix for plugins in Python 3.5, #222 - New plugin hooks: extra_css_urls() and extra_js_urls(), #214 - /-/static-plugins/PLUGIN_NAME/ now serves static/ from plugins - now gets class=""col-X"" - plus added col-X documentation - Use to_css_class for table cell column classes This ensures that columns with spaces in the name will still generate usable CSS class names. Refs #209 - Add column name classes to s, make PK bold [Russ Garrett] - Don't duplicate simple primary keys in the link column [Russ Garrett] When there's a simple (single-column) primary key, it looks weird to duplicate it in the link column. This change removes the second PK column and treats the link column as if it were the PK column from a header/sorting perspective. - Correct escaping for HTML display of row links [Russ Garrett] - Longer time limit for test_paginate_compound_keys It was failing intermittently in Travis - see #209 - Use application/octet-stream for downloadable databses - Updated PyPI classifiers - Updated PyPI link to pypi.org",2018-04-20T14:41:14Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.19,2018-04-17,"This is the first preview of the new Datasette plugins mechanism. Only two plugin hooks are available so far - for custom SQL functions and custom template filters. There's plenty more to come - read [the documentation](https://datasette.readthedocs.io/en/latest/plugins.html) and get involved in [the tracking ticket](https://github.com/simonw/datasette/issues/14) if you have feedback on the direction so far. - Fix for `_sort_desc=sortable_with_nulls` test, refs [#216](https://github.com/simonw/datasette/issues/216) - Fixed [#216](https://github.com/simonw/datasette/issues/216) - paginate correctly when sorting by nullable column - Initial documentation for plugins, closes [#213](https://github.com/simonw/datasette/issues/213) https://datasette.readthedocs.io/en/latest/plugins.html - New `--plugins-dir=plugins/` option ([#212](https://github.com/simonw/datasette/issues/212)) New option causing Datasette to load and evaluate all of the Python files in the specified directory and register any plugins that are defined in those files. This new option is available for the following commands: datasette serve mydb.db --plugins-dir=plugins/ datasette publish now/heroku mydb.db --plugins-dir=plugins/ datasette package mydb.db --plugins-dir=plugins/ - Start of the plugin system, based on pluggy ([#210](https://github.com/simonw/datasette/issues/14)) Uses https://pluggy.readthedocs.io/ originally created for the py.test project We're starting with two plugin hooks: `prepare_connection(conn)` This is called when a new SQLite connection is created. It can be used to register custom SQL functions. `prepare_jinja2_environment(env)` This is called with the Jinja2 environment. It can be used to register custom template tags and filters. An example plugin which uses these two hooks can be found at https://github.com/simonw/datasette-plugin-demos or installed using `pip install datasette-plugin-demos` Refs [#14](https://github.com/simonw/datasette/issues/14) - Return HTTP 405 on InvalidUsage rather than 500. [Russ Garrett] This also stops it filling up the logs. This happens for HEAD requests at the moment - which perhaps should be handled better, but that's a different issue.",2018-04-17T02:21:51Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.18,2018-04-14,"This release introduces [support for units](http://datasette.readthedocs.io/en/latest/metadata.html#specifying-units-for-a-column), contributed by Russ Garrett ([\#203](https://github.com/simonw/datasette/issues/203)). You can now optionally specify the units for specific columns using `metadata.json`. Once specified, units will be displayed in the HTML view of your table. They also become available for use in filters - if a column is configured with a unit of distance, you can request all rows where that column is less than 50 meters or more than 20 feet [for example](https://wtr-api.herokuapp.com/wtr-663ea99/license_frequency?frequency__gt=50GHz&height__lt=50ft). - Link foreign keys which don't have labels. \[Russ Garrett\] This renders unlabeled FKs as simple links. Also includes bonus fixes for two minor issues: - In foreign key link hrefs the primary key was escaped using HTML escaping rather than URL escaping. This broke some non-integer PKs. - Print tracebacks to console when handling 500 errors. - Fix SQLite error when loading rows with no incoming FKs. \[Russ Garrett\] This fixes `ERROR: conn=, sql = 'select ', params = {'id': '1'}` caused by an invalid query when loading incoming FKs. The error was ignored due to async but it still got printed to the console. - Allow custom units to be registered with Pint. \[Russ Garrett\] - Support units in filters. \[Russ Garrett\] - Tidy up units support. \[Russ Garrett\] - Add units to exported JSON - Units key in metadata skeleton - Docs - Initial units support. \[Russ Garrett\] Add support for specifying units for a column in `metadata.json` and rendering them on display using [pint](https://pint.readthedocs.io/en/latest/)",2018-04-14T15:45:11Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.16,2018-04-13," - Better mechanism for handling errors; 404s for missing table/database New error mechanism closes [#193](https://github.com/simonw/datasette/issues/193) 404s for missing tables/databases closes [#184](https://github.com/simonw/datasette/issues/184) - long\_description in markdown for the new PyPI - Hide Spatialite system tables. \[Russ Garrett\] - Allow `explain select` / `explain query plan select` [#201](https://github.com/simonw/datasette/issues/201) - Datasette inspect now finds primary\_keys [#195](https://github.com/simonw/datasette/issues/195) - Ability to sort using form fields (for mobile portrait mode) [#199](https://github.com/simonw/datasette/issues/199) We now display sort options as a select box plus a descending checkbox, which means you can apply sort orders even in portrait mode on a mobile phone where the column headers are hidden.",2018-04-13T21:10:53Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.15,2018-04-09,"The biggest new feature in this release is the ability to sort by column. On the table page the column headers can now be clicked to apply sort (or descending sort), or you can specify `?_sort=column` or `?_sort_desc=column` directly in the URL. You can try this feature out on [this fivethirtyeight data](https://fivethirtyeight.datasettes.com/fivethirtyeight/congress-age%2Fcongress-terms) about the ages of different US politicians. - `table_rows` =\> `table_rows_count`, `filtered_table_rows` =\> `filtered_table_rows_count` Renamed properties. Closes [\#194](https://github.com/simonw/datasette/issues/194) - New `sortable_columns` option in `metadata.json` to control sort options. You can now explicitly set which columns in a table can be used for sorting using the `_sort` and `_sort_desc` arguments using `metadata.json`: { ""databases"": { ""database1"": { ""tables"": { ""example_table"": { ""sortable_columns"": [ ""height"", ""weight"" ] } } } } } Refs [\#189](https://github.com/simonw/datasette/issues/189) - Column headers now link to sort/desc sort - refs [\#189](https://github.com/simonw/datasette/issues/189) - `_sort` and `_sort_desc` parameters for table views Allows for paginated sorted results based on a specified column. Refs [\#189](https://github.com/simonw/datasette/issues/189) - Total row count now correct even if `_next` applied - Use .custom\_sql() for \_group\_count implementation (refs [\#150](https://github.com/simonw/datasette/issues/150)) - Make HTML title more readable in query template ([\#180](https://github.com/simonw/datasette/issues/180)) \[Ryan Pitts\] - New `?_shape=objects/object/lists` param for JSON API ([\#192](https://github.com/simonw/datasette/issues/192)) New `_shape=` parameter replacing old `.jsono` extension Now instead of this: /database/table.jsono We use the `_shape` parameter like this: /database/table.json?_shape=objects Also introduced a new `_shape` called `object` which looks like this: /database/table.json?_shape=object Returning an object for the rows key: ... ""rows"": { ""pk1"": { ... }, ""pk2"": { ... } } Refs [\#122](https://github.com/simonw/datasette/issues/122) - Utility for writing test database fixtures to a .db file `python tests/fixtures.py /tmp/hello.db` This is useful for making a SQLite database of the test fixtures for interactive exploration. - Compound primary key `_next=` now plays well with extra filters Closes [\#190](https://github.com/simonw/datasette/issues/190) - Fixed bug with keyset pagination over compound primary keys Refs [\#190](https://github.com/simonw/datasette/issues/190) - Database/Table views inherit `source/license/source_url/license_url` metadata If you set the `source_url/license_url/source/license` fields in your root metadata those values will now be inherited all the way down to the database and table templates. The `title/description` are NOT inherited. Also added unit tests for the HTML generated by the metadata. Refs [\#185](https://github.com/simonw/datasette/issues/185) - Add metadata, if it exists, to heroku temp dir ([\#178](https://github.com/simonw/datasette/issues/178)) \[Tony Hirst\] - Initial documentation for pagination - Broke up test\_app into test\_api and test\_html - Fixed bug with .json path regular expression I had a table called `geojson` and it caused an exception because the regex was matching `.json` and not `\.json` - Deploy to Heroku with Python 3.6.3",2018-04-09T15:55:29Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.14,2017-12-10,"The theme of this release is customization: Datasette now allows every aspect of its presentation [to be customized](http://datasette.readthedocs.io/en/latest/custom_templates.html) either using additional CSS or by providing entirely new templates. Datasette's [metadata.json format](http://datasette.readthedocs.io/en/latest/metadata.html) has also been expanded, to allow per-database and per-table metadata. A new `datasette skeleton` command can be used to generate a skeleton JSON file ready to be filled in with per-database and per-table details. The `metadata.json` file can also be used to define [canned queries](http://datasette.readthedocs.io/en/latest/sql_queries.html#canned-queries), as a more powerful alternative to SQL views. - `extra_css_urls`/`extra_js_urls` in metadata A mechanism in the `metadata.json` format for adding custom CSS and JS urls. Create a `metadata.json` file that looks like this: { ""extra_css_urls"": [ ""https://simonwillison.net/static/css/all.bf8cd891642c.css"" ], ""extra_js_urls"": [ ""https://code.jquery.com/jquery-3.2.1.slim.min.js"" ] } Then start datasette like this: datasette mydb.db --metadata=metadata.json The CSS and JavaScript files will be linked in the `` of every page. You can also specify a SRI (subresource integrity hash) for these assets: { ""extra_css_urls"": [ { ""url"": ""https://simonwillison.net/static/css/all.bf8cd891642c.css"", ""sri"": ""sha384-9qIZekWUyjCyDIf2YK1FRoKiPJq4PHt6tp/ulnuuyRBvazd0hG7pWbE99zvwSznI"" } ], ""extra_js_urls"": [ { ""url"": ""https://code.jquery.com/jquery-3.2.1.slim.min.js"", ""sri"": ""sha256-k2WSCIexGzOj3Euiig+TlR8gA0EmPjuc79OEeY5L45g="" } ] } Modern browsers will only execute the stylesheet or JavaScript if the SRI hash matches the content served. You can generate hashes using - Auto-link column values that look like URLs ([\#153](https://github.com/simonw/datasette/issues/153)) - CSS styling hooks as classes on the body ([\#153](https://github.com/simonw/datasette/issues/153)) Every template now gets CSS classes in the body designed to support custom styling. The index template (the top level page at `/`) gets this: The database template (`/dbname/`) gets this: The table template (`/dbname/tablename`) gets: The row template (`/dbname/tablename/rowid`) gets: The `db-x` and `table-x` classes use the database or table names themselves IF they are valid CSS identifiers. If they aren't, we strip any invalid characters out and append a 6 character md5 digest of the original name, in order to ensure that multiple tables which resolve to the same stripped character version still have different CSS classes. Some examples (extracted from the unit tests): ""simple"" => ""simple"" ""MixedCase"" => ""MixedCase"" ""-no-leading-hyphens"" => ""no-leading-hyphens-65bea6"" ""_no-leading-underscores"" => ""no-leading-underscores-b921bc"" ""no spaces"" => ""no-spaces-7088d7"" ""-"" => ""336d5e"" ""no $ characters"" => ""no--characters-59e024"" - `datasette --template-dir=mytemplates/` argument You can now pass an additional argument specifying a directory to look for custom templates in. Datasette will fall back on the default templates if a template is not found in that directory. - Ability to over-ride templates for individual tables/databases. It is now possible to over-ride templates on a per-database / per-row or per-table basis. When you access e.g. `/mydatabase/mytable` Datasette will look for the following: - table-mydatabase-mytable.html - table.html If you provided a `--template-dir` argument to datasette serve it will look in that directory first. The lookup rules are as follows: Index page (/): index.html Database page (/mydatabase): database-mydatabase.html database.html Table page (/mydatabase/mytable): table-mydatabase-mytable.html table.html Row page (/mydatabase/mytable/id): row-mydatabase-mytable.html row.html If a table name has spaces or other unexpected characters in it, the template filename will follow the same rules as our custom `` CSS classes - for example, a table called ""Food Trucks"" will attempt to load the following templates: table-mydatabase-Food-Trucks-399138.html table.html It is possible to extend the default templates using Jinja template inheritance. If you want to customize EVERY row template with some additional content you can do so by creating a row.html template like this: {% extends ""default:row.html"" %} {% block content %}

EXTRA HTML AT THE TOP OF THE CONTENT BLOCK

This line renders the original block:

{{ super() }} {% endblock %} - `--static` option for datasette serve ([\#160](https://github.com/simonw/datasette/issues/160)) You can now tell Datasette to serve static files from a specific location at a specific mountpoint. For example: datasette serve mydb.db --static extra-css:/tmp/static/css Now if you visit this URL: http://localhost:8001/extra-css/blah.css The following file will be served: /tmp/static/css/blah.css - Canned query support. Named canned queries can now be defined in `metadata.json` like this: { ""databases"": { ""timezones"": { ""queries"": { ""timezone_for_point"": ""select tzid from timezones ..."" } } } } These will be shown in a new ""Queries"" section beneath ""Views"" on the database page. - New `datasette skeleton` command for generating `metadata.json` ([\#164](https://github.com/simonw/datasette/issues/164)) - `metadata.json` support for per-table/per-database metadata ([\#165](https://github.com/simonw/datasette/issues/165)) Also added support for descriptions and HTML descriptions. Here's an example metadata.json file illustrating custom per-database and per-table metadata: { ""title"": ""Overall datasette title"", ""description_html"": ""This is a description with HTML."", ""databases"": { ""db1"": { ""title"": ""First database"", ""description"": ""This is a string description & has no HTML"", ""license_url"": ""http://example.com/"", ""license"": ""The example license"", ""queries"": { ""canned_query"": ""select * from table1 limit 3;"" }, ""tables"": { ""table1"": { ""title"": ""Custom title for table1"", ""description"": ""Tables can have descriptions too"", ""source"": ""This has a custom source"", ""source_url"": ""http://example.com/"" } } } } } - Renamed `datasette build` command to `datasette inspect` ([\#130](https://github.com/simonw/datasette/issues/130)) - Upgrade to Sanic 0.7.0 ([\#168](https://github.com/simonw/datasette/issues/168)) - Package and publish commands now accept `--static` and `--template-dir` Example usage: datasette package --static css:extra-css/ --static js:extra-js/ \ sf-trees.db --template-dir templates/ --tag sf-trees --branch master This creates a local Docker image that includes copies of the templates/, extra-css/ and extra-js/ directories. You can then run it like this: docker run -p 8001:8001 sf-trees For publishing to Zeit now: datasette publish now --static css:extra-css/ --static js:extra-js/ \ sf-trees.db --template-dir templates/ --name sf-trees --branch master - HTML comment showing which templates were considered for a page ([\#171](https://github.com/simonw/datasette/issues/171)) ",2017-12-10T01:41:14Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.13,2017-11-25,"# 0.13 (2017-11-24) - Search now applies to current filters. Combined search into the same form as filters. Closes [\#133](https://github.com/simonw/datasette/issues/133) - Much tidier design for table view header. Closes [\#147](https://github.com/simonw/datasette/issues/147) - Added `?column__not=blah` filter. Closes [\#148](https://github.c) - Row page now resolves foreign keys. Closes [\#132]() - Further tweaks to select/input filter styling. Refs [\#86]() - thanks for the help, @natbat\! - Show linked foreign key in table cells. - Added UI for editing table filters. Refs [\#86]() - Hide FTS-created tables on index pages. Closes [\#129]() - Add publish to heroku support \[Jacob Kaplan-Moss\] `datasette publish heroku mydb.db` Pull request [\#104]() - Initial implementation of `?_group_count=column`. URL shortcut for counting rows grouped by one or more columns. `?_group_count=column1&_group_count=column2` works as well. SQL generated looks like this: select ""qSpecies"", count(*) as ""count"" from Street_Tree_List group by ""qSpecies"" order by ""count"" desc limit 100 Or for two columns like this: select ""qSpecies"", ""qSiteInfo"", count(*) as ""count"" from Street_Tree_List group by ""qSpecies"", ""qSiteInfo"" order by ""count"" desc limit 100 Refs [\#44]() - Added `--build=master` option to datasette publish and package. The `datasette publish` and `datasette package` commands both now accept an optional `--build` argument. If provided, this can be used to specify a branch published to GitHub that should be built into the container. This makes it easier to test code that has not yet been officially released to PyPI, e.g.: datasette publish now mydb.db --branch=master - Implemented `?_search=XXX` + UI if a FTS table is detected. Closes [\#131]() - Added `datasette --version` support. - Table views now show expanded foreign key references, if possible. If a table has foreign key columns, and those foreign key tables have `label_columns`, the TableView will now query those other tables for the corresponding values and display those values as links in the corresponding table cells. label\_columns are currently detected by the `inspect()` function, which looks for any table that has just two columns - an ID column and one other - and sets the `label_column` to be that second non-ID column. - Don't prevent tabbing to ""Run SQL"" button ([\#117]()) \[Robert Gieseke\] See comment in [\#115]() - Add keyboard shortcut to execute SQL query ([\#115]()) \[Robert Gieseke\] - Allow `--load-extension` to be set via environment variable. - Add support for `?field__isnull=1` ([\#107]()) \[Ray N\] - Add spatialite, switch to debian and local build ([\#114]()) \[Ariel Núñez\] - Added `--load-extension` argument to datasette serve. Allows loading of SQLite extensions. Refs [\#110](). ",2017-11-25T03:44:46Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 107914493,https://github.com/simonw/datasette,https://github.com/simonw/datasette/releases/tag/0.12,2017-11-16,"- Added `__version__`, now displayed as tooltip in page footer (#108). - Added initial docs, including a changelog (#99). - Turned on auto-escaping in Jinja. - Added a UI for editing named parameters (#96). You can now construct a custom SQL statement using SQLite named parameters (e.g. `:name`) and datasette will display form fields for editing those parameters. [Here's an example](https://australian-dogs.now.sh/australian-dogs-3ba9628?sql=select+name%2C+count%28*%29+as+n+from+%28%0D%0A%0D%0Aselect+upper%28%22Animal+name%22%29+as+name+from+%5BAdelaide-City-Council-dog-registrations-2013%5D+where+Breed+like+%3Abreed%0D%0A%0D%0Aunion+all%0D%0A%0D%0Aselect+upper%28Animal_Name%29+as+name+from+%5BAdelaide-City-Council-dog-registrations-2014%5D+where+Breed_Description+like+%3Abreed%0D%0A%0D%0Aunion+all+%0D%0A%0D%0Aselect+upper%28Animal_Name%29+as+name+from+%5BAdelaide-City-Council-dog-registrations-2015%5D+where+Breed_Description+like+%3Abreed%0D%0A%0D%0Aunion+all%0D%0A%0D%0Aselect+upper%28%22AnimalName%22%29+as+name+from+%5BCity-of-Port-Adelaide-Enfield-Dog_Registrations_2016%5D+where+AnimalBreed+like+%3Abreed%0D%0A%0D%0Aunion+all%0D%0A%0D%0Aselect+upper%28%22Animal+Name%22%29+as+name+from+%5BMitcham-dog-registrations-2015%5D+where+Breed+like+%3Abreed%0D%0A%0D%0Aunion+all%0D%0A%0D%0Aselect+upper%28%22DOG_NAME%22%29+as+name+from+%5Bburnside-dog-registrations-2015%5D+where+DOG_BREED+like+%3Abreed%0D%0A%0D%0Aunion+all+%0D%0A%0D%0Aselect+upper%28%22Animal_Name%22%29+as+name+from+%5Bcity-of-playford-2015-dog-registration%5D+where+Breed_Description+like+%3Abreed%0D%0A%0D%0Aunion+all%0D%0A%0D%0Aselect+upper%28%22Animal+Name%22%29+as+name+from+%5Bcity-of-prospect-dog-registration-details-2016%5D+where%22Breed+Description%22+like+%3Abreed%0D%0A%0D%0A%29+group+by+name+order+by+n+desc%3B&breed=pug) which lets you see the most popular names for dogs of different species registered through various dog registration schemes in Australia. - Pin to specific Jinja version. (#100). - Default to 127.0.0.1 not 0.0.0.0. (#98). - Added extra metadata options to publish and package commands. (#92). You can now run these commands like so: datasette now publish mydb.db \ --title=""My Title"" \ --source=""Source"" \ --source_url=""http://www.example.com/"" \ --license=""CC0"" \ --license_url=""https://creativecommons.org/publicdomain/zero/1.0/"" This will write those values into the metadata.json that is packaged with the app. If you also pass `--metadata=metadata.json` that file will be updated with the extra values before being written into the Docker image. - Added simple production-ready Dockerfile (#94) \[Andrew Cutler\] - New `?_sql_time_limit_ms=10` argument to database and table page (#95) - SQL syntax highlighting with Codemirror (#89) \[Tom Dyson\]",2017-11-16T16:01:35Z,"[""asgi"", ""automatic-api"", ""csv"", ""datasets"", ""datasette"", ""datasette-io"", ""docker"", ""json"", ""python"", ""sql"", ""sqlite""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.35.2,2023-11-04,"- The `--load-extension=spatialite` option and [find_spatialite()](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-gis-find-spatialite) utility function now both work correctly on `arm64` Linux. Thanks, [Mike Coats](https://github.com/MikeCoats). ([#599](https://github.com/simonw/sqlite-utils/issues/599)) - Fix for bug where `sqlite-utils insert` could cause your terminal cursor to disappear. Thanks, [Luke Plant](https://github.com/spookylukey). ([#433](https://github.com/simonw/sqlite-utils/issues/433)) - `datetime.timedelta` values are now stored as `TEXT` columns. Thanks, [Harald Nezbeda](https://github.com/nezhar). ([#522](https://github.com/simonw/sqlite-utils/issues/522)) - Test suite is now also run against Python 3.12.",2023-11-04T01:05:56Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.35.1,2023-09-09,- Fixed a bug where [table.transform()](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-transform) would sometimes re-assign the `rowid` values for a table rather than keeping them consistent across the operation. ([#592](https://github.com/simonw/sqlite-utils/issues/592)),2023-09-09T00:50:42Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.35,2023-08-18,"Adding foreign keys to a table no longer uses `PRAGMA writable_schema = 1` to directly manipulate the `sqlite_master` table. This was resulting in errors in some Python installations where the SQLite library was compiled in a way that prevented this from working, in particular on macOS. Foreign keys are now added using the [table transformation](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-transform) mechanism instead. ([#577](https://github.com/simonw/sqlite-utils/issues/577)) This new mechanism creates a full copy of the table, so it is likely to be significantly slower for large tables, but will no longer trigger table `sqlite_master may not be modified` errors on platforms that do not support `PRAGMA writable_schema = 1`. A new plugin, [sqlite-utils-fast-fks](https://github.com/simonw/sqlite-utils-fast-fks), is now available for developers who still want to use that faster but riskier implementation. Other changes: - The [table.transform() method](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-transform) has two new parameters: `foreign_keys=` allows you to replace the foreign key constraints defined on a table, and `add_foreign_keys=` lets you specify new foreign keys to add. These complement the existing `drop_foreign_keys=` parameter. ([#577](https://github.com/simonw/sqlite-utils/issues/577)) - The [sqlite-utils transform](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-transform-table) command has a new `--add-foreign-key` option which can be called multiple times to add foreign keys to a table that is being transformed. ([#585](https://github.com/simonw/sqlite-utils/issues/585)) - [sqlite-utils convert](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-convert) now has a `--pdb` option for opening a debugger on the first encountered error in your conversion script. ([#581](https://github.com/simonw/sqlite-utils/issues/581)) - Fixed a bug where `sqlite-utils install -e '.[test]'` option did not work correctly.",2023-08-18T02:05:22Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.34,2023-07-22,"This release introduces a new [plugin system](https://sqlite-utils.datasette.io/en/stable/plugins.html#plugins). ([#567](https://github.com/simonw/sqlite-utils/issues/567)) - Documentation describing [how to build a plugin](https://sqlite-utils.datasette.io/en/stable/plugins.html#plugins-building). - Plugin hook: [register_commands(cli)](https://sqlite-utils.datasette.io/en/stable/plugins.html#plugins-hooks-register-commands), for plugins to add extra commands to `sqlite-utils`. ([#569](https://github.com/simonw/sqlite-utils/issues/569)) - Plugin hook: [prepare_connection(conn)](https://sqlite-utils.datasette.io/en/stable/plugins.html#plugins-hooks-prepare-connection). Plugins can use this to help prepare the SQLite connection to do things like registering custom SQL functions. Thanks, [Alex Garcia](https://github.com/asg017). ([#574](https://github.com/simonw/sqlite-utils/issues/574)) - `sqlite_utils.Database(..., execute_plugins=False)` option for disabling plugin execution. ([#575](https://github.com/simonw/sqlite-utils/issues/575)) - `sqlite-utils install -e path-to-directory` option for installing editable code. This option is useful during the development of a plugin. ([#570](https://github.com/simonw/sqlite-utils/issues/570)) - `table.create(...)` method now accepts `replace=True` to drop and replace an existing table with the same name, or `ignore=True` to silently do nothing if a table already exists with the same name. ([#568](https://github.com/simonw/sqlite-utils/issues/568)) - `sqlite-utils insert ... --stop-after 10` option for stopping the insert after a specified number of records. Works for the `upsert` command as well. ([#561](https://github.com/simonw/sqlite-utils/issues/561)) - The `--csv` and `--tsv` modes for `insert` now accept a `--empty-null` option, which cases empty strings in the CSV file to be stored as `null` in the database. ([#563](https://github.com/simonw/sqlite-utils/issues/563)) - New `db.rename_table(table_name, new_name)` method for renaming tables. ([#565](https://github.com/simonw/sqlite-utils/issues/565)) - `sqlite-utils rename-table my.db table_name new_name` command for renaming tables. ([#565](https://github.com/simonw/sqlite-utils/issues/565)) - The `table.transform(...)` method now takes an optional `keep_table=new_table_name` parameter, which will cause the original table to be renamed to `new_table_name` rather than being dropped at the end of the transformation. ([#571](https://github.com/simonw/sqlite-utils/issues/571)) - Documentation now notes that calling `table.transform()` without any arguments will reformat the SQL schema stored by SQLite to be more aesthetically pleasing. ([#564](https://github.com/simonw/sqlite-utils/issues/564))",2023-07-22T23:30:49Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.33,2023-06-26,"- `sqlite-utils` will now use [sqlean.py](https://github.com/nalgeon/sqlean.py) in place of `sqlite3` if it is installed in the same virtual environment. This is useful for Python environments with either an outdated version of SQLite or with restrictions on SQLite such as disabled extension loading or restrictions resulting in the `sqlite3.OperationalError: table sqlite_master may not be modified` error. ([#559](https://github.com/simonw/sqlite-utils/issues/559)) - New `with db.ensure_autocommit_off()` context manager, which ensures that the database is in autocommit mode for the duration of a block of code. This is used by `db.enable_wal()` and `db.disable_wal()` to ensure they work correctly with `pysqlite3` and `sqlean.py`. - New `db.iterdump()` method, providing an iterator over SQL strings representing a dump of the database. This uses `sqlite-dump` if it is available, otherwise falling back on the `conn.iterdump()` method from `sqlite3`. Both `pysqlite3` and `sqlean.py` omit support for `iterdump()` - this method helps paper over that difference.",2023-06-26T01:32:30Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.32.1,2023-05-21,"- Examples in the [CLI documentation](https://sqlite-utils.datasette.io/en/stable/cli.html) can now all be copied and pasted without needing to remove a leading `$`. ([#551](https://github.com/simonw/sqlite-utils/issues/551)) - Documentation now covers [Setting up shell completion](https://sqlite-utils.datasette.io/en/stable//installation.html#installation-completion) for `bash` and `zsh`. ([#552](https://github.com/simonw/sqlite-utils/issues/552))",2023-05-21T21:12:05Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.32,2023-05-21,"- New experimental `sqlite-utils tui` interface for interactively building command-line invocations, powered by [Trogon](https://github.com/Textualize/trogon). This requires an optional dependency, installed using `sqlite-utils install trogon`. There is a screenshot [in the documentation](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-tui). ([#545](https://github.com/simonw/sqlite-utils/issues/545)) - `sqlite-utils analyze-tables` command ([documentation](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-analyze-tables)) now has a `--common-limit 20` option for changing the number of common/least-common values shown for each column. ([#544](https://github.com/simonw/sqlite-utils/issues/544)) - `sqlite-utils analyze-tables --no-most` and `--no-least` options for disabling calculation of most-common and least-common values. - If a column contains only `null` values, `analyze-tables` will no longer attempt to calculate the most common and least common values for that column. ([#547](https://github.com/simonw/sqlite-utils/issues/547)) - Calling `sqlite-utils analyze-tables` with non-existent columns in the `-c/--column` option now results in an error message. ([#548](https://github.com/simonw/sqlite-utils/issues/548)) - The `table.analyze_column()` method ([documented here](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-analyze-column)) now accepts `most_common=False` and `least_common=False` options for disabling calculation of those values.",2023-05-21T18:55:42Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.31,2023-05-08,"- Dropped support for Python 3.6. Tests now ensure compatibility with Python 3.11. ([#517](https://github.com/simonw/sqlite-utils/issues/517)) - Automatically locates the SpatiaLite extension on Apple Silicon. Thanks, Chris Amico. ([#536](https://github.com/simonw/sqlite-utils/pull/536)) - New `--raw-lines` option for the `sqlite-utils query` and `sqlite-utils memory` commands, which outputs just the raw value of the first column of evy row. ([#539](https://github.com/simonw/sqlite-utils/issues/539)) - Fixed a bug where `table.upsert_all()` failed if the `not_null=` option was passed. ([#538](https://github.com/simonw/sqlite-utils/issues/538)) - Fixed a `ResourceWarning` when using `sqlite-utils insert`. ([#534](https://github.com/simonw/sqlite-utils/issues/534)) - Now shows a more detailed error message when `sqlite-utils insert` is called with invalid JSON. ([#532](https://github.com/simonw/sqlite-utils/ises/532)) - `table.convert(..., skip_false=False)` and `sqlite-utils convert --no-skip-false` options, for avoiding a misfeature where the [convert()](http://127.0.0.1:8000/python-api.html#python-api-convert) mechanism skips rows in the database with a falsey value for the specified column. Fixing this by default would be a backwards-incompatible change and is under consideration for a 4.0 release in the future. ([#527](https://github.com/simonw/sqlite-utils/issues/527)) - Tables can now be created with self-referential foreign keys. Thanks, Scott Perry. ([#537](https://github.com/simonw/sqlite-utils/pull/537)) - `sqlite-utils transform` no longer breaks if a table defines default values for columns. Thanks, Kenny Song. ([#509](https://github.com/simonw/sqlite-utils/issues/509)) - Fixed a bug where repeated calls to `table.transform()` did not work correctly. Thanks, Martin Carpenter. ([#525](https://github.com/simonw/sqlite-utils/issues/525)) - Improved error message if `rows_from_file()` is passed a non-binary-mode file-like object. ([#520](https://github.com/simonw/sqlite-utils/issues/520))",2023-05-08T22:37:24Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.30,2022-10-25,"- Now tested against Python 3.11. ([#502](https://github.com/simonw/sqlite-utils/issues/502)) - New `table.search_sql(include_rank=True)` option, which adds a `rank` column to the generated SQL. Thanks, Jacob Chapman. ([#480](https://github.com/simonw/sqlite-utils/pull/480)) - Progress bars now display for newline-delimited JSON files using the `--nl` option. Thanks, Mischa Untaga. ([#485](https://github.com/simonw/sqlite-utils/issues/485)) - New `db.close()` method. ([#504](https://github.com/simonw/sqlite-utils/issues/504)) - Conversion functions passed to [table.convert(...)](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-convert) can now return lists or dictionaries, which will be inserted into the database as JSON strings. ([#495](https://github.com/simonw/sqlite-utils/issues/495)) - `sqlite-utils install` and `sqlite-utils uninstall` commands for installing packages into the same virtual environment as `sqlite-utils`, [described here](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-install). ([#483](https://github.com/simonw/sqlite-utils/issues/483)) - New [sqlite_utils.utils.flatten()](https://sqlite-utils.datasette.io/en/stable/reference.html#reference-utils-flatten) utility function. ([#500](https://github.com/simonw/sqlite-utils/issues/500)) - Documentation on [using Just](https://sqlite-utils.datasette.io/en/stable/contributing.html#contributing-just) to run tests, linters and build documentation. - Documentation now covers the [Release process](https://sqlite-utils.datasette.io/en/stable/contributing.html#release-process) for this package.",2022-10-25T22:34:48Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.29,2022-08-28,"- The `sqlite-utils query`, `memory` and `bulk` commands now all accept a new `--functions` option. This can be passed a string of Python code, and any callable objects defined in that code will be made available to SQL queries as custom SQL functions. See [Defining custom SQL functions](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-query-functions) for details. ([#471](https://github.com/simonw/sqlite-utils/issues/471)) - `db[table].create(...)` method now accepts a new `transform=True` parameter. If the table already exists it will be transform to match the schema configuration options passed to the function. This may result in columns being added or dropped, column types being changed, column order being updated or not null and default values for columns being set. ([#467](https://github.com/simonw/sqlite-utils/issues/467)) - Related to the above, the `sqlite-utils create-table` command now accepts a `--transform` option. - New introspection property: `table.default_values` returns a dictionary mapping each column name with a default value to the configured default value. ([#475](https://github.com/simonw/sqlite-utils/issues/475)) - The `--load-extension` option can now be provided a path to a compiled SQLite extension module accompanied by the name of an entrypoint, separated by a colon - for example `--load-extension ./lines0:sqlite3_lines0_noread_init`. This feature is modelled on code first [contributed to Datasette](https://github.com/simonw/datasette/pull/1789) by Alex Garcia. ([#470](https://github.com/simonw/sqlite-utils/issues/470)) - Functions registered using the [db.register_function()](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-register-function) method can now have a custom name specified using the new `db.register_function(fn, name=...)` parameter. ([#458](https://github.com/simonw/sqlite-utils/issues/458)) - [sqlite-utils rows](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-rows) has a new `--order` option for specifying the sort order for the returned rows. ([#469](https://github.com/simonw/sqlite-utils/issues/469)) - All of the CLI options that accept Python code blocks can now all be used to define functions that can access modules imported in that same block of code without needing to use the `global` keyword. ([#472](https://github.com/simonw/sqlite-utils/issues/472)) - Fixed bug where `table.extract()` would not behave correctly for columns containing null values. Thanks, Forest Gregg. ([#423](https://github.com/simonw/sqlite-utils/issues/423)) - New tutorial: [Cleaning data with sqlite-utils and Datasette](https://datasette.io/tutorials/clean-data) shows how to use `sqlite-utils` to import and clean an example CSV file. - Datasette and `sqlite-utils` now have a Discord community. [Join the Discord here](https://discord.gg/Ass7bCAMDw).",2022-08-28T03:50:29Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.28,2022-07-15,"- New [table.duplicate(new_name)](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-duplicate) method for creating a copy of a table with a matching schema and row contents. Thanks, [David](https://github.com/davidleejy). ([#449](https://github.com/simonw/sqlite-utils/issues/449)) - New `sqlite-utils duplicate data.db table_name new_name` CLI command for [Duplicating tables](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-duplicate-table). ([#454](https://github.com/simonw/sqlite-utils/issues/454)) - `sqlite_utils.utils.rows_from_file()` is now a [documented API](https://sqlite-utils.datasette.io/en/stable/reference.html#reference-utils-rows-from-file). It can be used to read a sequence of dictionaries from a file-like object containing CSV, TSV, JSON or newline-delimited JSON. It can be passed an explicit format or can attempt to detect the format automatically. ([#443](https://github.com/simonw/sqlite-utils/issues/443)) - `sqlite_utils.utils.TypeTracker` is now a documented API for detecting the likely column types for a sequence of string rows, see [Detecting column types using TypeTracker](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-typetracker). ([#445](https://github.com/simonw/sqlite-utils/issues/445)) - `sqlite_utils.utils.chunks()` is now a documented API for [splitting an iterator into chunks](https://sqlite-utils.datasette.io/en/stable/reference.html#reference-utils-chunks). ([#451](https://github.com/simonw/sqlite-utils/issues/451)) - `sqlite-utils enable-fts` now has a `--replace` option for replacing the existing FTS configuration for a table. ([#450](https://github.com/simonw/sqlite-utils/issues/450)) - The `create-index`, `add-column` and `duplicate` commands all now take a `--ignore` option for ignoring errors should the database not be in the right state for them to operate. ([#450](https://github.com/simonw/sqlite-utils/issues/450))",2022-07-15T23:02:45Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.27,2022-06-15,"See also [the annotated release notes](https://simonwillison.net/2022/Jun/19/weeknotes/#sqlite-utils-3-27) for this release. - Documentation now uses the [Furo](https://github.com/pradyunsg/furo) Sphinx theme. ([#435](https://github.com/simonw/sqlite-utils/issues/435)) - Code examples in documentation now have a ""copy to clipboard"" button. ([#436](https://github.com/simonw/sqlite-utils/issues/436)) - `sqlite_utils.utils.utils.rows_from_file()` is now a documented API, see [Reading rows from a file](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-rows-from-file). ([#443](https://github.com/simonw/sqlite-utils/issues/443)) - `rows_from_file()` has two new parameters to help handle CSV files with rows that contain more values than are listed in that CSV file's headings: `ignore_extras=True` and `extras_key=""name-of-key""`. ([#440](https://github.com/simonw/sqlite-utils/issues/440)) - `sqlite_utils.utils.maximize_csv_field_size_limit()` helper function for increasing the field size limit for reading CSV files to its maximum, see [Setting the maximum CSV field size limit](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-maximize-csv-field-size-limit). ([#442](https://github.com/simonw/sqlite-utils/issues/442)) - `table.search(where=, where_args=)` parameters for adding additional `WHERE` clauses to a search query. The `where=` parameter is available on `table.search_sql(...)` as well. See [Searching with table.search()](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-fts-search). ([#441](https://github.com/simonw/sqlite-utils/issues/441)) - Fixed bug where `table.detect_fts()` and other search-related functions could fail if two FTS-enabled tables had names that were prefixes of each other. ([#434](https://github.com/simonw/sqlite-utils/issues/434))",2022-06-15T04:34:45Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.26.1,2022-05-02,"- Now depends on [click-default-group-wheel](https://github.com/simonw/click-default-group-wheel), a pure Python wheel package. This means you can install and use this package with [Pyodide](https://pyodide.org/), which can run Python entirely in your browser using WebAssembly. ([#429](https://github.com/simonw/sqlite-utils/pull/429)) Try that out using the [Pyodide REPL](https://pyodide.org/en/stable/console.html): ```pycon >>> import micropip >>> await micropip.install(""sqlite-utils"") >>> import sqlite_utils >>> db = sqlite_utils.Database(memory=True) >>> list(db.query(""select 3 * 5"")) [{'3 * 5': 15}] ```",2022-05-02T18:18:01Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.26,2022-04-13,"- New `errors=r.IGNORE/r.SET_NULL` parameter for the `r.parsedatetime()` and `r.parsedate()` [convert recipes](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-convert-recipes). ([#416](https://github.com/simonw/sqlite-utils/issues/416)) - Fixed a bug where `--multi` could not be used in combination with `--dry-run` for the [convert](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-convert) command. ([#415](https://github.com/simonw/sqlite-utils/issues/415)) - New documentation: [Using a convert() function to execute initialization](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-convert-complex). ([#420](https://github.com/simonw/sqlite-utils/issues/420)) - More robust detection for whether or not `deterministic=True` is supported. ([#425](https://github.com/simonw/sqlite-utils/issues/425))",2022-04-13T22:53:36Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.25.1,2022-03-11,- Improved display of type information and parameters in the [API reference documentation](https://sqlite-utils.datasette.io/en/stable/reference.html). [#413](https://github.com/simonw/sqlite-utils/issues/413),2022-03-11T18:35:41Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.25,2022-03-02,"- New `hash_id_columns=` parameter for creating a primary key that's a hash of the content of specific columns - see [Setting an ID based on the hash of the row contents](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-hash) for details. ([#343](https://github.com/simonw/sqlite-utils/issues/343)) - New [db.sqlite_version](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-sqlite-version) property, returning a tuple of integers representing the version of SQLite, for example `(3, 38, 0)`. - Fixed a bug where [register_function(deterministic=True)](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-register-function) caused errors on versions of SQLite prior to 3.8.3. ([#408](https://github.com/simonw/sqlite-utils/issues/408)) - New documented [hash_record(record, keys=...)](https://sqlite-utils.datasette.io/en/stable/reference.html#reference-utils-hash-record) function.",2022-03-02T06:35:18Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.24,2022-02-16,"- SpatiaLite helpers for the `sqlite-utils` command-line tool - thanks, Chris Amico. ([#398](https://github.com/simonw/sqlite-utils/issues/398)) - [sqlite-utils create-database](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-create-database) `--init-spatialite` option for initializing SpatiaLite on a newly created database. - [sqlite-utils add-geometry-column](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-spatialite) command for adding geometry columns. - [sqlite-utils create-spatial-index](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-spatialite-indexes) command for adding spatial indexes. - `db[table].create(..., if_not_exists=True)` option for [creating a table](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-explicit-create) only if it does not already exist. ([#397](https://github.com/simonw/sqlite-utils/issues/397)) - `Database(memory_name=""my_shared_database"")` parameter for creating a [named in-memory database](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-connect) that can be shared between multiple connections. ([#405](https://github.com/simonw/sqlite-utils/issues/405)) - Documentation now describes [how to add a primary key to a rowid table](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-transform-table-add-primary-key-to-rowid) using `sqlite-utils transform`. ([#403](https://github.com/simonw/sqlite-utils/issues/403))",2022-02-16T01:41:50Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.23,2022-02-04,"This release introduces four new utility methods for working with [SpatiaLite](https://www.gaia-gis.it/fossil/libspatialite/index). Thanks, Chris Amico. ([#330](https://github.com/simonw/sqlite-utils/pull/385)) - `sqlite_utils.utils.find_spatialite()` [finds the location of the SpatiaLite module](https://sqlite-utils.readthedocs.io/en/stable/python-api.html#python-api-gis-find-spatialite) on disk. - `db.init_spatialite()` [initializes SpatiaLite](https://sqlite-utils.readthedocs.io/en/stable/python-api.html#python-api-gis-init-spatialite) for the given database. - `table.add_geometry_column(...)` [adds a geometry column](https://sqlite-utils.readthedocs.io/en/stable/python-api.html#python-api-gis-add-geometry-column) to an existing table. - `table.create_spatial_index(...)` [creates a spatial index](https://sqlite-utils.readthedocs.io/en/stable/python-api.html#python-api-gis-create-spatial-index) for a column. - `sqlite-utils batch` now accepts a `--batch-size` option. ([#392](https://github.com/simonw/sqlite-utils/issues/392))",2022-02-04T06:44:19Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.22.1,2022-01-26,"- All commands now include example usage in their `--help` - see [CLI reference](https://sqlite-utils.datasette.io/en/stable/cli-reference.html#cli-reference). ([#384](https://github.com/simonw/sqlite-utils/issues/384)) - Python library documentation has a new [Getting started](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-getting-started) section. ([#387](https://github.com/simonw/sqlite-utils/issues/387)) - Documentation now uses [Plausible analytics](https://plausible.io/). ([#389](https://github.com/simonw/sqlite-utils/issues/389))",2022-01-26T03:29:24Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.22,2022-01-11,"- New [CLI reference](https://sqlite-utils.datasette.io/en/stable/cli-reference.html#cli-reference) documentation page, listing the output of `--help` for every one of the CLI commands. ([#383](https://github.com/simonw/sqlite-utils/issues/383)) - `sqlite-utils rows` now has `--limit` and `--offset` options for paginating through data. ([#381](https://github.com/simonw/sqlite-utils/issues/381)) - `sqlite-utils rows` now has `--where` and `-p` options for filtering the table using a `WHERE` query, see [Returning all rows in a table](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-rows). ([#382](https://github.com/simonw/sqlite-utils/issues/382))",2022-01-11T23:49:28Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.21,2022-01-11,"CLI and Python library improvements to help run [ANALYZE](https://www.sqlite.org/lang_analyze.html) after creating indexes or inserting rows, to gain better performance from the SQLite query planner when it runs against indexes. Three new CLI commands: `create-database`, `analyze` and `bulk`. More details and examples can be found in the [annotated release notes](https://simonwillison.net/2022/Jan/11/sqlite-utils/). - New `sqlite-utils create-database` command for creating new empty database files. ([#348](https://github.com/simonw/sqlite-utils/issues/348)) - New Python methods for running `ANALYZE` against a database, table or index: `db.analyze()` and `table.analyze()`, see [Optimizing index usage with ANALYZE](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-analyze). ([#366](https://github.com/simonw/sqlite-utils/issues/366)) - New [sqlite-utils analyze command](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-analyze) for running `ANALYZE` using the CLI. ([#379](https://github.com/simonw/sqlite-utils/issues/379)) - The `create-index`, `insert` and `upsert` commands now have a new `--analyze` option for running `ANALYZE` after the command has completed. ([#379](https://github.com/simonw/sqlite-utils/issues/379)) - New [sqlite-utils bulk command](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-bulk) which can import records in the same way as `sqlite-utils insert` (from JSON, CSV or TSV) and use them to bulk execute a parametrized SQL query. ([#375](https://github.com/simonw/sqlite-utils/issues/375)) - The CLI tool can now also be run using `python -m sqlite_utils`. ([#368](https://github.com/simonw/sqlite-utils/issues/368)) - Using `--fmt` now implies `--table`, so you don't need to pass both options. ([#374](https://github.com/simonw/sqlite-utils/issues/374)) - The `--convert` function applied to rows can now modify the row in place. ([#371](https://github.com/simonw/sqlite-utils/issues/371)) - The [insert-files command](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-insert-files) supports two new columns: `stem` and `suffix`. ([#372](https://github.com/simonw/sqlite-utils/issues/372)) - The `--nl` import option now ignores blank lines in the input. ([#376](https://github.com/simonw/sqlite-utils/issues/376)) - Fixed bug where streaming input to the `insert` command with `--batch-size 1` would appear to only commit after several rows had been ingested, due to unnecessary input buffering. ([#364](https://github.com/simonw/sqlite-utils/issues/364))",2022-01-11T02:35:02Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.20,2022-01-06,"- `sqlite-utils insert ... --lines` to insert the lines from a file into a table with a single `line` column, see [Inserting unstructured data with --lines and --text](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-insert-unstructured). - `sqlite-utils insert ... --text` to insert the contents of the file into a table with a single `text` column and a single row. - `sqlite-utils insert ... --convert` allows a Python function to be provided that will be used to convert each row that is being inserted into the database. See [Applying conversions while inserting data](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-insert-convert), including details on special behavior when combined with `--lines` and `--text`. ([#356](https://github.com/simonw/sqlite-utils/issues/356)) - `sqlite-utils convert` now accepts a code value of `-` to read code from standard input. ([#353](https://github.com/simonw/sqlite-utils/issues/353)) - `sqlite-utils convert` also now accepts code that defines a named `convert(value)` function, see [Converting data in columns](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-convert). - `db.supports_strict` property showing if the database connection supports [SQLite strict tables](https://www.sqlite.org/stricttables.html). - `table.strict` property (see [.strict](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-introspection-strict)) indicating if the table uses strict mode. ([#344](https://github.com/simonw/sqlite-utils/issues/344)) - Fixed bug where `sqlite-utils upsert ... --detect-types` ignored the `--detect-types` option. ([#362](https://github.com/simonw/sqlite-utils/issues/362))",2022-01-06T06:57:09Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.19,2021-11-21,"- The [table.lookup() method](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-lookup-tables) now accepts keyword arguments that match those on the underlying `table.insert()` method: `foreign_keys=`, `column_order=`, `not_null=`, `defaults=`, `extracts=`, `conversions=` and `columns=`. You can also now pass `pk=` to specify a different column name to use for the primary key. ([#342](https://github.com/simonw/sqlite-utils/issues/342))",2021-11-21T04:42:24Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.19a0,2021-11-19,- Extra keyword arguments for `table.lookup()` which are passed through to `.insert()`. [#342](https://github.com/simonw/sqlite-utils/issues/342),2021-11-19T07:28:50Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.18,2021-11-15,"- The `table.lookup()` method now has an optional second argument which can be used to populate columns only the first time the record is created, see [Working with lookup tables](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-lookup-tables). ([#339](https://github.com/simonw/sqlite-utils/issues/339)) - `sqlite-utils memory` now has a `--flatten` option for [flattening nested JSON objects](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-inserting-data-flatten) into separate columns, consistent with `sqlite-utils insert`. ([#332](https://github.com/simonw/sqlite-utils/issues/332)) - `table.create_index(..., find_unique_name=True)` parameter, which finds an available name for the created index even if the default name has already been taken. This means that `index-foreign-keys` will work even if one of the indexes it tries to create clashes with an existing index name. ([#335](https://github.com/simonw/sqlite-utils/issues/335)) - Added `py.typed` to the module, so [mypy](http://mypy-lang.org/) should now correctly pick up the type annotations. Thanks, Andreas Longo. ([#331](https://github.com/simonw/sqlite-utils/issues/331)) - Now depends on `python-dateutil` instead of depending on `dateutils`. Thanks, Denys Pavlov. ([#324](https://github.com/simonw/sqlite-utils/issues/324)) - `table.create()` (see [Explicitly creating a table](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-explicit-create)) now handles `dict`, `list` and `tuple` types, mapping them to `TEXT` columns in SQLite so that they can be stored encoded as JSON. ([#338](https://github.com/simonw/sqlite-utils/issues/338)) - Inserted data with square braces in the column names (for example a CSV file containing a `item[price]`) column now have the braces converted to underscores: `item_price_`. Previously such columns would be rejected with an error. ([#329](https://github.com/simonw/sqlite-utils/issues/329)) - Now also tested against Python 3.10. ([#330](https://github.com/simonw/sqlite-utils/pull/330))",2021-11-15T03:17:31Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.17.1,2021-09-22,"- [sqlite-utils memory](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-memory) now works if files passed to it share the same file name. ([#325](https://github.com/simonw/sqlite-utils/issues/325)) - [sqlite-utils query](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-query) now returns `[]` in JSON mode if no rows are returned. ([#328](https://github.com/simonw/sqlite-utils/issues/328))",2021-09-22T20:51:04Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.17,2021-08-24,"- The [sqlite-utils memory](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-memory) command has a new `--analyze` option, which runs the equivalent of the [analyze-tables](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-analyze-tables) command directly against the in-memory database created from the incoming CSV or JSON data. ([#320](https://github.com/simonw/sqlite-utils/issues/320)) - [sqlite-utils insert-files](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-insert-files) now has the ability to insert file contents in to `TEXT` columns in addition to the default `BLOB`. Pass the `--text` option or use `content_text` as a column specifier. ([#319](https://github.com/simonw/sqlite-utils/issues/319))",2021-08-24T23:42:22Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.16,2021-08-18,"- Type signatures added to more methods, including `table.resolve_foreign_keys()`, `db.create_table_sql()`, `db.create_table()` and `table.create()`. ([#314](https://github.com/simonw/sqlite-utils/issues/314)) - New `db.quote_fts(value)` method, see [Quoting characters for use in search](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-quote-fts) - thanks, Mark Neumann. ([#246](https://github.com/simonw/sqlite-utils/issues/246)) - `table.search()` now accepts an optional `quote=True` parameter. ([#296](https://github.com/simonw/sqlite-utils/issues/296)) - CLI command `sqlite-utils search` now accepts a `--quote` option. ([#296](https://github.com/simonw/sqlite-utils/issues/296)) - Fixed bug where `--no-headers` and `--tsv` options to [sqlite-utils insert](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-insert-csv-tsv) could not be used together. ([#295](https://github.com/simonw/sqlite-utils/issues/295)) - Various small improvements to [API reference](https://sqlite-utils.datasette.io/en/stable/reference.html#reference) documentation.",2021-08-18T22:37:55Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.15.1,2021-08-10,"- Python library now includes type annotations on almost all of the methods, plus detailed docstrings describing each one. ([#311](https://github.com/simonw/sqlite-utils/issues/311)) - New [API Reference](https://sqlite-utils.datasette.io/en/stable/reference.html) documentation page, powered by those docstrings. - Fixed bug where `.add_foreign_keys()` failed to raise an error if called against a `View`. ([#313](https://github.com/simonw/sqlite-utils/issues/313)) - Fixed bug where `.delete_where()` returned a `[]` instead of returning `self` if called against a non-existant table. ([#315](https://github.com/simonw/sqlite-utils/issues/315))",2021-08-10T23:55:38Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.15,2021-08-09,"- `sqlite-utils insert --flatten` option for [flattening nested JSON objects](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-inserting-data-flatten) to create tables with column names like `topkey_nestedkey`. ([#310](https://github.com/simonw/sqlite-utils/issues/310)) - Fixed several spelling mistakes in the documentation, spotted [using codespell](https://til.simonwillison.net/python/codespell). - Errors that occur while using the `sqlite-utils` CLI tool now show the responsible SQL and query parameters, if possible. ([#309](https://github.com/simonw/sqlite-utils/issues/309))",2021-08-09T22:43:16Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.14,2021-08-02,"This release introduces the new [sqlite-utils convert command](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-convert) ([#251](https://github.com/simonw/sqlite-utils/issues/251)) and corresponding [table.convert(...)](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-convert) Python method ([#302](https://github.com/simonw/sqlite-utils/issues/302)). These tools can be used to apply a Python conversion function to one or more columns of a table, either updating the column in place or using transformed data from that column to populate one or more other columns. This command-line example uses the Python standard library [textwrap module](https://docs.python.org/3/library/textwrap.html) to wrap the content of the `content` column in the `articles` table to 100 characters: ``` $ sqlite-utils convert content.db articles content\ '""\n"".join(textwrap.wrap(value, 100))'\ --import=textwrap ``` The same operation in Python code looks like this: ```python import sqlite_utils, textwrap db = sqlite_utils.Database(""content.db"") db[""articles""].convert(""content"", lambda v: ""\n"".join(textwrap.wrap(v, 100))) ``` See the full documentation for the [sqlite-utils convert command](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-convert) and the [table.convert(...)](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-convert) Python method for more details. Also in this release: - The new `table.count_where(...)` method, for counting rows in a table that match a specific SQL `WHERE` clause. ([#305](https://github.com/simonw/sqlite-utils/issues/305)) - New `--silent` option for the [sqlite-utils insert-files command](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-insert-files) to hide the terminal progress bar, consistent with the `--silent` option for `sqlite-utils convert`. ([#301](https://github.com/simonw/sqlite-utils/issues/301))",2021-08-02T21:34:43Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.13,2021-07-24,"- `sqlite-utils schema my.db table1 table2` command now accepts optional table names. ([#299](https://github.com/simonw/sqlite-utils/issues/299)) - `sqlite-utils memory --help` now describes the `--schema` option.",2021-07-24T22:17:47Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.12,2021-06-25,"- New [db.query(sql, params)](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-query) method, which executes a SQL query and returns the results as an iterator over Python dictionaries. ([#290](https://github.com/simonw/sqlite-utils/issues/290)) - This project now uses `flake8` and has started to use `mypy`. ([#291](https://github.com/simonw/sqlite-utils/issues/291)) - New documentation on [contributing](https://sqlite-utils.datasette.io/en/stable/contributing.html#contributing) to this project. ([#292](https://github.com/simonw/sqlite-utils/issues/292))",2021-06-25T18:00:18Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.11,2021-06-20,"- New `sqlite-utils memory data.csv --schema` option, for outputting the schema of the in-memory database generated from one or more files. See [--schema, --dump and --save](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-memory-schema-dump-save). ([#288](https://github.com/simonw/sqlite-utils/issues/288)) - Added [installation instructions](https://sqlite-utils.datasette.io/en/stable/installation.html#installation). ([#286](https://github.com/simonw/sqlite-utils/issues/286))",2021-06-20T18:53:09Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.10,2021-06-19,"This release introduces the `sqlite-utils memory` command, which can be used to load CSV or JSON data into a temporary in-memory database and run SQL queries (including joins across multiple files) directly against that data. Also new: `sqlite-utils insert --detect-types`, `sqlite-utils dump`, `table.use_rowid` plus some smaller fixes. ### sqlite-utils memory This example of `sqlite-utils memory` retrieves information about the all of the repositories in the [Dogsheep](https://github.com/dogsheep) organization on GitHub using [this JSON API](https://api.github.com/users/dogsheep/repos), sorts them by their number of stars and outputs a table of the top five (using `-t`): ``` $ curl -s 'https://api.github.com/users/dogsheep/repos'\ | sqlite-utils memory - ' select full_name, forks_count, stargazers_count from stdin order by stargazers_count desc limit 5 ' -t full_name forks_count stargazers_count --------------------------------- ------------- ------------------ dogsheep/twitter-to-sqlite 12 225 dogsheep/github-to-sqlite 14 139 dogsheep/dogsheep-photos 5 116 dogsheep/dogsheep.github.io 7 90 dogsheep/healthkit-to-sqlite 4 85 ``` The tool works against files on disk as well. This example joins data from two CSV files: ``` $ cat creatures.csv species_id,name 1,Cleo 2,Bants 2,Dori 2,Azi $ cat species.csv id,species_name 1,Dog 2,Chicken $ sqlite-utils memory species.csv creatures.csv ' select * from creatures join species on creatures.species_id = species.id ' [{""species_id"": 1, ""name"": ""Cleo"", ""id"": 1, ""species_name"": ""Dog""}, {""species_id"": 2, ""name"": ""Bants"", ""id"": 2, ""species_name"": ""Chicken""}, {""species_id"": 2, ""name"": ""Dori"", ""id"": 2, ""species_name"": ""Chicken""}, {""species_id"": 2, ""name"": ""Azi"", ""id"": 2, ""species_name"": ""Chicken""}] ``` Here the `species.csv` file becomes the `species` table, the `creatures.csv` file becomes the `creatures` table and the output is JSON, the default output format. You can also use the `--attach` option to attach existing SQLite database files to the in-memory database, in order to join data from CSV or JSON directly against your existing tables. Full documentation of this new feature is available in [Querying data directly using an in-memory database](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-memory). ([#272](https://github.com/simonw/sqlite-utils/issues/272)) ### sqlite-utils insert --detect-types The [sqlite-utils insert](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-inserting-data) command can be used to insert data from JSON, CSV or TSV files into a SQLite database file. The new `--detect-types` option (shortcut `-d`), when used in conjunction with a CSV or TSV import, will automatically detect if columns in the file are integers or floating point numbers as opposed to treating everything as a text column and create the new table with the corresponding schema. See [Inserting CSV or TSV data](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-insert-csv-tsv) for details. ([#282](https://github.com/simonw/sqlite-utils/issues/282)) ### Other changes - **Bug fix**: `table.transform()`, when run against a table without explicit primary keys, would incorrectly create a new version of the table with an explicit primary key column called `rowid`. ([#284](https://github.com/simonw/sqlite-utils/issues/284)) - New `table.use_rowid` introspection property, see [.use_rowid](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-introspection-use-rowid). ([#285](https://github.com/simonw/sqlite-utils/issues/285)) - The new `sqlite-utils dump file.db` command outputs a SQL dump that can be used to recreate a database. ([#274](https://github.com/simonw/sqlite-utils/issues/274)) - `-h` now works as a shortcut for `--help`, thanks Loren McIntyre. ([#276](https://github.com/simonw/sqlite-utils/issues/276)) - Now using [pytest-cov](https://pytest-cov.readthedocs.io/) and [Codecov](https://about.codecov.io/) to track test coverage - currently at 96%. ([#275](https://github.com/simonw/sqlite-utils/issues/275)) - SQL errors that occur when using `sqlite-utils query` are now displayed as CLI errors.",2021-06-19T16:13:11Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.9.1,2021-06-13,- Fixed bug when using `table.upsert_all()` to create a table with only a single column that is treated as the primary key. ([#271](https://github.com/simonw/sqlite-utils/issues/271)),2021-06-13T03:00:45Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.9,2021-06-12,"- New `sqlite-utils schema` command showing the full SQL schema for a database, see [Showing the schema (CLI)](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-schema). ([#268](https://github.com/simonw/sqlite-utils/issues/268)) - `db.schema` introspection property exposing the same feature to the Python library, see [Showing the schema (Python library)](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-schema).",2021-06-12T02:08:03Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.8,2021-06-03,"- New `sqlite-utils indexes` command to list indexes in a database, see [Listing indexes](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-indexes). ([#263](https://github.com/simonw/sqlite-utils/issues/263)) - `table.xindexes` introspection property returning more details about that table's indexes, see [.xindexes](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-introspection-xindexes). ([#261](https://github.com/simonw/sqlite-utils/issues/261))",2021-06-03T05:17:33Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.7,2021-05-29,"- New `table.pks_and_rows_where()` method returning `(primary_key, row_dictionary)` tuples - see [Listing rows with their primary keys](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-pks-and-rows-where). ([#240](https://github.com/simonw/sqlite-utils/issues/240)) - Fixed bug with *table.add_foreign_key()* against columns containing spaces. ([#238](https://github.com/simonw/sqlite-utils/issues/238)) - `table_or_view.drop(ignore=True)` option for avoiding errors if the table or view does not exist. ([#237](https://github.com/simonw/sqlite-utils/issues/237)) - `sqlite-utils drop-view --ignore` and `sqlite-utils drop-table --ignore` options. ([#237](https://github.com/simonw/sqlite-utils/issues/237)) - Fixed a bug with inserts of nested JSON containing non-ascii strings - thanks, Dylan Wu. ([#257](https://github.com/simonw/sqlite-utils/issues/257)) - Suggest `--alter` if an error occurs caused by a missing column. ([#259](https://github.com/simonw/sqlite-utils/issues/259)) - Support creating indexes with columns in descending order, see [API documentation](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-create-index) and [CLI documentation](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-create-index). ([#260](https://github.com/simonw/sqlite-utils/issues/260)) - Correctly handle CSV files that start with a UTF-8 BOM. ([#250](https://github.com/simonw/sqlite-utils/issues/250))",2021-05-29T05:49:59Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.6,2021-02-19,"This release adds the ability to execute queries joining data from more than one database file - similar to the cross database querying feature introduced in [Datasette 0.55](https://docs.datasette.io/en/stable/changelog.html#v0-55). - The `db.attach(alias, filepath)` Python method can be used to attach extra databases to the same connection, see [db.attach() in the Python API documentation](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-attach). ([#113](https://github.com/simonw/sqlite-utils/issues/113)) - The `--attach` option attaches extra aliased databases to run SQL queries against directly on the command-line, see [attaching additional databases in the CLI documentation](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-attach). ([#236](https://github.com/simonw/sqlite-utils/issues/236))",2021-02-19T05:19:00Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.5,2021-02-14,"- `sqlite-utils insert --sniff` option for detecting the delimiter and quote character used by a CSV file, see [Alternative delimiters and quote characters](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-insert-csv-tsv-delimiter). ([#230](https://github.com/simonw/sqlite-utils/issues/230)) - The `table.rows_where()`, `table.search()` and `table.search_sql()` methods all now take optional `offset=` and `limit=` arguments. ([#231](https://github.com/simonw/sqlite-utils/issues/231)) - New `--no-headers` option for `sqlite-utils insert --csv` to handle CSV files that are missing the header row, see [CSV files without a header row](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-insert-csv-tsv-no-header). ([#228](https://github.com/simonw/sqlite-utils/issues/228)) - Fixed bug where inserting data with extra columns in subsequent chunks would throw an error. Thanks [@nieuwenhoven](https://github.com/nieuwenhoven) for the fix. ([#234](https://github.com/simonw/sqlite-utils/issues/234)) - Fixed bug importing CSV files with columns containing more than 128KB of data. ([#229](https://github.com/simonw/sqlite-utils/issues/229)) - Test suite now runs in CI against Ubuntu, macOS and Windows. Thanks [@nieuwenhoven](https://github.com/nieuwenhoven) for the Windows test fixes. ([#232](https://github.com/simonw/sqlite-utils/issues/232))",2021-02-14T22:44:21Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.4.1,2021-02-06,- Fixed a code import bug that slipped in to 3.4. ([#226](https://github.com/simonw/sqlite-utils/issues/226)),2021-02-06T02:11:15Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.4,2021-02-06,- `sqlite-utils insert --csv` now accepts optional `--delimiter` and `--quotechar` options. See [Alternative delimiters and quote characters](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-insert-csv-tsv-delimiter). ([#223](https://github.com/simonw/sqlite-utils/issues/223)),2021-02-06T01:38:26Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.3,2021-01-18,- The `table.m2m()` method now accepts an optional `alter=True` argument to specify that any missing columns should be added to the referenced table. See [Working with many-to-many relationships](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-m2m). ([#222](https://github.com/simonw/sqlite-utils/issues/222)),2021-01-18T04:29:48Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.2.1,2021-01-12,- Fixed a bug where `.add_missing_columns()` failed to take case insensitive column names into account. ([#221](https://github.com/simonw/sqlite-utils/issues/221)),2021-01-12T23:23:25Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.2,2021-01-03,"This release introduces a new mechanism for speeding up `count(*)` queries using cached table counts, stored in a `_counts` table and updated by triggers. This mechanism is described in [Cached table counts using triggers](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-cached-table-counts), and can be enabled using Python API methods or the new `enable-counts` CLI command. ([#212](https://github.com/simonw/sqlite-utils/issues/212)) - `table.enable_counts()` method for enabling these triggers on a specific table. - `db.enable_counts()` method for enabling triggers on every table in the database. ([#213](https://github.com/simonw/sqlite-utils/issues/213)) - New `sqlite-utils enable-counts my.db` command for enabling counts on all or specific tables, see [Enabling cached counts](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-enable-counts). ([#214](https://github.com/simonw/sqlite-utils/issues/214)) - New `sqlite-utils triggers` command for listing the triggers defined for a database or specific tables, see [Listing triggers](https://sqlite-utils.datasette.io/en/stable/cli.html#cli-triggers). ([#218](https://github.com/simonw/sqlite-utils/issues/218)) - New `db.use_counts_table` property which, if `True`, causes `table.count` to read from the `_counts` table. ([#215](https://github.com/simonw/sqlite-utils/issues/215)) - `table.has_counts_triggers` property revealing if a table has been configured with the new `_counts` database triggers. - `db.reset_counts()` method and `sqlite-utils reset-counts` command for resetting the values in the `_counts` table. ([#219](https://github.com/simonw/sqlite-utils/issues/219)) - The previously undocumented `db.escape()` method has been renamed to `db.quote()` and is now covered by the documentation: [Quoting strings for use in SQL](https://sqlite-utils.datasette.io/en/stable/python-api.html#python-api-quote). ([#217](https://github.com/simonw/sqlite-utils/issues/217)) - New `table.triggers_dict` and `db.triggers_dict` introspection properties. ([#211](https://github.com/simonw/sqlite-utils/issues/211), [#216](https://github.com/simonw/sqlite-utils/issues/216)) - `sqlite-utils insert` now shows a more useful error message for invalid JSON. ([#206](https://github.com/simonw/sqlite-utils/issues/206))",2021-01-03T21:17:37Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.1.1,2021-01-01,"- Fixed failing test caused by `optimize` sometimes creating larger database files. ([#209](https://github.com/simonw/sqlite-utils/issues/209)) - Documentation now lives on - README now includes `brew install sqlite-utils` installation method.",2021-01-01T23:57:07Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.1,2020-12-13,"- New command: `sqlite-utils analyze-tables my.db` outputs useful information about the table columns in the database, such as the number of distinct values and how many rows are null. See [Analyzing tables](https://sqlite-utils.readthedocs.io/en/stable/cli.html#cli-analyze-tables) for documentation. ([#207](https://github.com/simonw/sqlite-utils/issues/207)) - New `table.analyze_column(column)` Python method used by the `analyze-tables` command - see [Analyzing a column](https://sqlite-utils.readthedocs.io/en/stable/python-api.html#python-api-analyze-column). - The `table.update()` method now correctly handles values that should be stored as JSON. Thanks, Andreas Madsack. ([#204](https://github.com/simonw/sqlite-utils/pull/204))",2020-12-13T07:31:40Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.0,2020-11-08,"This release introduces a new `sqlite-utils search` command for searching tables, see [Executing searches](https://sqlite-utils.readthedocs.io/en/latest/cli.html#cli-search). ([#192](https://github.com/simonw/sqlite-utils/issues/192)) The `table.search()` method has been redesigned, see [Searching with table.search()](https://sqlite-utils.readthedocs.io/en/latest/python-api.html#python-api-fts-search). ([#197](https://github.com/simonw/sqlite-utils/issues/197)) The release includes minor backwards-incompatible changes, hence the version bump to 3.0. Those changes, which should not affect most users, are: - The `-c` shortcut option for outputting CSV is no longer available. The full `--csv` option is required instead. - The `-f` shortcut for `--fmt` has also been removed - use `--fmt`. - The `table.search()` method now defaults to sorting by relevance, not sorting by `rowid`. ([#198](https://github.com/simonw/sqlite-utils/issues/198)) - The `table.search()` method now returns a generator over a list of Python dictionaries. It previously returned a list of tuples. Also in this release: - The `query`, `tables`, `rows` and `search` CLI commands now accept a new `--tsv` option which outputs the results in TSV. ([#193](https://github.com/simonw/sqlite-utils/issues/193)) - A new `table.virtual_table_using` property reveals if a table is a virtual table, and returns the upper case type of virtual table (e.g. `FTS4` or `FTS5`) if it is. It returns `None` if the table is not a virtual table. ([#196](https://github.com/simonw/sqlite-utils/issues/196)) - The new `table.search_sql()` method returns the SQL for searching a table, see [Building SQL queries with table.search_sql()](https://sqlite-utils.readthedocs.io/en/latest/python-api.html#python-api-fts-search-sql). - `sqlite-utils rows` now accepts multiple optional `-c` parameters specifying the columns to return. ([#200](https://github.com/simonw/sqlite-utils/issues/200)) Changes since the 3.0a0 alpha release: - The `sqlite-utils search` command now defaults to returning every result, unless you add a `--limit 20` option. - The `sqlite-utils search -c` and `table.search(columns=[])` options are now fully respected. ([#201](https://github.com/simonw/sqlite-utils/issues/201))",2020-11-08T17:24:27Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/3.0a0,2020-11-07,"This release introduces a new `sqlite-utils search` command for searching tables, see [Executing searches](https://sqlite-utils.readthedocs.io/en/latest/cli.html#cli-search). ([#192](https://github.com/simonw/sqlite-utils/issues/192)) The `table.search()` method has been redesigned, see [Searching with table.search()](https://sqlite-utils.readthedocs.io/en/latest/python-api.html#python-api-fts-search). ([#197](https://github.com/simonw/sqlite-utils/issues/197)) The release includes minor backwards-incompatible changes, hence the version bump to 3.0. Those changes, which should not affect most users, are: - The `-c` shortcut option for outputting CSV is no longer available. The full `--csv` option is required instead. - The `-f` shortcut for `--fmt` has also been removed - use `--fmt`. - The `table.search()` method now defaults to sorting by relevance, not sorting by `rowid`. ([#198](https://github.com/simonw/sqlite-utils/issues/198)) - The `table.search()` method now returns a generator over a list of Python dictionaries. It previously returned a list of tuples. Also in this release: - The `query`, `tables`, `rows` and `search` CLI commands now accept a new `--tsv` option which outputs the results in TSV. ([#193](https://github.com/simonw/sqlite-utils/issues/193)) - A new `table.virtual_table_using` property reveals if a table is a virtual table, and returns the upper case type of virtual table (e.g. `FTS4` or `FTS5`) if it is. It returns `None` if the table is not a virtual table. ([#196](https://github.com/simonw/sqlite-utils/issues/196)) - The new `table.search_sql()` method returns the SQL for searching a table, see [Building SQL queries with table.search_sql()](https://sqlite-utils.readthedocs.io/en/latest/python-api.html#python-api-fts-search-sql). - `sqlite-utils rows` now accepts multiple optional `-c` parameters specifying the columns to return. ([#200](https://github.com/simonw/sqlite-utils/issues/200))",2020-11-07T01:24:43Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.23,2020-10-28,"- `table.m2m(other_table, records)` method now takes any iterable, not just a list or tuple. Thanks, Adam Wolf. ([#189](https://github.com/simonw/sqlite-utils/pull/189)) - `sqlite-utils insert` now displays a progress bar for CSV or TSV imports. ([#173](https://github.com/simonw/sqlite-utils/issues/173)) - New `@db.register_function(deterministic=True)` option for registering deterministic SQLite functions in Python 3.8 or higher. ([#191](https://github.com/simonw/sqlite-utils/issues/191))",2020-10-28T21:38:54Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.22,2020-10-16,"- New `--encoding` option for processing CSV and TSV files that use a non-utf-8 encoding, for both the `insert` and `update` commands. ([#182](https://github.com/simonw/sqlite-utils/issues/182)) - The `--load-extension` option is now available to many more commands. ([#137](https://github.com/simonw/sqlite-utils/issues/137)) - `--load-extension=spatialite` can be used to load SpatiaLite from common installation locations, if it is available. ([#136](https://github.com/simonw/sqlite-utils/issues/136)) - Tests now also run against Python 3.9. ([#184](https://github.com/simonw/sqlite-utils/issues/184)) - Passing `pk=[""id""]` now has the same effect as passing `pk=""id""`. ([#181](https://github.com/simonw/sqlite-utils/issues/181))",2020-10-16T19:31:45Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.21,2020-09-24,"- `table.extract()` and `sqlite-utils extract` now apply much, much faster - one example operation reduced from twelve minutes to just four seconds! ([#172](https://github.com/simonw/sqlite-utils/issues/172)) - `sqlite-utils extract` no longer shows a progress bar, because it's fast enough not to need one. - New `column_order=` option for `table.transform()` which can be used to alter the order of columns in a table. ([#175](https://github.com/simonw/sqlite-utils/issues/175)) - `sqlite-utils transform --column-order=` option (with a `-o` shortcut) for changing column order. ([#176](https://github.com/simonw/sqlite-utils/issues/176)) - The `table.transform(drop_foreign_keys=)` parameter and the `sqlite-utils transform --drop-foreign-key` option have changed. They now accept just the name of the column rather than requiring all three of the column, other table and other column. This is technically a backwards-incompatible change but I chose not to bump the major version number because the transform feature is so new. ([#177](https://github.com/simonw/sqlite-utils/issues/177)) - The table `.disable_fts()`, `.rebuild_fts()`, `.delete()`, `.delete_where()` and `.add_missing_columns()` methods all now `return self`, which means they can be chained together with other table operations.",2020-09-24T16:45:44Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.20,2020-09-23,"This release introduces two key new capabilities: **transform** ([#114](https://github.com/simonw/sqlite-utils/issues/114)) and **extract** ([#42](https://github.com/simonw/sqlite-utils/issues/42)). ### Transform SQLite's ALTER TABLE has [several documented limitations](https://sqlite.org/lang_altertable.html). The `table.transform()` Python method and `sqlite-utils transform` CLI command work around these limitations using a pattern where a new table with the desired structure is created, data is copied over to it and the old table is then dropped and replaced by the new one. You can use these tools to drop columns, change column types, rename columns, add and remove `NOT NULL` and defaults, remove foreign key constraints and more. See the [transforming tables (CLI)](https://sqlite-utils.readthedocs.io/en/stable/cli.html#cli-transform-table) and [transforming tables (Python library)](https://sqlite-utils.readthedocs.io/en/stable/python-api.html#python-api-transform) documentation for full details of how to use them. ### Extract Sometimes a database table - especially one imported from a CSV file - will contain duplicate data. A `Trees` table may include a `Species` column with only a few dozen unique values, when the table itself contains thousands of rows. The `table.extract()` method and `sqlite-utils extract` commands can extract a column - or multiple columns - out into a separate lookup table, and set up a foreign key relationship from the original table. The Python library [extract() documentation](https://sqlite-utils.readthedocs.io/en/stable/python-api.html#python-api-extract) describes how extraction works in detail, and [Extracting columns into a separate table](https://sqlite-utils.readthedocs.io/en/stable/cli.html#cli-extract) in the CLI documentation includes a detailed example. ### Other changes - The `@db.register_function` decorator can be used to quickly register Python functions as custom SQL functions, see [Registering custom SQL functions](https://sqlite-utils.readthedocs.io/en/stable/python-api.html#python-api-register-function). ([#162](https://github.com/simonw/sqlite-utils/issues/162)) - The `table.rows_where()` method now accepts an optional `select=` argument for specifying which columns should be selected, see [Listing rows](https://sqlite-utils.readthedocs.io/en/stable/python-api.html#python-api-rows).",2020-09-23T00:37:01Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.19,2020-09-20,"- New `sqlite-utils add-foreign-keys` command for [Adding multiple foreign keys at once](https://sqlite-utils.readthedocs.io/en/stable/cli.html#cli-add-foreign-keys). ([#157](https://github.com/simonw/sqlite-utils/issues/157)) - New `table.enable_fts(..., replace=True)` argument for replacing an existing FTS table with a new configuration. ([#160](https://github.com/simonw/sqlite-utils/issues/160)) - New `table.add_foreign_key(..., ignore=True)` argument for ignoring a foreign key if it already exists. ([#112](https://github.com/simonw/sqlite-utils/issues/112))",2020-09-20T22:24:04Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.18,2020-09-08,"- `table.rebuild_fts()` method for rebuilding a FTS index, see [Rebuilding a full-text search table](https://sqlite-utils.readthedocs.io/en/stable/python-api.html#python-api-fts-rebuild). ([#155](https://github.com/simonw/sqlite-utils/issues/155)) - `sqlite-utils rebuild-fts data.db` command for rebuilding FTS indexes across all tables, or just specific tables. ([#155](https://github.com/simonw/sqlite-utils/issues/155)) - `table.optimize()` method no longer deletes junk rows from the `*_fts_docsize` table. This was added in 2.17 but it turns out running `table.rebuild_fts()` is a better solution to this problem. - Fixed a bug where rows with additional columns that are inserted after the first batch of records could cause an error due to breaking SQLite's maximum number of parameters. Thanks, Simon Wiles. ([#145](https://github.com/simonw/sqlite-utils/issues/145))",2020-09-08T23:39:21Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.17,2020-09-07,"This release handles a bug where replacing rows in FTS tables could result in growing numbers of unneccessary rows in the associated `*_fts_docsize` table. ([#149](https://github.com/simonw/sqlite-utils/issues/149)) - `PRAGMA recursive_triggers=on` by default for all connections. You can turn it off with `Database(recursive_triggers=False)`. ([#152](https://github.com/simonw/sqlite-utils/issues/152)) - `table.optimize()` method now deletes unnecessary rows from the `*_fts_docsize` table. ([#153](https://github.com/simonw/sqlite-utils/issues/153)) - New tracer method for tracking underlying SQL queries, see [Tracing queries](http://127.0.0.1:8000/python-api.html#python-api-tracing). ([#150](https://github.com/simonw/sqlite-utils/issues/150)) - Neater indentation for schema SQL. ([#148](https://github.com/simonw/sqlite-utils/issues/148)) - Documentation for `sqlite_utils.AlterError` exception thrown by in `add_foreign_keys()`.",2020-09-07T22:08:33Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.16.1,2020-08-28,"- `insert_all(..., alter=True)` now works for columns introduced after the first 100 records. Thanks, Simon Wiles! ([#139](https://github.com/simonw/sqlite-utils/issues/139)) - Continuous Integration is now powered by GitHub Actions. ([#143](https://github.com/simonw/sqlite-utils/issues/143))",2020-08-28T22:47:02Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.16,2020-08-21,"- `--load-extension` option for `sqlite-utils query` for loading SQLite extensions. ([#134](https://github.com/simonw/sqlite-utils/issues/134)) - New `sqlite_utils.utils.find_spatialite()` function for finding SpatiaLite in common locations. ([#135](https://github.com/simonw/sqlite-utils/issues/135))",2020-08-21T21:05:51Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.15.1,2020-08-12,- Now available as a `sdist` package on PyPI in addition to a wheel. ([#133](https://github.com/simonw/sqlite-utils/issues/133)),2020-08-12T17:00:27Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.15,2020-08-10,"- New `db.enable_wal()` and `db.disable_wal()` methods for enabling and disabling [Write-Ahead Logging](https://www.sqlite.org/wal.html) for a database file - see [WAL mode](https://sqlite-utils.readthedocs.io/en/stable//python-api.html#python-api-wal) in the Python API documentation. - Also `sqlite-utils enable-wal file.db` and `sqlite-utils disable-wal file.db` commands for doing the same thing on the command-line, see [WAL mode (CLI)](https://sqlite-utils.readthedocs.io/en/stable/cli.html#cli-wal). ([#132](https://github.com/simonw/sqlite-utils/issues/132))",2020-08-10T19:07:27Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.14.1,2020-08-06,- Documentation improvements,2020-08-06T06:31:48Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.14,2020-08-01,"- The [insert-files command](https://sqlite-utils.readthedocs.io/en/stable/cli.html#cli-insert-files) can now read from standard input: `cat dog.jpg | sqlite-utils insert-files dogs.db pics - --name=dog.jpg`. ([#127](https://github.com/simonw/sqlite-utils/issues/127)) - You can now specify a full-text search tokenizer using the new `tokenize=` parameter to [enable_fts()](https://sqlite-utils.readthedocs.io/en/stable/python-api.html#python-api-fts). This means you can enable Porter stemming on a table by running `db[""articles""].enable_fts([""headline"", ""body""], tokenize=""porter"")`. ([#130](https://github.com/simonw/sqlite-utils/issues/130)) - You can also set a custom tokenizer using the [sqlite-utils enable-fts](https://sqlite-utils.readthedocs.io/en/stable/cli.html#cli-fts) CLI command, via the new `--tokenize` option.",2020-08-01T21:00:31Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.13,2020-07-30,"- `memoryview` and `uuid.UUID` objects are now supported. `memoryview` objects will be stored using `BLOB` and `uuid.UUID` objects will be stored using `TEXT`. (#128) ",2020-07-30T01:15:55Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.12,2020-07-27,"The theme of this release is better tools for working with binary data. The new `insert-files` command can be used to insert binary files directly into a database table, and other commands have been improved with better support for BLOB columns. - `sqlite-utils insert-files my.db gifs *.gif` can now insert the contents of files into a specified table. The columns in the table can be customized to include different pieces of metadata derived from the files. See [Inserting binary data from files](https://sqlite-utils.readthedocs.io/en/stable/cli.html#cli-insert-files). ([#122](https://github.com/simonw/sqlite-utils/issues/122)) - `--raw` option to `sqlite-utils query` - for outputting just a single raw column value - see [Returning raw data from a query, such as binary content](https://sqlite-utils.readthedocs.io/en/stable/cli.html#cli-query-raw). ([#123](https://github.com/simonw/sqlite-utils/issues/123)) - JSON output now encodes BLOB values as special base64 obects - see [Running queries and returning JSON](https://sqlite-utils.readthedocs.io/en/stable/cli.html#cli-query-json). ([#125](https://github.com/simonw/sqlite-utils/issues/125)) - The same format of JSON base64 objects can now be used to insert binary data - see [Inserting JSON data](https://sqlite-utils.readthedocs.io/en/stable/cli.html#cli-inserting-data). ([#126](https://github.com/simonw/sqlite-utils/issues/126)) - The `sqlite-utils query` command can now accept named parameters, e.g. `sqlite-utils :memory: ""select :num * :num2"" -p num 5 -p num2 6` - see [Running queries and returning JSON](https://sqlite-utils.readthedocs.io/en/stable/cli.html#cli-query-json). ([#124](https://github.com/simonw/sqlite-utils/issues/124))",2020-07-27T07:24:10Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.11,2020-07-08,"- New `--truncate` option to `sqlite-utils insert`, and `truncate=True` argument to `.insert_all()`. Thanks, Thomas Sibley. ([#118](https://github.com/simonw/sqlite-utils/pull/118)) - The `sqlite-utils query` command now runs updates in a transaction. Thanks, Thomas Sibley. ([#120](https://github.com/simonw/sqlite-utils/pull/120))",2020-07-08T17:36:45Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]" 140912432,https://github.com/simonw/sqlite-utils,https://github.com/simonw/sqlite-utils/releases/tag/2.10.1,2020-06-23,* Added documentation for the `table.pks` introspection property. #116,2020-06-23T21:04:50Z,"[""cli"", ""click"", ""datasette"", ""datasette-io"", ""datasette-tool"", ""python"", ""sqlite"", ""sqlite-database""]"