id,page,ref,title,content,breadcrumbs,references changelog:id83,changelog,id83,0.29.1 (2019-07-11),"Fixed bug with static mounts using relative paths which could lead to traversal exploits ( #555 ) - thanks Abdussamet Kocak! Datasette can now be run as a module: python -m datasette ( #556 ) - thanks, Abdussamet Kocak!","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/555"", ""label"": ""#555""}, {""href"": ""https://github.com/simonw/datasette/issues/556"", ""label"": ""#556""}]" changelog:id81,changelog,id81,0.29.3 (2019-09-02),"Fixed implementation of CodeMirror on database page ( #560 ) Documentation typo fixes - thanks, Min ho Kim ( #561 ) Mechanism for detecting if a table has FTS enabled now works if the table name used alternative escaping mechanisms ( #570 ) - for compatibility with a recent change to sqlite-utils .","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/560"", ""label"": ""#560""}, {""href"": ""https://github.com/simonw/datasette/pull/561"", ""label"": ""#561""}, {""href"": ""https://github.com/simonw/datasette/issues/570"", ""label"": ""#570""}, {""href"": ""https://github.com/simonw/sqlite-utils/pull/57"", ""label"": ""a recent change to sqlite-utils""}]" changelog:id70,changelog,id70,0.36 (2020-02-21),"The datasette object passed to plugins now has API documentation: Datasette class . ( #576 ) New methods on datasette : .add_database() and .remove_database() - documentation . ( #671 ) prepare_connection() plugin hook now takes optional datasette and database arguments - prepare_connection(conn, database, datasette) . ( #678 ) Added three new plugins and one new conversion tool to the The Datasette Ecosystem .","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/576"", ""label"": ""#576""}, {""href"": ""https://github.com/simonw/datasette/issues/671"", ""label"": ""#671""}, {""href"": ""https://github.com/simonw/datasette/issues/678"", ""label"": ""#678""}]" changelog:id80,changelog,id80,0.30 (2019-10-18),"Added /-/threads debugging page Allow EXPLAIN WITH... ( #583 ) Button to format SQL - thanks, Tobias Kunze ( #136 ) Sort databases on homepage by argument order - thanks, Tobias Kunze ( #585 ) Display metadata footer on custom SQL queries - thanks, Tobias Kunze ( #589 ) Use --platform=managed for publish cloudrun ( #587 ) Fixed bug returning non-ASCII characters in CSV ( #584 ) Fix for /foo v.s. /foo-bar bug ( #601 )","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/583"", ""label"": ""#583""}, {""href"": ""https://github.com/simonw/datasette/issues/136"", ""label"": ""#136""}, {""href"": ""https://github.com/simonw/datasette/issues/585"", ""label"": ""#585""}, {""href"": ""https://github.com/simonw/datasette/pull/589"", ""label"": ""#589""}, {""href"": ""https://github.com/simonw/datasette/issues/587"", ""label"": ""#587""}, {""href"": ""https://github.com/simonw/datasette/issues/584"", ""label"": ""#584""}, {""href"": ""https://github.com/simonw/datasette/issues/601"", ""label"": ""#601""}]" changelog:id79,changelog,id79,0.30.1 (2019-10-30),"Fixed bug where ?_where= parameter was not persisted in hidden form fields ( #604 ) Fixed bug with .JSON representation of row pages - thanks, Chris Shaw ( #603 )","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/604"", ""label"": ""#604""}, {""href"": ""https://github.com/simonw/datasette/issues/603"", ""label"": ""#603""}]" changelog:id78,changelog,id78,0.30.2 (2019-11-02),"/-/plugins page now uses distribution name e.g. datasette-cluster-map instead of the name of the underlying Python package ( datasette_cluster_map ) ( #606 ) Array faceting is now only suggested for columns that contain arrays of strings ( #562 ) Better documentation for the --host argument ( #574 ) Don't show None with a broken link for the label on a nullable foreign key ( #406 )","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/606"", ""label"": ""#606""}, {""href"": ""https://github.com/simonw/datasette/issues/562"", ""label"": ""#562""}, {""href"": ""https://github.com/simonw/datasette/issues/574"", ""label"": ""#574""}, {""href"": ""https://github.com/simonw/datasette/issues/406"", ""label"": ""#406""}]" changelog:new-features,changelog,new-features,New features,"If an error occurs while executing a user-provided SQL query, that query is now re-displayed in an editable form along with the error message. ( #619 ) New ?_col= and ?_nocol= parameters to show and hide columns in a table, plus an interface for hiding and showing columns in the column cog menu. ( #615 ) A new ?_facet_size= parameter for customizing the number of facet results returned on a table or view page. ( #1332 ) ?_facet_size=max sets that to the maximum, which defaults to 1,000 and is controlled by the the max_returned_rows setting. If facet results are truncated the … at the bottom of the facet list now links to this parameter. ( #1337 ) ?_nofacet=1 option to disable all facet calculations on a page, used as a performance optimization for CSV exports and ?_shape=array/object . ( #1349 , #263 ) ?_nocount=1 option to disable full query result counts. ( #1353 ) ?_trace=1 debugging option is now controlled by the new trace_debug setting, which is turned off by default. ( #1359 )","[""Changelog"", ""0.57 (2021-06-05)""]","[{""href"": ""https://github.com/simonw/datasette/issues/619"", ""label"": ""#619""}, {""href"": ""https://github.com/simonw/datasette/issues/615"", ""label"": ""#615""}, {""href"": ""https://github.com/simonw/datasette/issues/1332"", ""label"": ""#1332""}, {""href"": ""https://github.com/simonw/datasette/issues/1337"", ""label"": ""#1337""}, {""href"": ""https://github.com/simonw/datasette/issues/1349"", ""label"": ""#1349""}, {""href"": ""https://github.com/simonw/datasette/issues/263"", ""label"": ""#263""}, {""href"": ""https://github.com/simonw/datasette/issues/1353"", ""label"": ""#1353""}, {""href"": ""https://github.com/simonw/datasette/issues/1359"", ""label"": ""#1359""}]" changelog:id75,changelog,id75,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 )","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/633"", ""label"": ""#633""}, {""href"": ""https://github.com/simonw/datasette/issues/572"", ""label"": ""#572""}, {""href"": ""https://github.com/simonw/datasette/issues/632"", ""label"": ""#632""}]" changelog:id73,changelog,id73,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 )","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/636"", ""label"": ""#636""}, {""href"": ""https://github.com/simonw/datasette/issues/638"", ""label"": ""#638""}, {""href"": ""https://github.com/simonw/datasette/issues/637"", ""label"": ""#637""}, {""href"": ""https://github.com/simonw/datasette/issues/641"", ""label"": ""#641""}, {""href"": ""https://latest.datasette.io/fixtures/roadside_attractions?_context=1"", ""label"": ""https://latest.datasette.io/fixtures/roadside_attractions?_context=1""}, {""href"": ""https://github.com/simonw/datasette/issues/654"", ""label"": ""#654""}]" changelog:id64,changelog,id64,0.41 (2020-05-06),"You can now create custom pages within your Datasette instance using a custom template file. For example, adding a template file called templates/pages/about.html will result in a new page being served at /about on your instance. See the custom pages documentation for full details, including how to return custom HTTP headers, redirects and status codes. ( #648 ) Configuration directory mode ( #731 ) allows you to define a custom Datasette instance as a directory. So instead of running the following: datasette one.db two.db \ --metadata=metadata.json \ --template-dir=templates/ \ --plugins-dir=plugins \ --static css:css You can instead arrange your files in a single directory called my-project and run this: datasette my-project/ Also in this release: New NOT LIKE table filter: ?colname__notlike=expression . ( #750 ) Datasette now has a pattern portfolio at /-/patterns - e.g. https://latest.datasette.io/-/patterns . This is a page that shows every Datasette user interface component in one place, to aid core development and people building custom CSS themes. ( #151 ) SQLite PRAGMA functions such as pragma_table_info(tablename) are now allowed in Datasette SQL queries. ( #761 ) Datasette pages now consistently return a content-type of text/html; charset=utf-8"" . ( #752 ) Datasette now handles an ASGI raw_path value of None , which should allow compatibility with the Mangum adapter for running ASGI apps on AWS Lambda. Thanks, Colin Dellow. ( #719 ) Installation documentation now covers how to Using pipx . ( #756 ) Improved the documentation for Full-text search . ( #748 )","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/648"", ""label"": ""#648""}, {""href"": ""https://github.com/simonw/datasette/issues/731"", ""label"": ""#731""}, {""href"": ""https://github.com/simonw/datasette/issues/750"", ""label"": ""#750""}, {""href"": ""https://latest.datasette.io/-/patterns"", ""label"": ""https://latest.datasette.io/-/patterns""}, {""href"": ""https://github.com/simonw/datasette/issues/151"", ""label"": ""#151""}, {""href"": ""https://www.sqlite.org/pragma.html#pragfunc"", ""label"": ""PRAGMA functions""}, {""href"": ""https://github.com/simonw/datasette/issues/761"", ""label"": ""#761""}, {""href"": ""https://github.com/simonw/datasette/issues/752"", ""label"": ""#752""}, {""href"": ""https://github.com/erm/mangum"", ""label"": ""Mangum""}, {""href"": ""https://github.com/simonw/datasette/pull/719"", ""label"": ""#719""}, {""href"": ""https://github.com/simonw/datasette/issues/756"", ""label"": ""#756""}, {""href"": ""https://github.com/simonw/datasette/issues/748"", ""label"": ""#748""}]" changelog:id72,changelog,id72,0.34 (2020-01-29),"_search= queries are now correctly escaped using a new escape_fts() custom SQL function. This means you can now run searches for strings like park. without seeing errors. ( #651 ) Google Cloud Run is no longer in beta, so datasette publish cloudrun has been updated to work even if the user has not installed the gcloud beta components package. Thanks, Katie McLaughlin ( #660 ) datasette package now accepts a --port option for specifying which port the resulting Docker container should listen on. ( #661 )","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/651"", ""label"": ""#651""}, {""href"": ""https://cloud.google.com/run/"", ""label"": ""Google Cloud Run""}, {""href"": ""https://github.com/simonw/datasette/pull/660"", ""label"": ""#660""}, {""href"": ""https://github.com/simonw/datasette/issues/661"", ""label"": ""#661""}]" changelog:id69,changelog,id69,0.37 (2020-02-25),"Plugins now have a supported mechanism for writing to a database, using the new .execute_write() and .execute_write_fn() methods. Documentation . ( #682 ) Immutable databases that have had their rows counted using the inspect command now use the calculated count more effectively - thanks, Kevin Keogh. ( #666 ) --reload no longer restarts the server if a database file is modified, unless that database was opened immutable mode with -i . ( #494 ) New ?_searchmode=raw option turns off escaping for FTS queries in ?_search= allowing full use of SQLite's FTS5 query syntax . ( #676 )","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/682"", ""label"": ""#682""}, {""href"": ""https://github.com/simonw/datasette/pull/666"", ""label"": ""#666""}, {""href"": ""https://github.com/simonw/datasette/issues/494"", ""label"": ""#494""}, {""href"": ""https://www.sqlite.org/fts5.html#full_text_query_syntax"", ""label"": ""FTS5 query syntax""}, {""href"": ""https://github.com/simonw/datasette/issues/676"", ""label"": ""#676""}]" changelog:id63,changelog,id63,0.42 (2020-05-08),"A small release which provides improved internal methods for use in plugins, along with documentation. See #685 . Added documentation for db.execute() , see await db.execute(sql, ...) . Renamed db.execute_against_connection_in_thread() to db.execute_fn() and made it a documented method, see await db.execute_fn(fn) . New results.first() and results.single_value() methods, plus documentation for the Results class - see Results .","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/685"", ""label"": ""#685""}]" changelog:better-plugin-documentation,changelog,better-plugin-documentation,Better plugin documentation,"The plugin documentation has been re-arranged into four sections, including a brand new section on testing plugins. ( #687 ) Plugins introduces Datasette's plugin system and describes how to install and configure plugins. Writing plugins describes how to author plugins, from one-off single file plugins to packaged plugins that can be published to PyPI. It also describes how to start a plugin using the new datasette-plugin cookiecutter template. Plugin hooks is a full list of detailed documentation for every Datasette plugin hook. Testing plugins describes how to write tests for Datasette plugins, using pytest and HTTPX .","[""Changelog"", ""0.45 (2020-07-01)""]","[{""href"": ""https://github.com/simonw/datasette/issues/687"", ""label"": ""#687""}, {""href"": ""https://github.com/simonw/datasette-plugin"", ""label"": ""datasette-plugin""}, {""href"": ""https://docs.pytest.org/"", ""label"": ""pytest""}, {""href"": ""https://www.python-httpx.org/"", ""label"": ""HTTPX""}]" changelog:id68,changelog,id68,0.37.1 (2020-03-02),"Don't attempt to count table rows to display on the index page for databases > 100MB. ( #688 ) Print exceptions if they occur in the write thread rather than silently swallowing them. Handle the possibility of scope[""path""] being a string rather than bytes Better documentation for the extra_template_vars(template, database, table, columns, view_name, request, datasette) plugin hook.","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/688"", ""label"": ""#688""}]" changelog:id212,changelog,id212,0.8 (2017-11-13),"V0.8 - added PyPI metadata, ready to ship. Implemented offset/limit pagination for views ( #70 ). Improved pagination. ( #78 ) Limit on max rows returned, controlled by --max_returned_rows option. ( #69 ) If someone executes 'select * from table' against a table with a million rows in it, we could run into problems: just serializing that much data as JSON is likely to lock up the server. Solution: we now have a hard limit on the maximum number of rows that can be returned by a query. If that limit is exceeded, the server will return a ""truncated"": true field in the JSON. This limit can be optionally controlled by the new --max_returned_rows option. Setting that option to 0 disables the limit entirely.","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/70"", ""label"": ""#70""}, {""href"": ""https://github.com/simonw/datasette/issues/78"", ""label"": ""#78""}, {""href"": ""https://github.com/simonw/datasette/issues/69"", ""label"": ""#69""}]" changelog:id61,changelog,id61,Smaller changes,"New internals documentation for Request object and Response class . ( #706 ) request.url now respects the force_https_urls config setting. closes ( #781 ) request.args.getlist() returns [] if missing. Removed request.raw_args entirely. ( #774 ) New datasette.get_database() method. Added _ prefix to many private, undocumented methods of the Datasette class. ( #576 ) Removed the db.get_outbound_foreign_keys() method which duplicated the behaviour of db.foreign_keys_for_table() . New await datasette.permission_allowed() method. /-/actor debugging endpoint for viewing the currently authenticated actor. New request.cookies property. /-/plugins endpoint now shows a list of hooks implemented by each plugin, e.g. https://latest.datasette.io/-/plugins?all=1 request.post_vars() method no longer discards empty values. New ""params"" canned query key for explicitly setting named parameters, see Canned query parameters . ( #797 ) request.args is now a MultiParams object. Fixed a bug with the datasette plugins command. ( #802 ) Nicer pattern for using make_app_client() in tests. ( #395 ) New request.actor property. Fixed broken CSS on nested 404 pages. ( #777 ) New request.url_vars property. ( #822 ) Fixed a bug with the python tests/fixtures.py command for outputting Datasette's testing fixtures database and plugins. ( #804 ) datasette publish heroku now deploys using Python 3.8.3. Added a warning that the register_facet_classes() hook is unstable and may change in the future. ( #830 ) The {""$env"": ""ENVIRONMENT_VARIBALE""} mechanism (see Secret configuration values ) now works with variables inside nested lists. ( #837 )","[""Changelog"", ""0.44 (2020-06-11)""]","[{""href"": ""https://github.com/simonw/datasette/issues/706"", ""label"": ""#706""}, {""href"": ""https://github.com/simonw/datasette/issues/781"", ""label"": ""#781""}, {""href"": ""https://github.com/simonw/datasette/issues/774"", ""label"": ""#774""}, {""href"": ""https://github.com/simonw/datasette/issues/576"", ""label"": ""#576""}, {""href"": ""https://latest.datasette.io/-/plugins?all=1"", ""label"": ""https://latest.datasette.io/-/plugins?all=1""}, {""href"": ""https://github.com/simonw/datasette/issues/797"", ""label"": ""#797""}, {""href"": ""https://github.com/simonw/datasette/issues/802"", ""label"": ""#802""}, {""href"": ""https://github.com/simonw/datasette/issues/395"", ""label"": ""#395""}, {""href"": ""https://github.com/simonw/datasette/issues/777"", ""label"": ""#777""}, {""href"": ""https://github.com/simonw/datasette/issues/822"", ""label"": ""#822""}, {""href"": ""https://github.com/simonw/datasette/issues/804"", ""label"": ""#804""}, {""href"": ""https://github.com/simonw/datasette/issues/830"", ""label"": ""#830""}, {""href"": ""https://github.com/simonw/datasette/issues/837"", ""label"": ""#837""}]" changelog:id65,changelog,id65,0.40 (2020-04-21),"Datasette Metadata can now be provided as a YAML file as an optional alternative to JSON. ( #713 ) Removed support for datasette publish now , which used the the now-retired Zeit Now v1 hosting platform. A new plugin, datasette-publish-now , can be installed to publish data to Zeit ( now Vercel ) Now v2. ( #710 ) Fixed a bug where the extra_template_vars(request, view_name) plugin hook was not receiving the correct view_name . ( #716 ) Variables added to the template context by the extra_template_vars() plugin hook are now shown in the ?_context=1 debugging mode (see template_debug ). ( #693 ) Fixed a bug where the ""templates considered"" HTML comment was no longer being displayed. ( #689 ) Fixed a datasette publish bug where --plugin-secret would over-ride plugin configuration in the provided metadata.json file. ( #724 ) Added a new CSS class for customizing the canned query page. ( #727 )","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/713"", ""label"": ""#713""}, {""href"": ""https://github.com/simonw/datasette-publish-now"", ""label"": ""datasette-publish-now""}, {""href"": ""https://vercel.com/blog/zeit-is-now-vercel"", ""label"": ""now Vercel""}, {""href"": ""https://github.com/simonw/datasette/issues/710"", ""label"": ""#710""}, {""href"": ""https://github.com/simonw/datasette/issues/716"", ""label"": ""#716""}, {""href"": ""https://github.com/simonw/datasette/issues/693"", ""label"": ""#693""}, {""href"": ""https://github.com/simonw/datasette/issues/689"", ""label"": ""#689""}, {""href"": ""https://github.com/simonw/datasette/issues/724"", ""label"": ""#724""}, {""href"": ""https://github.com/simonw/datasette/issues/727"", ""label"": ""#727""}]" changelog:v1-0-a3,changelog,v1-0-a3,1.0a3 (2023-08-09),"This alpha release previews the updated design for Datasette's default JSON API. ( #782 ) The new default JSON representation for both table pages ( /dbname/table.json ) and arbitrary SQL queries ( /dbname.json?sql=... ) is now shaped like this: { ""ok"": true, ""rows"": [ { ""id"": 3, ""name"": ""Detroit"" }, { ""id"": 2, ""name"": ""Los Angeles"" }, { ""id"": 4, ""name"": ""Memnonia"" }, { ""id"": 1, ""name"": ""San Francisco"" } ], ""truncated"": false } Tables will include an additional ""next"" key for pagination, which can be passed to ?_next= to fetch the next page of results. The various ?_shape= options continue to work as before - see Different shapes for details. A new ?_extra= mechanism is available for tables, but has not yet been stabilized or documented. Details on that are available in #262 .","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/782"", ""label"": ""#782""}, {""href"": ""https://github.com/simonw/datasette/issues/262"", ""label"": ""#262""}]" changelog:permissions,changelog,permissions,Permissions,"Datasette also now has a built-in concept of Permissions . The permissions system answers the following question: Is this actor allowed to perform this action , optionally against this particular resource ? You can use the new ""allow"" block syntax in metadata.json (or metadata.yaml ) to set required permissions at the instance, database, table or canned query level. For example, to restrict access to the fixtures.db database to the ""root"" user: { ""databases"": { ""fixtures"": { ""allow"": { ""id"" ""root"" } } } } See Defining permissions with ""allow"" blocks for more details. Plugins can implement their own custom permission checks using the new permission_allowed(datasette, actor, action, resource) hook. A new debug page at /-/permissions shows recent permission checks, to help administrators and plugin authors understand exactly what checks are being performed. This tool defaults to only being available to the root user, but can be exposed to other users by plugins that respond to the permissions-debug permission. ( #788 )","[""Changelog"", ""0.44 (2020-06-11)""]","[{""href"": ""https://github.com/simonw/datasette/issues/788"", ""label"": ""#788""}]" changelog:flash-messages,changelog,flash-messages,Flash messages,"Writable canned queries needed a mechanism to let the user know that the query has been successfully executed. The new flash messaging system ( #790 ) allows messages to persist in signed cookies which are then displayed to the user on the next page that they visit. Plugins can use this mechanism to display their own messages, see .add_message(request, message, type=datasette.INFO) for details. You can try out the new messages using the /-/messages debug tool, for example at https://latest.datasette.io/-/messages","[""Changelog"", ""0.44 (2020-06-11)""]","[{""href"": ""https://github.com/simonw/datasette/issues/790"", ""label"": ""#790""}, {""href"": ""https://latest.datasette.io/-/messages"", ""label"": ""https://latest.datasette.io/-/messages""}]" changelog:csrf-protection,changelog,csrf-protection,CSRF protection,"Since writable canned queries are built using POST forms, Datasette now ships with CSRF protection ( #798 ). This applies automatically to any POST request, which means plugins need to include a csrftoken in any POST forms that they render. They can do that like so: ","[""Changelog"", ""0.44 (2020-06-11)""]","[{""href"": ""https://github.com/simonw/datasette/issues/798"", ""label"": ""#798""}]" changelog:register-routes-plugin-hooks,changelog,register-routes-plugin-hooks,register_routes() plugin hooks,"Plugins can now register new views and routes via the register_routes(datasette) plugin hook ( #819 ). View functions can be defined that accept any of the current datasette object, the current request , or the ASGI scope , send and receive objects.","[""Changelog"", ""0.44 (2020-06-11)""]","[{""href"": ""https://github.com/simonw/datasette/issues/819"", ""label"": ""#819""}]" changelog:id209,changelog,id209,0.10 (2017-11-14),"Fixed #83 - 500 error on individual row pages. Stop using sqlite WITH RECURSIVE in our tests. The version of Python 3 running in Travis CI doesn't support this.","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/83"", ""label"": ""#83""}]" changelog:id59,changelog,id59,Smaller changes,"Cascading view permissions - so if a user has view-table they can view the table page even if they do not have view-database or view-instance . ( #832 ) CSRF protection no longer applies to Authentication: Bearer token requests or requests without cookies. ( #835 ) datasette.add_message() now works inside plugins. ( #864 ) Workaround for ""Too many open files"" error in test runs. ( #846 ) Respect existing scope[""actor""] if already set by ASGI middleware. ( #854 ) New process for shipping Alpha and beta releases . ( #807 ) {{ csrftoken() }} now works when plugins render a template using datasette.render_template(..., request=request) . ( #863 ) Datasette now creates a single Request object and uses it throughout the lifetime of the current HTTP request. ( #870 )","[""Changelog"", ""0.45 (2020-07-01)""]","[{""href"": ""https://github.com/simonw/datasette/issues/832"", ""label"": ""#832""}, {""href"": ""https://github.com/simonw/datasette/issues/835"", ""label"": ""#835""}, {""href"": ""https://github.com/simonw/datasette/issues/864"", ""label"": ""#864""}, {""href"": ""https://github.com/simonw/datasette/issues/846"", ""label"": ""#846""}, {""href"": ""https://github.com/simonw/datasette/issues/854"", ""label"": ""#854""}, {""href"": ""https://github.com/simonw/datasette/issues/807"", ""label"": ""#807""}, {""href"": ""https://github.com/simonw/datasette/issues/863"", ""label"": ""#863""}, {""href"": ""https://github.com/simonw/datasette/issues/870"", ""label"": ""#870""}]" changelog:log-out,changelog,log-out,Log out,"The ds_actor cookie can be used by plugins (or by Datasette's --root mechanism ) to authenticate users. The new /-/logout page provides a way to clear that cookie. A ""Log out"" button now shows in the global navigation provided the user is authenticated using the ds_actor cookie. ( #840 )","[""Changelog"", ""0.45 (2020-07-01)""]","[{""href"": ""https://github.com/simonw/datasette/issues/840"", ""label"": ""#840""}]" changelog:magic-parameters-for-canned-queries,changelog,magic-parameters-for-canned-queries,Magic parameters for canned queries,"Canned queries now support Magic parameters , which can be used to insert or select automatically generated values. For example: insert into logs (user_id, timestamp) values (:_actor_id, :_now_datetime_utc) This inserts the currently authenticated actor ID and the current datetime. ( #842 )","[""Changelog"", ""0.45 (2020-07-01)""]","[{""href"": ""https://github.com/simonw/datasette/issues/842"", ""label"": ""#842""}]" changelog:id49,changelog,id49,0.50 (2020-10-09),"The key new feature in this release is the column actions menu on the table page ( #891 ). This can be used to sort a column in ascending or descending order, facet data by that column or filter the table to just rows that have a value for that column. Plugin authors can use the new datasette.client object to make internal HTTP requests from their plugins, allowing them to make use of Datasette's JSON API. ( #943 ) New Deploying Datasette documentation with guides for deploying Datasette on a Linux server using systemd or to hosting providers that support buildpacks . ( #514 , #997 ) Other improvements in this release: Publishing to Google Cloud Run documentation now covers Google Cloud SDK options. Thanks, Geoffrey Hing. ( #995 ) New datasette -o option which opens your browser as soon as Datasette starts up. ( #970 ) Datasette now sets sqlite3.enable_callback_tracebacks(True) so that errors in custom SQL functions will display tracebacks. ( #891 ) Fixed two rendering bugs with column headers in portrait mobile view. ( #978 , #980 ) New db.table_column_details(table) introspection method for retrieving full details of the columns in a specific table, see Database introspection . Fixed a routing bug with custom page wildcard templates. ( #996 ) datasette publish heroku now deploys using Python 3.8.6. New datasette publish heroku --tar= option. ( #969 ) OPTIONS requests against HTML pages no longer return a 500 error. ( #1001 ) Datasette now supports Python 3.9. See also Datasette 0.50: The annotated release notes .","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/891"", ""label"": ""#891""}, {""href"": ""https://github.com/simonw/datasette/issues/943"", ""label"": ""#943""}, {""href"": ""https://github.com/simonw/datasette/issues/514"", ""label"": ""#514""}, {""href"": ""https://github.com/simonw/datasette/issues/997"", ""label"": ""#997""}, {""href"": ""https://github.com/simonw/datasette/pull/995"", ""label"": ""#995""}, {""href"": ""https://github.com/simonw/datasette/issues/970"", ""label"": ""#970""}, {""href"": ""https://github.com/simonw/datasette/issues/891"", ""label"": ""#891""}, {""href"": ""https://github.com/simonw/datasette/issues/978"", ""label"": ""#978""}, {""href"": ""https://github.com/simonw/datasette/issues/980"", ""label"": ""#980""}, {""href"": ""https://github.com/simonw/datasette/issues/996"", ""label"": ""#996""}, {""href"": ""https://github.com/simonw/datasette/issues/969"", ""label"": ""#969""}, {""href"": ""https://github.com/simonw/datasette/issues/1001"", ""label"": ""#1001""}, {""href"": ""https://simonwillison.net/2020/Oct/9/datasette-0-50/"", ""label"": ""Datasette 0.50: The annotated release notes""}]" changelog:url-building,changelog,url-building,URL building,"The new datasette.urls family of methods can be used to generate URLs to key pages within the Datasette interface, both within custom templates and Datasette plugins. See Building URLs within plugins for more details. ( #904 )","[""Changelog"", ""0.51 (2020-10-31)""]","[{""href"": ""https://github.com/simonw/datasette/issues/904"", ""label"": ""#904""}]" changelog:id57,changelog,id57,0.46 (2020-08-09),"This release contains a security fix related to authenticated writable canned queries. If you are using this feature you should upgrade as soon as possible. Security fix: CSRF tokens were incorrectly included in read-only canned query forms, which could allow them to be leaked to a sophisticated attacker. See issue 918 for details. Datasette now supports GraphQL via the new datasette-graphql plugin - see GraphQL in Datasette with the new datasette-graphql plugin . Principle git branch has been renamed from master to main . ( #849 ) New debugging tool: /-/allow-debug tool ( demo here ) helps test allow blocks against actors, as described in Defining permissions with ""allow"" blocks . ( #908 ) New logo for the documentation, and a new project tagline: ""An open source multi-tool for exploring and publishing data"". Whitespace in column values is now respected on display, using white-space: pre-wrap . ( #896 ) New await request.post_body() method for accessing the raw POST body, see Request object . ( #897 ) Database file downloads now include a content-length HTTP header, enabling download progress bars. ( #905 ) File downloads now also correctly set the suggested file name using a content-disposition HTTP header. ( #909 ) tests are now excluded from the Datasette package properly - thanks, abeyerpath. ( #456 ) The Datasette package published to PyPI now includes sdist as well as bdist_wheel . Better titles for canned query pages. ( #887 ) Now only loads Python files from a directory passed using the --plugins-dir option - thanks, Amjith Ramanujam. ( #890 ) New documentation section on Publishing to Vercel .","[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/918"", ""label"": ""issue 918""}, {""href"": ""https://github.com/simonw/datasette-graphql"", ""label"": ""datasette-graphql""}, {""href"": ""https://simonwillison.net/2020/Aug/7/datasette-graphql/"", ""label"": ""GraphQL in Datasette with the new datasette-graphql plugin""}, {""href"": ""https://github.com/simonw/datasette/issues/849"", ""label"": ""#849""}, {""href"": ""https://latest.datasette.io/-/allow-debug"", ""label"": ""demo here""}, {""href"": ""https://github.com/simonw/datasette/issues/908"", ""label"": ""#908""}, {""href"": ""https://github.com/simonw/datasette/issues/896"", ""label"": ""#896""}, {""href"": ""https://github.com/simonw/datasette/issues/897"", ""label"": ""#897""}, {""href"": ""https://github.com/simonw/datasette/issues/905"", ""label"": ""#905""}, {""href"": ""https://github.com/simonw/datasette/issues/909"", ""label"": ""#909""}, {""href"": ""https://github.com/simonw/datasette/issues/456"", ""label"": ""#456""}, {""href"": ""https://github.com/simonw/datasette/issues/887"", ""label"": ""#887""}, {""href"": ""https://github.com/simonw/datasette/pull/890"", ""label"": ""#890""}]" changelog:id55,changelog,id55,0.47.1 (2020-08-11),Fixed a bug where the sdist distribution of Datasette was not correctly including the template files. ( #930 ),"[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/930"", ""label"": ""#930""}]" changelog:id53,changelog,id53,0.47.3 (2020-08-15),The datasette --get command-line mechanism now ensures any plugins using the startup() hook are correctly executed. ( #934 ),"[""Changelog""]","[{""href"": ""https://github.com/simonw/datasette/issues/934"", ""label"": ""#934""}]" changelog:id26,changelog,id26,0.59 (2021-10-14),"Columns can now have associated metadata descriptions in metadata.json , see Column descriptions . ( #942 ) New register_commands() plugin hook allows plugins to register additional Datasette CLI commands, e.g. datasette mycommand file.db . ( #1449 ) Adding ?_facet_size=max to a table page now shows the number of unique values in each facet. ( #1423 ) Upgraded dependency httpx 0.20 - the undocumented allow_redirects= parameter to datasette.client is now follow_redirects= , and defaults to False where it previously defaulted to True . ( #1488 ) The --cors option now causes Datasette to return the Access-Control-Allow-Headers: Authorization header, in addition to Access-Control-Allow-Origin: * . ( #1467 ) Code that figures out which named parameters a SQL query takes in order to display form fields for them is no longer confused by strings that contain colon characters. ( #1421 ) Renamed --help-config option to --help-settings . ( #1431 ) datasette.databases property is now a documented API. ( #1443 ) The base.html template now wraps everything other than the