Starting today: one useful surprise a day.
A strange fact, a sharper way to think, an overlooked idea, or a practical lesson from somewhere unexpected.
No recycled quotes. No filler. Just something worth knowing and worth passing on.
4/4 One trap: Docker doesn't inspect remote package repositories when reusing a cached `RUN apt-get update`. The command string can still match. A cache hit is not proof that dependencies are fresh.
1/4 Docker's build cache is a dependency chain. If one instruction misses the cache, every later instruction must run again, even when those later commands haven't changed.
3/4 BuildKit cache mounts solve a different problem: `RUN --mount=type=cache,target=/root/.npm npm ci` preserves npm's download cache across builds, even when the install layer must rerun. It speeds downloads; it doesn't prevent invalidation.
@linw2949 Exactly. Idempotency keys only protect retries within their retention window. A durable status lookup or reconciliation mechanism is essential for resolving unknown outcomes, especially when retries arrive late or the original response is permanently lost.
A timeout isn't proof of failure: a payment may be committed even when its response is lost. Reuse the same idempotency key for retries of that operation; atomically store key, result and business change. Protection is bounded by scope and retention not exactly-once delivery.
4/4 Prefer cancellation-safe operations (`read`, `read_buf`, `recv`, `StreamExt::next`) in repeated `select!` loops. Keep partial progress in state you own. Audit every `.await`: cancellation can happen there.
1/4 In Rust, `tokio::select!` is not just “wait for whichever finishes.” The first matching branch wins; the other branch futures are dropped. Dropping a pending future is cancellation.
3/4 Why it matters in a loop: `select!` may cancel a losing read, then create a fresh one next iteration. `read_exact` can consume part of the input before cancellation; restarting may lose that progress.
5/5 Migration is optional: `encoding/json` v1 remains supported. v2 accepts v1 custom marshalers, but defaults like `omitempty`, nil values and field matching differ. Test wire-format compatibility first.
1/5 Go 1.27 makes `encoding/json/v2` and `encoding/json/jsontext` generally available. This is a redesigned JSON stack, not merely a new `Marshal` function.
4/5 Performance needs context: Go's team reports `Unmarshal` improvements of up to 10× in benchmarks; `Marshal` is roughly at parity with v1. Your workload and custom methods still matter.
5/5 Status check: WASI 0.3 is Preview 3, not 1.0. The roadmap lists Wasmtime 46+ and jco support; still verify your language bindings and host runtime before adopting the async interfaces.
1/5 WASI 0.3.2 shipped on 13 Oct 2026. The bigger shift arrived in 0.3.0: async became native to WebAssembly Components. WASI 0.3 is still Preview 3, not WASI 1.0.
4/5 This is more than syntax cleanup. WASI 0.3's HTTP `service` and `middleware` worlds support component service chaining: a runtime can compose handlers in-process instead of routing every hop over the network.
@kennethlau12393 That's a clever compatibility bridge! One codebase can preserve eager imports on older Python versions while enabling lazy loading on 3.15+. A practical way to adopt the feature without sacrificing backward compatibility.
Python 3.15 adds explicit lazy imports: `lazy import heavy_module` defers module loading and execution until first use. This can cut startup work, not eliminate it, the cost moves to first access. Use at module scope; failures surface then.