One afternoon ten CI jobs queued within a second of each other, and four of them started three minutes late. EC2 had capacity for all ten the whole time. This is the third of five posts about running each GitHub Actions job on its own EC2 spot instance. The first post covers the design. This one is about the single API call the whole system depends on, RunInstances, and the two bugs that taught us where a retry belongs. The version that almost worked A job chooses a pool with a label, and a pool is a list of three instance types, newest generation first. To launch, we try each type in each of
On 10 November 2026, during a GitHub incident, our runner control plane refused 17 CI jobs in 13 minutes. It logged no error, because from where it stood nothing had failed. This is the second of five posts about running each GitHub Actions job on its own EC2 instance. The first post covers the design. This one is about the only input the system has, GitHub's workflow_job webhook, and what it takes to build on an input you cannot trust. The version that fits on a napkin The design looks like two event handlers: on queued: launch an instance for the job; on completed: record the result. It ran
Consistency without substance creates noise. Real trust comes from solving a specific problem clearly, even if you publish less often. Continue reading on Medium »
Your user is looking at a map of downtown Seattle. They type "400 Broad St" into the search box next to it. Which 400 Broad Street do they mean? Almost certainly the one on the map: the Space Needle's address. But the search box doesn't know about the map, so it offers Des Moines, Utica and Georgetown too. In this tutorial we connect the two. The search box gets a bias to the map center, so nearby addresses come first, and an "Only in this map area" switch that turns on a filter, so only addresses on the visible map are suggested. Both follow the map as the user pans and zooms. At the end, we
Hire an AI agency when several workstreams have to move at once and you want a bench. Hire one senior AI engineer when you need a single agent, written by the person you talk to, with the repo and the accounts in your name. Hire in-house when the system will still be changing in a year and you already have someone who can manage that person. That is the decision. Vetting the person is a different page: Hire an AI engineer. Cost, without a made-up rate card, is in AI agent development cost. When an AI agency wins An agency sells capacity: more than one person, a schedule, and someone whose job
If you let an AI coding agent tidy up your project, sooner or later it will delete something you needed. Not out of malice — out of confidence. The file looked unused. The folder looked like a duplicate. The cleanup looked obvious. The fix is one rule, written down where the agent has to read it: Never delete. Move it to a quarantine folder and ask. That single rule — plus a short written rules list around it — is what turned my Claude Code sessions from "fast but occasionally scary" into something I can leave running. Here is the whole system. TL;DR Put a no-delete rule in your project instru
TL;DR A direct Gumroad sale is charged 12.9% + $0.80 in total: Gumroad's 10% + $0.50 fee, plus 2.9% + $0.30 card processing. Because of the fixed $0.80, the effective rate depends on your price: $5 sale → you keep $3.56 (28.9% gone) $9 sale → you keep $7.04 (21.8% gone) $19 sale → you keep $15.75 (17.1% gone) $49 sale → you keep $41.88 (14.5% gone) Sales through Gumroad Discover cost a flat 30% instead. Rates below verified against Gumroad's official help page in November 2026. The fee breakdown Component Rate Fixed Gumroad fee (direct sales) 10% + $0.50 Card processing 2.9% + $0.30 Total, dir
Your service handles requests from a message queue. After a busy morning, someone in the team chat writes that the connection pool is far too small for this load, by Little's law. Two other people agree. You are not sure whether you are allowed to ask what Little's law is. You are, and the good news is that it fits on one line. In 1961 John Little, an operations researcher, published a proof of a formula that people in queueing theory had been using for some time. It says that L = λ × W. L is the average number of things in the system. λ, the Greek letter lambda, is the rate at which they arri
Each of our depots has a small Debian gateway that the handheld scanners talk to. Our playbook templates the scanner API's configuration, and one line in it has been the same for four years: bind_address: {{ ansible_default_ipv4.address }}. Every gateway had one network card on the depot LAN, so the default IPv4 address and the LAN address were the same thing. In November we opened two new depots with a new gateway build. These have two network cards. enp1s0 is on the depot LAN. enp2s0 is a dedicated internet line for carrier traffic, and the default route goes out through it, because that is
15:12 IST, Wednesday. Datadog: p95 on GET /orders is 410 ms and climbing. It was 38 ms this morning. Nothing deployed since Monday. the scramble Priya gets paged first because the alert routes to the orders on-call. She posts the graph in the incident channel: latency is not a step, it is a ramp, starting around 09:30 and getting steeper every hour. A ramp usually means something is accumulating. First theory: the planner picked a bad plan after yesterday's stats refresh. I run EXPLAIN (ANALYZE, BUFFERS) on the list query and compare it to the saved plan from last week. Same plan, same index (
A client replies "payment goes out Friday." That can be more useful than silence, but it only helps if you can see later whether Friday came and went. A small log is enough. Here is the format, with placeholder data: Invoice Amount Original due date Promised date Promised by Status [#] [amount] [date] [date] [name] open Fill in a row when the promise is made. Update the status when the date passes: paid, or promise missed. When the promised date has passed. Check whether the payment arrived. Allow for processing time, and look at what you have already said to this client. Then send a short mes
The bill for screening a logistics catalogue import has several parts: processing uploaded images, checking job status, retaining originals and results, and investigating disputed decisions. Processing every submitted image remains the main work term in a design that screens every upload. With an illustrative import of 1,000 images, screening at upload means 1,000 screening decisions; changing the polling interval cannot remove those decisions. Which term dominates the actual bill requires your workload and provider rates. Short answer: submit the images as one batch, persist its identifier, a
I see you everywhere, but not beside me, seeing you laughing with another girl as a new source of happiness, not to replace me but to… Continue reading on Medium »
When Tether freezes a USDT address on TRON, most tools learn about it from one event: AddedBlackList on the USDT contract. By the time that event fires, the address can no longer send USDT. But the freeze does not start there. It starts minutes, sometimes days, earlier, as a public transaction in a 2-of-3 multisig wallet, with the target address sitting in plain view in the call data. This post shows how to read that multisig with nothing but the public TronGrid API, what we found when we measured every freeze for a year, and how we use it in FreezeCheck, a free AML checker for TRON USDT walle
I asked Python to remove every even number from a list: nums = [2, 2, 3, 4] for n in nums: if n % 2 == 0: nums.remove(n) print(nums) # [2, 3] One 2 survived. No error, no warning, just a wrong answer. Below is exactly why, the same bug with dictionaries, and four ways to do it right. Everything was run on Python 3.15. Video version: Why: the loop walks by index A for loop over a list keeps an internal position: index 0, then 1, then 2… remove() shifts every later item one step to the left. I printed each step: visit index 0 → 2 list [2, 2, 3, 4] remove it visit index 1 → 3 list [2, 3, 4] (the
Hooks and the request lifecycle Ninth chapter of the "Fastify with TypeScript" series. Hooks are Fastify's equivalent of middleware, but with a well-defined execution order and much finer granularity. Rather than memorize that order from a diagram, we'll make the application print it. The lifecycle Every request goes through the same sequence of stages, and you can attach a function, a hook, to each of them: onRequest → preParsing → preValidation → preHandler → handler → preSerialization → onSend → onResponse Watch it happen Add this at the top of the userRoutes plugin in src/users/users.route
In school you learned that 2.5 rounds up to 3. Python disagrees: >>> [round(x) for x in (0.5, 1.5, 2.5, 3.5, 4.5)] [0, 2, 2, 4, 4] >>> round(-1.5) -2 JavaScript does it the school way: $ node -e "console.log(Math.round(2.5))" 3 It's not a bug. Below is why Python does this, a second, unrelated reason round() surprises people, and how to round money correctly. Everything was run on Python 3.15 (and Node.js 22 for Math.round). Video version: Round half to even ("banker's rounding") When a number is exactly halfway between two integers, Python's round() picks the even one. That's the IEEE 754 def
Plugins and encapsulation Eighth chapter of the "Fastify with TypeScript" series. The plugin system is arguably Fastify's most distinctive feature, and understanding encapsulation is essential to structuring any application well. We have been using a plugin since chapter 5 (userRoutes is one). In this chapter we write a second one, watch it fail in an instructive way, and fix it. What a plugin is A plugin is a function that receives a Fastify instance and adds things to it: routes, hooks, decorators, other plugins. You hand it to app.register(). The instance a plugin receives is not the root a
Code tested against VisioForge.DotNet.MediaBlocks 2026.11.23. Runnable demo: PreEventRecording. Latest version of this guide: VisioForge… Continue reading on Medium »
Users of my app, Beluga, upload property photos and videos, and I needed every one of those files to carry a watermark but I didn't want to do it by hand, and I didn't want to push the work into the Flutter app or onto my backend server. My uploads already went straight from the Flutter app to Amazon S3 through presigned URLs. So, I kept that and added one small piece: when a file lands in S3, a Lambda function watermarks it and writes it back to the same object key. The app and the backend don't change, and every stored URL keeps working. This post walks through the whole build: the AWS setup