"Trilogy of Error" is the eighteenth episode of season 12.
Homer's thumb is cut off following breakfast and the episode follows three different paths. Homer's day: as he and Marge race to get his thumb reattached. Lisa's day: as she misses the bus and tries to get to school so that she can win the science fair. Bart's day: as he and Milhouse make use of a stash of fireworks that Fat Tony has illegally smuggled into the country. In the end their respective paths come together.
A garbage truck comes by. It picks up Ned's mailbox (making him say "Son of a diddily"), and then a newspaper saying that Spring has arrived is tossed.
 Homer's Day
Homer is getting ready for work and after coming out of the shower, he tries to eat breakfast. However, Marge bought a really hard to eat breakfast from Europe and then Bart leaves when Milhouse rings the doorbell. Lisa tries to spare her mother's feelings by winking to Homer and asking if he wants to see her school project, Homer not understanding what Lisa is doing. Homer said no but he'd rather do that than eat the crappy breakfast, leaving Marge in the kitchen hurt. Lisa shows Homer her science project, Linguo, a grammar fixing robot and when Homer says "Me like beer", Linguo corrects it by saying "I like beer" and Homer gives Linguo a bottle of Duff Beer and makes him malfunction. Homer then sees a tray of brownies in the kitchen and Homer wants one but Marge is still cutting them. Homer then attempts to grab one when Marge is cutting and she accidentally cuts Homer's thumb off. Marge tries to call 911, however Chief Wiggum, who picks up the line, misinterprets the information as a deliberate attack and states that she will be arrested, forcing Marge to use a fake address of 123 Fake Street. Marge drives Homer to a doctor, but crashes into Rainier Wolfcastle's car forcing them to carjack him. After learning from Dr. Hibbert that Homer's finger insurance does not cover his thumb, Marge drives Homer to Dr. Nick's hospital. When his thumb is decaying, Homer and Marge make a pitstop at Moe's Tavern and Moe gives Homer a new jar to put his thumb in to preserve it. After wasting time in the tavern, Homer comes out and finds that Marge and the car are gone and Homer catches a ride with Cletus to go to Dr. Nick's. However, Dr. Nick's is on fire and Marge steals Cletus's truck, forcing Homer to walk to Shelbyville. 20 miles away, he decides to bin his thumb, and then sees Linguo's head fly to him following an explosion.
 Lisa's Day
After Homer gives Linguo beer and makes him malfunction, Lisa goes to her room and fixes Linguo. But when Lisa has to leave, her bike is missing, the bus has left (while Martin is on it with his science project ready), and Homer and Marge have left for the hospital. Lisa runs to school and sees Krusty's limo after it almost hits her. Krusty has his chauffeur, Mr. Teeny, to take Lisa to school, passing Chief Wiggum along the way who asks for directions to 123 Fake Street. However, it is the wrong school and Lisa is actually in West Springfield Elementary and there she meets a student named Thelonius who she falls in love with. Lisa then runs to Moe's Tavern to find Homer, but Homer is not there. She notices that Chief Wiggum is there who is working on a sting operation to catch some fireworks smugglers and is listening to the conversation with some people he sent undercover and the criminals. When Lisa recognizes one of the criminals as Fat Tony, Wiggum speaks into the microphone which exposes the undercover people, Bart and Milhouse. Just as Lisa leaves Moe's, Homer and Marge arrive. Lisa sees Marge outside, and hops in her car which Marge stole from Rainier Wolfcastle. They leave when Marge hears Homer talking to Moe drunk and knows she has plenty of time to drive Lisa to school. However, the car instructions are in Italian and they run out of fuel. Marge and Lisa then take a ride in Cletus's truck by hiding in the back (with some chickens) and after arriving at Dr. Nick's, Marge steals the truck, during the time that Homer and Cletus observe that the hospital is on fire. With only a few minutes of school left, Marge attempts to make it. But as she does, Bart crawls out of a manhole and the truck is headed right for him.
 Bart's Day
At breakfast, Milhouse comes over and Bart tags along with him. They steal Lisa's bike and go to a cave where Milhouse has found firecrackers. The boys enjoy blowing things up, such as Skinner's lawn gnomes and Dr. Nick's office. They hear sirens and hide in an abandoned building and are caught by Chief Wiggum (which is a coincidence as the building's address is the fake address that Marge made up to Chief Wiggum earlier). The boys are then put into a sting operation to find the real firework smugglers who end up being Fat Tony's gang. Bart and Milhouse are exposed when Wiggum speaks into their receiver and are forced to escape. They come out through a sewer and then come up through a manhole cover and Bart is nearly ran over by Marge and Lisa, but instead gets a small blow on the head. The boys, Marge, and Lisa are then confronted by Fat Tony in an alley, but Lisa has to sacrifice Linguo by having him fix the terrible grammar of Legs and Louie that overloads him and the sparks from his body set off the fireworks, causing a big explosion. Over on the highway, Homer finds Linguo's head, as it flew through the air and landed in front of him.
Legs is able to avoid arrest by sewing Homer's thumb back on and it becomes Lisa's science fair project, which is awarded 1st place by Ms. Hoover. The whole episode cast comes and laughs except for Mr. Teeny who murmurs "this plot made no sense" an example of "breaking the fourth wall".
The episode was written by Matt Selman and directed by Mike B. Anderson.
The episode has received positive reviews. IGN awarded the episode a rating of 9, describing it as "outstanding" and suggested that, "The Simpsons may have peaked in the '90s, but that doesn't mean the eight years since haven't delivered their share of quality episodes. This was one of them. And with so much plot to go over in this review, there just wasn't enough room to reference all the great lines. Like Dr. Nick's, 'Inflammable means flammable?!' and Cletus' reference to 'TV magic queers'."