Simon Willison
81b68a143a
/-/auth-token as root redirects to /, closes #2375
2024-07-26 14:09:20 -07:00
Alex Garcia
a23c2aee00
Introduce new /$DB/-/query endpoint, soft replaces /$DB?sql=... ( #2363 )
...
* Introduce new default /$DB/-/query endpoint
* Fix a lot of tests
* Update pyodide test to use query endpoint
* Link to /fixtures/-/query in a few places
* Documentation for QueryView
---------
Co-authored-by: Simon Willison <swillison@gmail.com>
2024-07-15 10:33:51 -07:00
Simon Willison
7316dd4ac6
Fix for TableNotFound, refs #2359
2024-06-21 16:09:20 -07:00
Simon Willison
62686114ee
Do not show database name in Database Not Found error, refs #2359
2024-06-21 16:02:15 -07:00
Simon Willison
93534fd3d0
Show response.text on test_upsert failure, refs #2356
2024-06-13 10:19:26 -07:00
Simon Willison
45c27603d2
xfail two flaky tests, #2355 , #2356
2024-06-13 10:15:38 -07:00
Alex Garcia
8f86d2af6a
Test against multiple SQLite versions ( #2352 )
...
* Use sqlite-versions action for testing multiple versions
2024-06-13 10:09:45 -07:00
Simon Willison
d118d5c5bb
named_parameters(sql) sync function, refs #2354
...
Also refs #2353 and #2352
2024-06-12 16:51:07 -07:00
Simon Willison
7437d40e5d
<html lang="en">, closes #2348
2024-06-11 10:17:02 -07:00
Alex Garcia
e1bfab3fca
Move Metadata to --internal database
...
Refs:
- https://github.com/simonw/datasette/pull/2343
- https://github.com/simonw/datasette/issues/2341
2024-06-11 09:33:23 -07:00
Agustin Bacigalup
67e66f36c1
Add ETag header for static responses ( #2306 )
...
* add etag to static responses
* fix RuntimeError related to static headers
* Remove unnecessary import
---------
Co-authored-by: Simon Willison <swillison@gmail.com>
2024-03-17 12:18:40 -07:00
Simon Willison
feddd61789
Fix tests I broke in #2302
2024-03-12 17:01:51 -07:00
Simon Willison
b8711988b9
row_actions() plugin hook, closes #2299
2024-03-12 16:16:05 -07:00
Simon Willison
06281a0b8e
Test for labels on Table/View action buttons, refs #2297
2024-03-12 14:32:48 -07:00
Simon Willison
909c85cd2b
view_actions plugin hook, closes #2297
2024-03-12 14:25:28 -07:00
Simon Willison
daf5ca02ca
homepage_actions() plugin hook, closes #2298
2024-03-12 13:46:06 -07:00
Simon Willison
7818e8b9d1
Hide tables starting with an _, refs #2104
2024-03-07 00:03:42 -05:00
Simon Willison
090dff542b
Action menu descriptions
...
* Refactor tests to extract get_actions_links() helper
* Table, database and query action menu items now support optional descriptions
Closes #2294
2024-03-06 22:54:06 -05:00
Simon Willison
4d24bf6b34
Don't explain an explain even in the demo, refs #2293
2024-03-05 18:14:55 -08:00
Simon Willison
5de6797d4a
Better demo plugin for query_actions, refs #2293
2024-03-05 18:06:38 -08:00
Simon Willison
6ec0081f5d
query_actions plugin hook
...
* New query_actions plugin hook, closes #2283
2024-02-27 21:55:16 -08:00
Simon Willison
f99c2f5f8c
?column_notcontains= table filter, closes #2287
2024-02-27 16:07:41 -08:00
Jeroen Van Goey
103b4decbd
fix (typo): Corrected spelling of 'environments' ( #2268 )
...
* fix (typo): Corrected spelling of 'environments'
* ci: add test folder to codespell workflow
2024-02-19 14:41:32 -08:00
Simon Willison
28bf3a933f
Applied Black, refs #2278
2024-02-19 14:22:59 -08:00
Simon Willison
26300738e3
Fixes for permissions debug page, closes #2278
2024-02-19 14:17:37 -08:00
Simon Willison
b36a2d8f4b
Require update-row to use insert replace, closes #2279
2024-02-19 12:55:51 -08:00
Simon Willison
3856a8cb24
Consistent Permission denied:, refs #2279
2024-02-19 12:51:14 -08:00
Simon Willison
10f9ba1a00
Take advantage of execute_write_fn(transaction=True)
...
A bunch of places no longer need to do manual transaction handling
thanks to this change. Refs #2277
2024-02-17 20:51:19 -08:00
Simon Willison
5e0e440f2c
database.execute_write_fn(transaction=True) parameter, closes #2277
2024-02-17 20:28:15 -08:00
Simon Willison
3a999a85fb
Fire insert-rows on /db/-/create if rows were inserted, refs #2260
2024-02-16 13:59:56 -08:00
Simon Willison
244f3ff83a
Test demonstrating fix for permisisons bug in #2262
2024-02-16 13:39:57 -08:00
Simon Willison
398a92cf1e
Include database in name of _execute_writes thread, closes #2265
2024-02-08 20:12:31 -08:00
Simon Willison
c62cfa6de8
Fix upsert test to detect new alter-table event
2024-02-08 13:36:17 -08:00
Simon Willison
c954795f9a
alter: true for row/-/update, refs #2101
2024-02-08 13:36:17 -08:00
Simon Willison
4e944c29e4
Corrected path used in test_update_row_check_permission
2024-02-08 13:36:17 -08:00
Simon Willison
528d89d1a3
alter: true support for /-/insert and /-/upsert, refs #2101
2024-02-08 13:36:17 -08:00
Simon Willison
b5ccc4d608
Test for Permission denied - need alter-table
2024-02-08 13:36:17 -08:00
Simon Willison
900d15bcb8
alter table support for /db/-/create API, refs #2101
2024-02-08 13:36:17 -08:00
Simon Willison
9ac9f0152f
Migrate allow from metadata to config if necessary, closes #2249
2024-02-06 22:18:38 -08:00
Simon Willison
60c6692f68
table_config instead of table_metadata ( #2257 )
...
Table configuration that was incorrectly placed in metadata is now treated as if it was in config.
New await datasette.table_config() method.
Closes #2247
2024-02-06 21:57:09 -08:00
Simon Willison
52a1dac5d2
Test proving $env works for datasette.yml, closes #2255
2024-02-06 21:00:55 -08:00
Simon Willison
69c6e95323
Fixed a bunch of unused imports spotted with ruff
2024-02-06 17:27:20 -08:00
Simon Willison
5a63ecc557
Rename metadata= to table_config= in facet code, refs #2247
2024-02-06 15:03:19 -08:00
Simon Willison
1e901aa690
/-/config page, closes #2254
2024-02-06 12:33:46 -08:00
Simon Willison
be4f02335f
Treat plugins in metadata as if they were in config, closes #2248
2024-02-01 15:33:33 -08:00
Simon Willison
d4bc2b2dfc
Remove fail_if_plugins_in_metadata, part of #2248
2024-02-01 14:44:16 -08:00
Simon Willison
bcc4f6bf1f
track_event() mechanism for analytics and plugins
...
* Closes #2240
* Documentation for event plugin hooks, refs #2240
* Include example track_event plugin in docs, refs #2240
* Tests for track_event() and register_events() hooks, refs #2240
* Initial documentation for core events, refs #2240
* Internals documentation for datasette.track_event()
2024-01-31 15:21:40 -08:00
Simon Willison
5c64af6936
Upgrade to latest Black, closes #2239
2024-01-30 19:55:26 -08:00
Simon Willison
c3caf36af7
Template slot family of plugin hooks - top_homepage() and others
...
New plugin hooks:
top_homepage
top_database
top_table
top_row
top_query
top_canned_query
New datasette.utils.make_slot_function()
Closes #1191
2024-01-30 19:54:03 -08:00
Simon Willison
7a5adb592a
Docs on temporary plugins in fixtures, closes #2234
2024-01-12 14:12:14 -08:00