Simon Willison’s Weblog

Newsletter
Atom feed

Elsewhere

Filters: Sorted by date

Release datasette 0.60a1 — An open source multi-tool for exploring and publishing data
Release datasette-pretty-traces 0.3.1 — Prettier formatting for ?_trace=1 traces
Release datasette-pretty-traces 0.3 — Prettier formatting for ?_trace=1 traces
None
TIL Safely outputting JSON — Carelessly including the output of `json.dumps()` in an HTML page can lead to an XSS hole, thanks to the following:
None
TIL Creating a minimal SpatiaLite database with Python — When writing a test for [datasette-leaflet-freedraw](https://github.com/simonw/datasette-leaflet-freedraw) I realized I didn't have a simple tiny recipe for creating an in-memory SpatiaLite database in Python. I came up with this:
Release datasette 0.60a0 — An open source multi-tool for exploring and publishing data
None
TIL Registering the same Pluggy hook multiple times in a single file — I found myself wanting to register more than one instance of a [Pluggy](https://pluggy.readthedocs.io/) plugin hook inside a single module.
Release datasette-pretty-traces 0.2.1 — Prettier formatting for ?_trace=1 traces
Release datasette-pretty-traces 0.2 — Prettier formatting for ?_trace=1 traces
Release datasette-pretty-traces 0.1 — Prettier formatting for ?_trace=1 traces
None
TIL Using lsof on macOS — `lsof` stands for "list open files". Here are some very basic usage notes for the version that ships with macOS.
None
TIL Using C_INCLUDE_PATH to install Python packages — I tried to install my [datasette-bplist](https://github.com/simonw/datasette-bplist) plugin today in a fresh Python 3.10 virtual environment on macOS and got this error:
Release git-history 0.6.1 — Tools for analyzing Git history using SQLite
None
TIL Storing files in an S3 bucket between GitHub Actions runs — For my [git-history live demos](https://github.com/simonw/git-history/issues/30) I needed to store quite large files (~200MB SQLite databases) in between GitHub Actions runs, to avoid having to recreate the entire file from scratch every time.
Release datasette-cluster-map 0.17.2 — Datasette plugin that shows a map for any data with latitude/longitude columns
Release git-history 0.6 — Tools for analyzing Git history using SQLite
Release s3-credentials 0.8 — A tool for creating credentials for accessing S3 buckets
None
TIL __init_subclass__ — David Beazley [on Twitter](https://twitter.com/dabeaz/status/1466731368956809219) said:
Release asyncinject 0.2a1 — Run async workflows using pytest-fixtures-style dependency injection
Release git-history 0.5 — Tools for analyzing Git history using SQLite
Release datasette-hovercards 0.1a0 — Add preview hovercards to links in Datasette
Release github-to-sqlite 2.8.3 — Save data from GitHub to a SQLite database
None
TIL Ignoring a line in both flake8 and mypy — I [needed to tell](https://github.com/simonw/sqlite-utils/pull/347#issuecomment-982133970) both `flake8` and `mypy` to ignore the same line of code.
Release s3-credentials 0.7 — A tool for creating credentials for accessing S3 buckets
Release datasette 0.59.4 — An open source multi-tool for exploring and publishing data
None
TIL Reusing an existing Click tool with register_commands — The [register_commands](https://docs.datasette.io/en/stable/plugin_hooks.html#register-commands-cli) plugin hook lets you add extra sub-commands to the `datasette` CLI tool.
None
TIL Publishing a Web Component to npm — I tried this for the first time today with my highly experimental [datasette-table](https://www.npmjs.com/package/datasette-table) Web Component. Here's [the source code](https://github.com/simonw/datasette-table/tree/0.1.0) for version 0.1.0.
Release datasette-table 0.1.0 — A Web Component for embedding a Datasette table on a page
None
TIL Pausing traffic and retrying in Caddy — A pattern I really like for zero-downtime deploys is the ability to "pause" HTTP traffic at the load balancer, such that incoming requests from browsers appear to take a few extra seconds to return, but under the hood they've actually been held in a queue while a backend server is swapped out or upgraded in some way.
Release datasette-publish-vercel 0.12 — Datasette plugin for publishing data using Vercel