Back to Movie Clips

Agatha All Along

It was Agatha all along — and it was colorMode() all along.
The WandaVision reveal that explains why
debugging sometimes needs breadcrumbs, not intuition.

About WandaVision — Marvel’s Most Unusual Show

WandaVision (Disney+, January–March 2021) was Marvel’s first television series in the Marvel Cinematic Universe — and it arrived unlike anything the studio had made before. Set after the events of Avengers: Endgame, the nine-episode miniseries follows Wanda Maximoff (Elizabeth Olsen) and Vision (Paul Bettany) living an idyllic suburban life — except that life unfolds as a succession of classic American sitcom styles, from the black-and-white 1950s through the full-color 1990s, one decade per episode.

The show begins charming and disorienting in equal measure. Something is very wrong inside the fictional town of Westview, New Jersey — but the audience, like Wanda, cannot quite name what it is. Outside the bubble, S.W.O.R.D. agents watch the anomaly on screens, trying to reach in. Inside, neighbors wave and smile a little too perfectly. Vision occasionally asks questions that feel like they are from a different reality. And through it all, the sitcom laugh track rolls on.

The show is ultimately about grief. After Vision’s death in Infinity War, Wanda’s raw, unprocessed grief manifested as a reality-warping field of chaos magic that consumed an entire town, trapping its residents inside her idealized fantasy of domestic life. The sitcom format is not a gimmick — it is the architecture of denial. Each decade represents a layer of avoidance, a stage of grief given aesthetic form.

It won eleven Emmy Awards, including Outstanding Limited or Anthology Series or Movie. The costume design, the shot-for-shot sitcom recreations, and the two lead performances were all widely praised. And then there was the song.

Agatha Harkness — The Neighbor Who Was Never What She Seemed

Throughout WandaVision’s early episodes, Agnes is Wanda and Vision’s enthusiastically nosy neighbor — cheerful, slightly odd, always showing up at exactly the right (or wrong) moment. She is played by Kathryn Hahn with a barely-contained energy that keeps viewers perpetually unsure whether Agnes is comic relief, a red herring, or something more. She felt like a classic sitcom neighbor: funny, warm, a little too eager.

And then, in Episode 7 (“Breaking the Fourth Wall”), the curtain drops.

Agnes leads Wanda into her basement. The cheerful neighbor persona evaporates. The truth emerges: Agnes is Agatha Harkness, a centuries-old witch who had been manipulating events inside the Hex from the very beginning — feeding on Wanda’s power, steering the fantasy, pulling strings behind every episode’s carefully constructed sitcom world. All those moments that felt harmless, funny, or incidental? Agatha. The chaos and misdirection? Agatha. The “glitches” that seemed like random noise? Agatha.

“It was Agatha all along!
She’s been pulling every evil string —
something wicked is going on…” — “Agatha All Along,” Kristin Anderson-Lopez & Robert Lopez — WandaVision, Ep. 7, 2021

The reveal is delivered as a villain origin flashback montage set to an earworm of a song written by Kristin Anderson-Lopez and Robert Lopez (the duo behind Frozen’s “Let It Go”). The song recaps every suspicious moment from prior episodes — now recontextualized as Agatha’s manipulations. The effect is simultaneously funny and genuinely unsettling. You were watching all along. You just weren’t watching the right person.

The TNT Connection — Why This Scene Lives in a Coding Classroom

While converting a p5.js JitterBug sketch to Python Processing, a strange thing happened: the program ran, but instead of a full canvas, all that appeared was a tiny gray square in the corner. No error. No warning. No stack trace. The IDE just… silently failed.

The natural suspect was the trail effect — the semi-transparent overlay that creates a motion blur behind the moving object. That was the most recent change, the last thing added, the most “experimental” piece of code. So we looked there first. We looked hard. We rewrote it. Nothing changed. The gray square remained.

It was not the trail code.

The real culprit was hiding in plain sight, three lines earlier: a call to colorMode(HSB, 360, 100, 100, 100) placed immediately after size() inside setup(). In Python Processing, colorMode() requires the graphics renderer to be fully initialized. But when size() lives in setup(), the renderer isn’t ready yet when the next line runs. The call to colorMode() short-circuits silently, setup never completes, and the sketch renders a minimal stub canvas. It looked like a trail problem. It was a colorMode() problem all along.

The fix — moving size() into a settings() function so the renderer is fully initialized before setup() begins — solved everything instantly. And the moment it clicked, the WandaVision reference was unavoidable: a cheerful, apparently innocent line of code, quietly pulling all the strings behind the scenes.

There is a broader lesson here, and it applies to every complex system: the most dangerous problems are not the loud ones. Loud problems announce themselves with red text and line numbers. Quiet problems look exactly like normal code and smile at you while everything falls apart. In Python Processing especially, the IDE is very lean on error messages — things just break silently. The right response is not intuition. It is breadcrumbs.

The Breadcrumb Technique — How to Debug When the IDE Goes Silent

When a program fails silently — no error, just wrong output — the right tool is a trail of print() statements called breadcrumbs. Place one at the start of every major block and, critically, one at the very end of every function. The first ending print that never appears in the console tells you exactly which function died.

def settings():
    print("...settings START...")
    size(450, 450)
    print("...settings COMPLETE...")
# end settings

def setup():
    print("...setup START...")
    colorMode(HSB, 360, 100, 100, 100)
    print("...colorMode set...")      ← this never printed
    background(white)
    print("...setup COMPLETE...")
# end setup

The # end setup and # end draw comments are not just style. They make function boundaries visible when scanning a long file, and give the console output a named destination to match against. When ...setup COMPLETE... never appears but ...setup START... does, you have a bracket: the failure is inside setup(), and you narrow from there.

Agatha hid in plain sight for seven episodes because no one was looking for her specifically — they were watching the sitcom. Bugs hide in plain sight because we’re watching the wrong suspect. Breadcrumbs force you to look systematically, function by function, line by line, until the real culprit has nowhere left to hide.

Movie clip is only available in larger viewports.
On some mobile devices, rotating to landscape will allow viewing.