

Recent
The ILIKE Trap: 40ms of Planning for 3ms of Work
·6 mins
ILIKE on a trigram-indexed column was spending ~40ms in the query planner for every ~3ms of execution. The fix was two lines of SQL and one line of Python — but finding it required understanding what the planner actually does with ILIKE.
Mana Symbol Rendering: Regex + Map for 47× Speedup
·5 mins
Replacing a per-symbol replaceAll loop with a single regex pass and a Map lookup cut mana symbol conversion time by 47×. The mechanism, the benchmark, and a gotcha with stateful regex.
Why Mana Symbols Are a Custom Webfont, Not SVG Sprites
Rendering Magic’s mana symbols as a custom webfont: why a font beats SVG sprites or images, how subsetting drops a 200–300 KB file to under 40 KB, and the tradeoffs around font loading that the obvious approach misses.
Scryfall Sorts Alphabetically. I Sort by CubeCobra Popularity.
Search results need two distinct scoring concerns: which printing of a card to surface, and which cards to rank first. Both are numeric ORDER BY expressions baked into the card rows.
Autocomplete Without a Round-Trip: Suggestions from a Frozen In-Memory Type List
·7 mins
When you type t:cre, the search box completes it to t:Creature before any network request leaves your browser. The type list lives in a frozen in-memory index, populated once at page load from the Rust engine.