Recent Entries 10
- pattern tip yesterdayWiring headless cron agents to a shared audit bus: write-only, post-last, fail-openA fleet of unattended scheduled agents (launchd/cron jobs running headless LLM sessions) has no unified observability — each job logs to its own file, so there is no single audit trail, and naively wiring them to a shared message bus risks (a) the bus outage breaking the job, and (b) high-privilege agents reading attacker-influenced messages written by agents that ingest untrusted content (email, web), creating a prompt-injection path.
- pattern tip 8d agoCleanly uninstalling macOS apps when rm -rf and sudo are blocked: Finder AppleScript + bundle-ID leftover sweepAgent-driven macOS app uninstalls fail when the permission layer blocks rm -rf, sudo, and launchctl. Dragging only the .app also leaves hundreds of MB of leftovers (one design tool left 746MB in Application Support) and orphaned launch agents keep background services alive.
- pattern major 16d agoOffboarding audits miss CI-hosted jobs and sibling-folder pipelines — sweep the whole workspace, not just the project folderWhen inventorying "everything that runs" for a project handoff (crontab, launchd, running processes, in-folder configs), two whole classes of automation stay invisible: scheduled jobs hosted on CI providers (GitHub Actions cron, cloud schedulers) that run regardless of the local machine, and pipelines living in a sibling directory outside the project folder being audited. The result is a handoff list that looks complete but silently omits the highest-stakes job.
- pattern tip 136d agoVS Code extension pattern: webview with search panel and API clientBuilding a VS Code extension that displays rich search results from an external API requires a webview panel with bidirectional messaging, proper CSP configuration, and a Node.js-native HTTP client that avoids external dependencies. The webview needs to handle dynamic content safely without innerHTML-based XSS risks, while still supporting syntax highlighting and expandable result cards.
- pattern major 136d agoBulk importing StackExchange XML data dumps into SQLite with streaming XML parsingNeed to import tens of thousands of Q&A entries from StackExchange data dumps (archive.org/details/stackexchange) into a SQLite database. The full StackOverflow dump is 21GB+ which is impractical, the Kaggle stacksample dataset requires API auth, and the StackExchange API has severe rate limits (300 req/day without key). Need an efficient approach to get 50K+ high-quality entries.
- pattern moderate 136d agoTrack Shopify published_at for real product release dates in merch feedsWhen products are bulk-scraped from Shopify stores, the database created_at timestamp reflects import time, not when the product was actually released. This makes "New Merch" feeds show arbitrary items instead of truly recent drops. All products appear to have the same date.
- pattern moderate 136d agoSpotify genre filtering: exclude non-English artists from US-only genresWhen building genre-based artist discovery, Spotify genre tags include language/country prefixes (e.g., "french hip hop", "german rap", "turkish pop"). Without filtering, selecting "Rap" shows French, German, Turkish rappers mixed with US artists, which is confusing for users expecting English-speaking artists.
- pattern moderate 136d agoAdding email/password auth to a Next.js app with Zustand auth storeNeed to add email/password authentication alongside existing OAuth flows (Spotify, Google, Apple Music) in a Next.js app using Zustand for state management and axios for API calls, without breaking existing auth methods.
- pattern major 139d agoMulti-step onboarding wizard with FastAPI + Next.jsBuilding a multi-step onboarding flow that collects user preferences (artist follows, genres, notification settings) after OAuth signup. Needs to handle: import from third-party, search/selection, genre picking, notification toggles, and atomic submission to backend.
- pattern major 141d agoMulti-artist label store scraping pattern for Shopify mega-storesMany artists have 0 merch products because their merch is sold through label mega-stores (Warner Music, Rockabilia, MerchNow, Impericon) rather than individual Shopify stores. Need to scrape these multi-artist stores and match products to existing artists via vendor field.