Commit graph

48 commits

Author SHA1 Message Date
Simon Willison
eadb314ee4
Update cache-dependency-path to pyproject.toml 2026-02-11 17:31:08 -08:00
Simon Willison
13ae71e08e
Update Python versions and actions in workflow 2026-02-11 17:30:30 -08:00
Claude
02dd3ae9ca
Update documentation for new commands and output formats
- Update README.md with new commands summary and uv development workflow
- Add docs/exploring.md covering databases, tables, schema, rows, get
  commands with filtering, sorting, pagination, and output format examples
- Add docs/writing.md covering create-table, upsert, update, delete, drop
- Update docs/queries.md with output format options (--csv, --tsv, --nl, --table)
- Update docs/inserting.md with cross-references to upsert/update
- Update docs/index.md toctree to include new pages
- Regenerate all cog --help blocks with current command signatures

https://claude.ai/code/session_01DoiJf9Gbvbw2asN9yvP6dx
2026-02-12 01:28:52 +00:00
Simon Willison
364c344d8d
Update Python versions and workflow actions in test.yml 2026-02-11 17:27:53 -08:00
Claude
278c3b67e2
Add follow_redirects to API GET requests and showboat demo
- Fix _api_get to follow redirects (needed for query endpoint on
  newer Datasette which redirects /{db}.json?sql= to /{db}/-/query)
- Add demo.md showing all new commands against a live Datasette instance:
  create-table, insert, databases, tables, schema, rows (with filtering,
  sorting, column selection, CSV export), get, query, update, upsert,
  delete, drop

https://claude.ai/code/session_01DoiJf9Gbvbw2asN9yvP6dx
2026-02-12 00:32:58 +00:00
Claude
5ee8b2d93c
Implement T1 and T2: exploration, CRUD commands, and output formats
Refactored shared infrastructure:
- _resolve_url(), _resolve_token(), _api_get(), _api_post() helpers
- Shared output formatters: JSON, CSV, TSV, NL-JSON, text table
- DCLIENT_TOKEN and DCLIENT_URL environment variable support

T1 - Core table browsing:
- `databases` - list databases on a Datasette instance
- `tables` - list tables with optional --schema flag
- `schema` - show CREATE TABLE SQL for database/table
- `rows` - browse rows with filtering (-w), sorting, pagination,
  column selection, faceting, full-text search, --limit, --all
- `get` - fetch a single row by primary key

T2 - Write operations:
- `upsert` - insert-or-update rows from file (CSV/TSV/JSON/JSONL)
- `update` - update a single row by PK with key=value pairs
- `delete` - delete a row by PK (with --yes to skip confirmation)
- `drop` - drop a table (shows row count, requires confirmation)
- `create-table` - create empty table with --column name type --pk

Output formats added to query and rows:
- --csv, --tsv, --nl, --json, --table flags

23 new tests covering all commands (62 total, all passing).

https://claude.ai/code/session_01DoiJf9Gbvbw2asN9yvP6dx
2026-02-12 00:22:12 +00:00
Claude
9715510431
Migrate from setup.py to pyproject.toml for uv compatibility
- Replace setup.py with pyproject.toml using uv_build backend
- Add dependency-groups.dev for test dependencies
- Configure flat layout with module-root = ""
- Fix pre-existing test failures (updated error message, optional mock)
- Add uv.lock and dist/ to .gitignore
- uv run pytest (39 passed) and uv build both work

https://claude.ai/code/session_01DoiJf9Gbvbw2asN9yvP6dx
2026-02-12 00:16:43 +00:00
Claude
2a8836b272
Add comprehensive improvement plan comparing dclient to Datasette features
Detailed feature gap analysis and tiered implementation plan covering:
- Core table browsing and schema exploration (databases, tables, schema, rows, get)
- Write operations (upsert, update, delete, drop, create-table)
- Output format improvements (CSV, TSV, table, NL-JSON)
- Authentication UX (browser login, env vars, keyring, auth status)
- Discoverability features (info, URL inference, shell completions)

https://claude.ai/code/session_01DoiJf9Gbvbw2asN9yvP6dx
2026-02-12 00:09:00 +00:00
Simon Willison
1a0fe65015 Upgrade Actions for publish of 0.4 0.4 2024-03-08 11:09:54 -05:00
Simon Willison
0d4ab72b68 Release 0.4
Refs #23, #25, #26
2024-02-27 21:09:26 -08:00
Simon Willison
ea3dc64fb9 dclient actor command, closes #26 2024-02-27 21:08:15 -08:00
Simon Willison
20851f6ed6 -v/--verbose option, closes #25 2024-02-27 20:52:15 -08:00
Simon Willison
adfa6cce14 insert --alter support, closes #23 2024-02-27 20:49:54 -08:00
Simon Willison
0e40a80c84 Deploy future packages with PyPI trusted actions 2024-02-25 11:38:22 -08:00
Simon Willison
5303067da3 Release 0.3 0.3
Refs #8, #16, #18, #19, #21, #22
2024-02-25 11:36:27 -08:00
Simon Willison
081aeb32a2 Example usage in --help, closes #22 2024-02-25 11:24:46 -08:00
Simon Willison
f0058258b2 cog --check as part of CI 2024-02-25 11:13:35 -08:00
Simon Willison
8c82f9a572 Rename 'datasette client' to 'datasette dt', closes #18
Refs https://github.com/simonw/datasette/issues/2153#issuecomment-1691763427
2024-02-25 11:10:53 -08:00
Simon Willison
44d7e2bf9e Docs for streaming and --interval, closes #21 2024-02-25 11:08:02 -08:00
Simon Willison
5a0a81b8da
Create .readthedocs.yaml 2024-02-24 17:44:06 -08:00
Simon Willison
37423fe772 Drop Python 3.7, add 3.12 2024-02-23 20:08:30 -08:00
Simon Willison
43b6850780 --interval option, refs #19 2024-02-23 20:08:30 -08:00
Simon Willison
59129824e3 Update for Datasette 1.0 alphas to pass tests 2024-02-23 19:56:56 -08:00
Simon Willison
66a3cdd3be Remove query -t shortcut - so I can use it for table later, refs #16 2023-07-24 21:52:53 -07:00
Simon Willison
a17b7f6e7d Add dclient insert --help to insert docs, refs #8 2023-07-24 21:35:50 -07:00
Simon Willison
ce62592540
Demonstrate aliases directly in the README 2023-07-24 21:33:46 -07:00
Simon Willison
829f27b8d1
Release 0.2 0.2
Refs #8, #13
2023-07-24 16:24:05 -07:00
Simon Willison
6b7297205f
Much of the functionality requires Datasette 1.0a2 or higher 2023-07-24 16:23:30 -07:00
Simon Willison
c847badc4e
dclient insert command (#13)
* Move making queries to own page, refs #7
* Documentation for the dclient insert feature, refs #8
* Implemented progress bar for insert, refs #8
* --pk option
* --ignore and --replace for insert, refs #8
* --batch-size option, refs #8
* First insert test, using a mock - refs #8
* insert test that exercises against an in-memory Datasette instance, refs #8
* Insert tests now cover an error case, refs #8
* Tests for --ignore and --replace, refs #8
* Tests for different formats, refs #8
* Test for --no-detect-types
* Support for --encoding, refs #8
2023-07-24 16:22:39 -07:00
Simon Willison
41916a7be0 Move making queries to own page, refs #7 2023-07-18 19:25:22 -07:00
Simon Willison
20f0e18a80 Ran Black 2023-07-17 16:50:43 -07:00
Simon Willison
823413a9a7
Documentation on ReadTheDocs using MyST
Refs #7
2023-07-17 16:48:50 -07:00
Simon Willison
8a205d81a3
dclient auth commands
Closes #3
2023-07-17 16:23:53 -07:00
Simon Willison
055d6a6ffc Swap appdirs for click.get_app_dir(), change dir from dclient to io.datasette.dclient - closes #10 2023-07-17 15:00:46 -07:00
Simon Willison
c0d25a7512 Fixed failing test 2023-07-17 14:59:34 -07:00
Simon Willison
d59c680ffd
cache-dependency-path: setup.py 2022-11-21 23:00:33 -08:00
Simon Willison
ca301dcbe3
cache-dependency-path: setup.py 2022-11-21 22:59:12 -08:00
Simon Willison
aea4d3fd50 Test on Python 3.11, upgrade workflows 2022-11-21 22:35:34 -08:00
Simon Willison
2c9af739c2 Test for datasette plugin registration, refs #4 2022-11-21 22:31:48 -08:00
Simon Willison
bf6c709804
Release 0.1a2 0.1a2
Refs #4
2022-11-21 21:38:39 -08:00
Simon Willison
c30bd7e9bf
Docs for "datasette client" plugin mode
Refs #4
2022-11-21 21:38:14 -08:00
Simon Willison
02cf4c0cf2 Register as a Datasette plugin too, refs #4 2022-11-21 21:33:24 -08:00
Simon Willison
d71919fe24
Release 0.1a1 0.1a1
Refs #2
2022-11-21 19:01:15 -08:00
Simon Willison
ff3b64f425 alias remove command, alias list --json option - refs #2 2022-11-21 19:00:20 -08:00
Simon Willison
6bc35f46c2 dclient aliases command, closes #2 2022-11-21 18:53:12 -08:00
Simon Willison
1ecb6a02e8 Initial dclient query command, refs #1 0.1a0 2022-11-21 18:16:28 -08:00
simonw
56c4672f37 Initial library structure 2022-11-22 01:57:06 +00:00
Simon Willison
ac7aaab22d
Initial commit 2022-11-21 17:56:46 -08:00