Simon Willison
77e718c3ff
Revert "Fix bug with percentage redirects, close #1650"
...
This reverts commit c85d669de3
.
Refs #1658
2022-03-15 08:37:31 -07:00
Simon Willison
5a353a32b9
Revert "Fixed tests for urlsafe_components, refs #1650"
...
This reverts commit bb499942c1
.
Refs #1658
2022-03-15 08:37:14 -07:00
Simon Willison
bb499942c1
Fixed tests for urlsafe_components, refs #1650
2022-03-07 11:33:31 -08:00
Simon Willison
c85d669de3
Fix bug with percentage redirects, close #1650
2022-03-07 11:26:08 -08:00
Simon Willison
020effe47b
Preserve query string in % to - redirects, refs #1650
2022-03-07 08:18:07 -08:00
Simon Willison
644d25d1de
Redirect old % URLs to new - encoded URLs, closes #1650
...
Refs #1439
2022-03-07 08:01:42 -08:00
Simon Willison
1baa030eca
Switch to dash encoding for table/database/row-pk in paths
...
* Dash encoding functions, tests and docs, refs #1439
* dash encoding is now like percent encoding but with dashes
* Use dash-encoding for row PKs and ?_next=, refs #1439
* Use dash encoding for table names, refs #1439
* Use dash encoding for database names, too, refs #1439
See also https://simonwillison.net/2022/Mar/5/dash-encoding/
2022-03-07 07:38:29 -08:00
Simon Willison
5010d1359b
Fix for test failure caused by SQLite 3.37.0+, closes #1647
2022-03-05 11:46:59 -08:00
Simon Willison
458f03ad3a
More SpatiaLite details on /-/versions, closes #1607
2022-02-08 22:32:19 -08:00
Simon Willison
0cd982fc6a
De-duplicate 'datasette db.db db.db', closes #1632
...
Refs https://github.com/simonw/datasette-publish-fly/pull/12
2022-02-07 15:28:59 -08:00
Simon Willison
d9b508ffaa
@documented decorator plus unit test plus sphinx.ext.autodoc
...
New mechanism for marking datasette.utils functions that should be covered by the
documentation, then testing that they have indeed been documented.
Also enabled sphinx.ext.autodoc which can now be used to embed the documented
versions of those functions.
Refs #1176
2022-02-06 22:31:06 -08: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
ac239d34ab
Refactor test_trace into separate test module, refs #1576
2022-02-04 20:45:13 -08:00
Simon Willison
23a09b0f6a
Remove JSON rel=alternate from some pages, closes #1623
2022-02-02 13:48:52 -08:00
Simon Willison
8d5779acf0
Refactored alternate_url_json mechanism, refs #1620 , #1533
2022-02-02 13:32:47 -08:00
Simon Willison
b72b2423c7
rel=alternate JSON for queries and database pages, closes #1620
2022-02-02 13:22:45 -08:00
Simon Willison
3ef47a0896
Link rel=alternate header for tables and rows
...
Also added Access-Control-Expose-Headers: Link to --cors mode.
Closes #1533
Refs https://github.com/simonw/datasette-notebook/issues/2
LL# metadata.json.1
2022-02-01 23:49:09 -08:00
Simon Willison
68cc1e2dbb
Move queries to top of database page, refs #1612
2022-01-25 10:28:15 -08:00
Simon Willison
7c67483f5e
Make test_favicon flexible to changing icon sizes, refs #1603
2022-01-19 21:57:14 -08:00
Simon Willison
0467723ee5
New, improved favicon - refs #1603
2022-01-19 21:46:03 -08:00
Simon Willison
e1770766ce
Return plugins and hooks in predictable order
2022-01-19 21:14:04 -08:00
Simon Willison
58652dd925
Hidden tables sqlite1/2/3/4, closes #1587
2022-01-19 20:12:46 -08:00
Simon Willison
3664ddd400
Replace update-docs-help.py with cog, closes #1598
2022-01-13 16:47:53 -08:00
Simon Willison
ab7d6a7179
Updated settings help URL to avoid redirect
2022-01-13 16:38:16 -08:00
Simon Willison
3a0f7d6488
Fixed hidden form fields bug #1527
2022-01-13 16:27:21 -08:00
Simon Willison
3658e57ac2
Fixed bug with table title element, closes #1560
2022-01-13 14:20:07 -08:00
Simon Willison
63537dd3de
Allow 'explain query plan' with more whitespace, closes #1588
2022-01-13 12:34:55 -08:00
Simon Willison
8c401ee0f0
Fixed remaining code and docs for new block=True default, closes #1579
2021-12-23 11:18:20 -08:00
Simon Willison
00a2895cd2
execute_write defaut is now block=True, closes #1579
2021-12-23 11:03:49 -08:00
Simon Willison
4094741c28
Fixed bug with custom templates for writable canned queries, closes #1547
2021-12-19 13:11:57 -08:00
Simon Willison
5fac26aa22
Another populate_schema_tables optimization, refs #1555
2021-12-19 12:54:12 -08:00
Simon Willison
f65817000f
Include count in execute_write_many traces, closes #1571
2021-12-19 12:30:34 -08:00
Simon Willison
d637ed4676
Use execute_write_many to optimize internal DB, refs #1555 , #1570
2021-12-18 11:11:08 -08:00
Simon Willison
5cadc24489
db.execute_write_script() and db.execute_write_many(), closes #1570
...
Refs #1555
2021-12-18 10:57:22 -08:00
Simon Willison
2e4ba71b53
Optimize create table calls using executescript=True
...
Refs #1555 , #1569
2021-12-18 10:34:15 -08:00
Simon Willison
9e094b7c9d
db.execute_write(executescript=True) option, closes #1569
2021-12-18 10:34:15 -08:00
Simon Willison
f81d9d0cd9
Trace write SQL queries in addition to read ones, closes #1568
2021-12-17 18:42:29 -08:00
Simon Willison
7c8f8aa209
Documentation for Datasette() constructor, closes #1563
2021-12-17 18:19:36 -08:00
Simon Willison
3a0cae4d7f
Fix bug introduced by refactor in c35b84a2aa
2021-12-17 18:19:09 -08:00
Simon Willison
359140ceda
Datasette() constructor no longer requires files=, closes #1563
2021-12-17 18:09:00 -08:00
Simon Willison
83bacfa945
Call _prepare_connection() on write connections, closes #1564
2021-12-17 17:58:39 -08:00
Simon Willison
c35b84a2aa
Remove undocumented sqlite_functions mechanism, closes #1567
2021-12-17 17:54:39 -08:00
Simon Willison
aa7f0037a4
filters_from_request plugin hook, now used in TableView
...
- New `filters_from_request` plugin hook, closes #473
- Used it to extract the logic from TableView that handles `_search` and
`_through` and `_where` - refs #1518
Also needed for this plugin work: https://github.com/simonw/datasette-leaflet-freedraw/issues/7
2021-12-17 11:02:14 -08:00
Simon Willison
0d4145d0f4
Additional test for #625
2021-12-16 12:30:31 -08:00
Simon Willison
95d0dd7a1c
Fix for colliding facet types bug, closes #625
...
Refs #830
2021-12-16 12:12:04 -08:00
Simon Willison
992496f261
?_nosuggest=1 parameter for table views, closes #1557
2021-12-16 11:24:54 -08:00
Simon Willison
20a2ed6bec
Fixed bug with metadata config of array/date facets, closes #1552
...
Thanks @davidbgk for spotting the fix for the bug.
2021-12-16 10:47:40 -08:00
Simon Willison
eb53837d2a
Always show count of distinct facet values, closes #1556
...
Refs #1423
2021-12-15 09:58:01 -08:00
Simon Willison
4f02c8d4d7
Test for JSON in query_string name, refs #621
...
Plus simplified implementation of test_request_blank_values
2021-12-14 12:29:05 -08:00