close

DEV Community

Dakota Huang profile picture

Dakota Huang

Building things with Python, Go, and JavaScript. Love automating everything.

Location Seattle, WA Joined Joined on 
Your Golden Output Test Misses Call Order. Pin the Interaction Log First.

Your Golden Output Test Misses Call Order. Pin the Interaction Log First.

Comments
5 min read
Let the Model Propose, Let the Corpus Reject: A Change-Budget Loop for Messy Repos

Let the Model Propose, Let the Corpus Reject: A Change-Budget Loop for Messy Repos

Comments
5 min read
Trace Callee Hits First: How to Scope One Safe Edit in a Messy Repo

Trace Callee Hits First: How to Scope One Safe Edit in a Messy Repo

Comments
4 min read
Cap the Diff, Not the Ambition: A Line-Budget Gate for Messy-Repo Refactors

Cap the Diff, Not the Ambition: A Line-Budget Gate for Messy-Repo Refactors

Comments
5 min read
Cap the Diff at One Seam: Picking the Smallest Safe Refactor After Characterization

Cap the Diff at One Seam: Picking the Smallest Safe Refactor After Characterization

Comments
4 min read
Characterize the Failure Path First: A Fault Matrix Before Your Smallest Refactor

Characterize the Failure Path First: A Fault Matrix Before Your Smallest Refactor

Comments
5 min read
Run It Twenty Times Before You Pin It: Characterization Tests for Messy Repos

Run It Twenty Times Before You Pin It: Characterization Tests for Messy Repos

Comments
5 min read
Freeze the Output Before You Touch the Function: A Behavior Census for Untested Code

Freeze the Output Before You Touch the Function: A Behavior Census for Untested Code

Comments
5 min read
Freeze the Clock Before You Refactor: Characterization Tests for Impure Code

Freeze the Clock Before You Refactor: Characterization Tests for Impure Code

Comments
6 min read
Characterization Tests First: Freeze a Messy Function, Then Make One Safe Edit

Characterization Tests First: Freeze a Messy Function, Then Make One Safe Edit

Comments
5 min read
Characterize First, Then Refactor: A Golden-Corpus Harness With a Mutation Gate

Characterize First, Then Refactor: A Golden-Corpus Harness With a Mutation Gate

Comments 1
6 min read
The Patch Window: Let a Model Refactor Only Lines Your Tests Already Cover

The Patch Window: Let a Model Refactor Only Lines Your Tests Already Cover

Comments
5 min read
One Revertible Slice at a Time: A Diff Budget for Messy Repos

One Revertible Slice at a Time: A Diff Budget for Messy Repos

Comments
5 min read
Refactor One Exit at a Time: The Exit-Path Ledger for Messy Functions

Refactor One Exit at a Time: The Exit-Path Ledger for Messy Functions

Comments
6 min read
One Seam Per Patch: How to Measure the Smallest Safe Refactor

One Seam Per Patch: How to Measure the Smallest Safe Refactor

Comments
5 min read
A Rollback Drill and a Per-Commit Green Gate for Messy Refactors

A Rollback Drill and a Per-Commit Green Gate for Messy Refactors

Comments
5 min read
The Revert Residue Check: Prove Your Small Refactor Leaves Nothing Behind

The Revert Residue Check: Prove Your Small Refactor Leaves Nothing Behind

Comments
5 min read
Dual-Run Parity Beats a Bigger Diff: Flipping a Messy Refactor Safely

Dual-Run Parity Beats a Bigger Diff: Flipping a Messy Refactor Safely

Comments
4 min read
The Smallest Safe Refactor Is Two Commits: Seam First, Move Second

The Smallest Safe Refactor Is Two Commits: Seam First, Move Second

Comments
5 min read
Every Refactor Commit Should Be Green and Revertible: A Bisect Audit

Every Refactor Commit Should Be Green and Revertible: A Bisect Audit

Comments
4 min read
Run the Old Function Beside the New One Before You Delete It

Run the Old Function Beside the New One Before You Delete It

Comments
5 min read
Give the Refactor a Diff Budget Before You Touch the Messy Repo

Give the Refactor a Diff Budget Before You Touch the Messy Repo

Comments 1
6 min read
Swap One Seam, Dual-Run Both Implementations, Then Delete the Old Path

Swap One Seam, Dual-Run Both Implementations, Then Delete the Old Path

Comments
4 min read
Retire the Golden Master: A Deletion Ledger for Refactors That Already Landed

Retire the Golden Master: A Deletion Ledger for Refactors That Already Landed

Comments
5 min read
Zero-Surface Refactors: Fingerprint the Public Interface Before You Split the Diff

Zero-Surface Refactors: Fingerprint the Public Interface Before You Split the Diff

Comments
6 min read
Refactor a Messy Repo With a Diff Budget and One Frozen Seam

Refactor a Messy Repo With a Diff Budget and One Frozen Seam

Comments
6 min read
Prove Your Characterization Test Can Fail Before You Refactor

Prove Your Characterization Test Can Fail Before You Refactor

Comments
5 min read
Three Gates Before the Refactor: Freeze Order, Drafted Tests, Flake Census

Three Gates Before the Refactor: Freeze Order, Drafted Tests, Flake Census

Comments
5 min read
The Change Ladder: Rank Candidate Diffs by Blast Radius Before You Refactor

The Change Ladder: Rank Candidate Diffs by Blast Radius Before You Refactor

Comments
5 min read
Your Characterization Test Captured the Clock: Prove Stability Before You Pin a Golden Master

Your Characterization Test Captured the Clock: Prove Stability Before You Pin a Golden Master

Comments
5 min read
A Passing Characterization Test Proves Nothing Until You Break the Code

A Passing Characterization Test Proves Nothing Until You Break the Code

Comments
5 min read
Run Your Characterization Recorder Three Times Before You Trust It

Run Your Characterization Recorder Three Times Before You Trust It

Comments
5 min read
Prove Your Characterization Tests Can Fail: A Mutation Preflight for Messy Repos

Prove Your Characterization Tests Can Fail: A Mutation Preflight for Messy Repos

Comments
5 min read
Prove Each Golden Can Fail Before You Refactor the Messy Repo

Prove Each Golden Can Fail Before You Refactor the Messy Repo

Comments
6 min read
Import First, Refactor Second: Triage a Repo Nobody Can Run

Import First, Refactor Second: Triage a Repo Nobody Can Run

Comments 1
5 min read
Your Characterization Tests Are Guarding Dead Code: A Coverage Census for Messy Repos

Your Characterization Tests Are Guarding Dead Code: A Coverage Census for Messy Repos

Comments
6 min read
The Diff Budget: Prove the Smallest Safe Refactor Before You Merge It

The Diff Budget: Prove the Smallest Safe Refactor Before You Merge It

Comments
5 min read
Lock the Public Surface Before the Refactor: A Manifest Gate for AI-Proposed Diffs

Lock the Public Surface Before the Refactor: A Manifest Gate for AI-Proposed Diffs

Comments
6 min read
Your Refactor Copies a List. The Caller Still Holds the Old One.

Your Refactor Copies a List. The Caller Still Holds the Old One.

Comments
5 min read
Replay the Seam: A Differential Gate for the Smallest Safe Refactor

Replay the Seam: A Differential Gate for the Smallest Safe Refactor

Comments
5 min read
Run It Ten Times Before You Write One Characterization Test

Run It Ten Times Before You Write One Characterization Test

Comments
6 min read
Two Runs Must Agree Before You Freeze a CLI Transcript

Two Runs Must Agree Before You Freeze a CLI Transcript

Comments
6 min read
Count the Clocks Before Characterization Tests: A Nondeterminism Census for Messy Repos

Count the Clocks Before Characterization Tests: A Nondeterminism Census for Messy Repos

Comments
5 min read
Map Every Changed Line to the Test That Ran It Before You Refactor

Map Every Changed Line to the Test That Ran It Before You Refactor

Comments
6 min read
Pin the Order of Side Effects Before the Refactor: An Effect Ledger Gate

Pin the Order of Side Effects Before the Refactor: An Effect Ledger Gate

Comments
6 min read
Record What Your Code Throws Before You Refactor It

Record What Your Code Throws Before You Refactor It

Comments
5 min read
Your Characterization Tests Passed. The Side Effects Changed Order.

Your Characterization Tests Passed. The Side Effects Changed Order.

Comments
5 min read
Triage Nondeterminism Before Golden Tests: A Probe for Messy Repos

Triage Nondeterminism Before Golden Tests: A Probe for Messy Repos

Comments
7 min read
Pin the Order, Not Just the Value: an Interaction Ledger for Messy-Repo Refactors

Pin the Order, Not Just the Value: an Interaction Ledger for Messy-Repo Refactors

Comments 1
6 min read
Let the Free Model Write Inputs, Not Assertions: A Mutation Gate Before Your Refactor

Let the Free Model Write Inputs, Not Assertions: A Mutation Gate Before Your Refactor

Comments
5 min read
Before the Smallest Safe Change, Prove Your Characterization Tests Can Fail

Before the Smallest Safe Change, Prove Your Characterization Tests Can Fail

Comments
5 min read
Break Your Code on Purpose: A Kill-Rate Gate for Characterization Tests

Break Your Code on Purpose: A Kill-Rate Gate for Characterization Tests

Comments
6 min read
Prove the Smallest Safe Change Is Mechanical: An AST Diff Gate

Prove the Smallest Safe Change Is Mechanical: An AST Diff Gate

Comments
5 min read
Census the Names a Function Reads Before You Extract It

Census the Names a Function Reads Before You Extract It

Comments
5 min read
Freeze the Export Surface Before a Messy Refactor: A Manifest Gate in Python

Freeze the Export Surface Before a Messy Refactor: A Manifest Gate in Python

Comments
6 min read
Test the Process, Not the Module: A Black-Box Characterization Gate for a Repo You Can't Import

Test the Process, Not the Module: A Black-Box Characterization Gate for a Repo You Can't Import

Comments
5 min read
Time Your Safety Net First: A Budget Gate for Characterization Tests in Messy Repos

Time Your Safety Net First: A Budget Gate for Characterization Tests in Messy Repos

Comments
5 min read
Characterize the Boundary, Not the Module: An Import-Graph Gate for Messy Refactors

Characterize the Boundary, Not the Module: An Import-Graph Gate for Messy Refactors

Comments
5 min read
Census Every Raise Site Before You Move a Module

Census Every Raise Site Before You Move a Module

Comments
5 min read
Record the Ordered Side-Effect Ledger Before You Move One Function

Record the Ordered Side-Effect Ledger Before You Move One Function

Comments
4 min read
loading...