Simon Willison
b8711988b9
row_actions() plugin hook, closes #2299
2024-03-12 16:16:05 -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
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
5c64af6936
Upgrade to latest Black, closes #2239
2024-01-30 19:55:26 -08:00
Alex Garcia
92b8bf38c0
Add new `--internal internal.db` option, deprecate legacy `_internal` database
...
Refs:
- #2157
---------
Co-authored-by: Simon Willison <swillison@gmail.com>
2023-08-28 20:24:23 -07:00
Simon Willison
0b4a286914
render_cell(..., request) argument, closes #2007
2023-01-27 19:34:14 -08:00
Simon Willison
d94d363ec0
Don't use pytest_asyncio.fixture(scope="session") any more, refs #1959
...
Also got rid of the weird memory=False hack:
https://github.com/simonw/datasette/pull/1960#issuecomment-1354053151
2022-12-17 13:47:55 -08:00
Simon Willison
425ac4357f
Ported app_client to ds_client where possible in test_auth.py, refs #1959
2022-12-17 13:47:55 -08:00
Simon Willison
45979eb723
Rename permission created by demo plugin
...
It was showing up as 'new-permission' on https://latest.datasette.io/-/permissions
which I thought was confusing
2022-12-12 21:21:01 -08:00
Simon Willison
8bf06a76b5
register_permissions() plugin hook ( #1940 )
...
* Docs for permissions: in metadata, refs #1636
* Refactor default_permissions.py to help with implementation of #1636
* register_permissions() plugin hook, closes #1939 - also refs #1938
* Tests for register_permissions() hook, refs #1939
* Documentation for datasette.permissions, refs #1939
* permission_allowed() falls back on Permission.default, refs #1939
* Raise StartupError on duplicate permissions
* Allow dupe permisisons if exact matches
2022-12-12 18:05:54 -08:00
Simon Willison
d7e5e3c9f9
Fix for todomvc permission check
...
Refs https://github.com/simonw/todomvc-datasette/issues/2
2022-12-01 17:38:23 -08:00
Simon Willison
27efa8c381
todomvc permissions and fixed DATASETTE_SECRET for new demo
...
Refs https://github.com/simonw/todomvc-datasette/issues/2
2022-12-01 17:29:44 -08:00
Simon Willison
f3c8da7acd
MAke the sign in as root button bigger on latest.datasette.io
2022-12-01 13:29:31 -08:00
Simon Willison
ddc999ad12
Async support for prepare_jinja2_environment, closes #1809
2022-09-16 20:38:24 -07:00
Simon Willison
b40872f5e5
prepare_jinja2_environment(datasette) argument, refs #1809
2022-09-14 14:31:54 -07:00
Simon Willison
c09c53f345
New handle_exception plugin hook, refs #1770
...
Also refs:
- https://github.com/simonw/datasette-sentry/issues/1
- https://github.com/simonw/datasette-show-errors/issues/2
2022-07-17 16:24:39 -07:00
Simon Willison
6373bb3414
Expose current SQLite row to render_cell hook, closes #1300
2022-07-07 09:30:49 -07:00
Simon Willison
8a25ea9bca
Implemented import shortcuts, closes #957
2022-02-05 22:34:33 -08:00
Simon Willison
da53e0360d
tracer.trace_child_tasks() for asyncio.gather tracing
...
Also added documentation for datasette.tracer module.
Closes #1576
2022-02-04 21:19:49 -08:00
Simon Willison
c35b84a2aa
Remove undocumented sqlite_functions mechanism, closes #1567
2021-12-17 17:54:39 -08:00
Simon Willison
6e971b4ac1
Test confirming plugins can over-ride default routes, closes #1517
2021-11-18 19:07:21 -08:00
Simon Willison
3bb6409a6c
render_cell() can now return an awaitable, refs
2021-08-08 16:05:00 -07:00
Simon Willison
a679d0de87
Fixed spelling of 'receive' in a bunch of places
2021-08-03 09:11:18 -07:00
Simon Willison
eccfeb0871
register_routes() plugin hook datasette argument, closes #1404
2021-07-26 16:16:46 -07:00
Simon Willison
b1fd24ac9f
skip_csrf(datasette, scope) plugin hook, refs #1377
2021-06-23 15:40:09 -07:00
Simon Willison
d23a267138
Make request available to menu plugin hooks, closes #1371
2021-06-09 21:45:24 -07:00
Simon Willison
2bd9d54b27
Fix Jinja warnings, closes #1338 , refs #1331
2021-05-23 18:41:50 -07:00
Simon Willison
d579fcf4f7
Applied some fixes suggested by @withshubh in #1260
2021-03-28 17:20:55 -07:00
Simon Willison
c38c42948c
extra_body_script module support, closes #1187
2021-01-13 18:14:33 -08:00
Simon Willison
fa0c3777b8
script type=module support, closes #1186
2021-01-13 17:50:52 -08:00
Miroslav Šedivý
a882d67962
Modernize code to Python 3.6+ ( #1158 )
...
* Compact dict and set building
* Remove redundant parentheses
* Simplify chained conditions
* Change method name to lowercase
* Use triple double quotes for docstrings
Thanks, @eumiro!
2020-12-23 09:04:32 -08:00
Simon Willison
30e64c8d3b
Use f-strings in place of .format()
...
Code transformed like so:
pip install flynt
flynt .
black .
2020-11-15 15:24:22 -08:00
Simon Willison
7b19492070
database_actions() plugin hook, closes #1077
2020-11-02 10:27:25 -08:00
Simon Willison
bf18b9ba17
Stop using plugin-example.com, closes #1074
2020-10-31 12:47:42 -07:00
Simon Willison
84bc7244c1
datasette.client now applies base_url, closes #1026
2020-10-31 12:29:42 -07:00
Simon Willison
d6db47f5c1
Deploy demo plugins to latest.datasette.io, refs #1074
2020-10-31 10:36:46 -07:00
Simon Willison
f0a740ac21
Remove load_plugin hook - closes #1073
...
Refs #1042
This reverts commit 81dea4b07a
.
2020-10-31 09:21:22 -07:00
Simon Willison
81dea4b07a
load_template() plugin hook
...
Closes #1042
2020-10-30 10:47:18 -07:00
Simon Willison
2f7731e9e5
table_actions() plugin hook plus menu, closes #1066
...
Refs #690
2020-10-29 22:16:41 -07:00
Simon Willison
18a64fbb29
Navigation menu plus menu_links() hook
...
Closes #1064 , refs #690 .
2020-10-29 20:45:15 -07:00
Simon Willison
7d9fedc176
Cascading permissions for .db download, closes #1058
2020-10-27 20:15:41 -07:00
Simon Willison
a648bb82ba
Upgrade to Black 20.8b1, closes #958
2020-09-02 15:24:55 -07:00
Simon Willison
799ecae948
register_output_renderer can now return Response, closes #953
2020-08-27 21:02:50 -07:00
Simon Willison
3a4c8ed36a
Added columns argument to various extra_ plugin hooks, closes #938
2020-08-16 11:09:53 -07:00
Simon Willison
e3639247cd
Standard arguments for extra_ plugin hooks, closes #939
2020-08-16 09:50:23 -07:00
Simon Willison
549b1c2063
New forbidden() plugin hook, closes #812
2020-06-30 21:17:38 -07:00