Television audiences can have tough times saying good-bye to shows they love. For every finale that elicits tears and cheers on its departure—every Mary Tyler Moore Show or Six Feet Under that vacates in triumph—there’s a Dexter or a How I Met Your Mother that bows out with loyal viewers feeling cheated or even betrayed.

The ending of The Sopranos was so shocking, so ambiguously abrupt, that loyal viewers needed time to process what had happened before they could figure out whether or not they even liked it.

Still, of all the eagerly anticipated finales of modern times, none inspired as many impassioned debates as did HBO’s explosive cultural landmark Game of Thrones, its biggest commercial hit ever and the most expensive show in HBO history. “How would it end?” was a question that gripped the viewing nation long before HBO announced plans for the show’s final chapter.

In a scene reminiscent of Alaric’s sack of Rome, Tyrion Lannister stands powerless at the walls of the capital, watching his city burn.

In fact, the dilemma facing HBO over how this monumental series would bow out had been baked into the company’s genealogy decades earlier. Since his arrival in the Home Box Office programming department, in 1976, just four years after the network had taken timidly to the air, Michael Fuchs—HBO’s fearless George Washington—had been determined to distinguish this new pay-TV venture from the big three commercial networks that had ruled the airwaves since radio days. Fuchs’s aggressive offensive was a multi-faceted campaign built on two fundamental tenets.

First, do what networks couldn’t do. That meant sex, violence, and cursing—all strictly forbidden on the commercial nets—had to be welcome, even commonplace, on this new enterprise. (Hence HBO’s airing of George Carlin’s “seven words you can’t say on television” routine.)

“How would it end?” was a question that gripped the Game of Thrones viewing nation long before HBO announced plans for the show’s final chapter.

Second, make sure HBO got known around town as a talent-friendly outfit, not just for recognizable stars signing on dotted lines but for creators too. Fuchs was determined that show-runners and their “creative” colleagues have as much freedom as possible—something the big three, with their affection and hubris for micro-management, were constitutionally incapable of doing.

It worked.

Two of HBO’s most important original productions early on—The Larry Sanders Show and Oz—were about as autonomous as anything ever seen in series television. At one point, Garry Shandling was able to deliver an episode of his show that was only 20 minutes long and, at another point, to take more than a year off. When Tom Fontana, creator of Oz, was asked by then HBO programming executive Chris Albrecht, “What’s the one thing you have never been allowed to do on broadcast television?,” Fontana replied, “Kill the lead in the first episode.” Albrecht stared back and told Fontana, “Okay, we’ll do it.”

Jon Snow swears fealty to his new king, Bran the Broken, before departing for the wall.

Fast-forward to 2015, when David Benioff and D. B. Weiss, the superb show-runners for Game of Thrones, visited HBO programming head Mike Lombardo to discuss plans for the show’s final chapters.

Previous seasons of Game of Thrones had been 10 episodes each; Lombardo was hoping for 9 seasons, possibly even 10. But at the meeting, Weiss and Benioff announced that the series’s seventh season would be a mere eight episodes long, and that the season after that would be the show’s last and would consist of only six shows. To make matters even more horrific for HBO, the two film buffs even dangled the possibility of formally ending the show with a theatrical movie … or two.

After the meeting, Lombardo quickly phoned his boss Richard Plepler, HBO’s C.E.O., to share the bad news. Plepler, widely known for his incredible powers of persuasion, pleaded to Benioff and Weiss that they “extend” their “ownership of the culture.” But the formula that had served HBO well for decades—placing trust and power in the creators’ hands—now came back to bite the brass on the nose. Benioff and Weiss agreed to abandon their fanciful dreams of a theatrical ending but would yield no further.

By the time Season Eight began, the über-dedicated Game of Thrones partisans had already devoted 63 hours and 11 minutes of viewing time to their magnificent obsession, a huge commitment. And though crestfallen at the prospect of only a six-episode final season, they still held out hope for the best.

Benioff, Weiss, and the entire production team poured themselves into that final season with the same zeal and invention they’d shown for the entire run. Despite their best efforts, however, the resultant disappointment in the truncated season would leave HBO to face a vast constituency brokenhearted over what many considered a tortured conclusion.

James Andrew Miller’s Tinderbox: HBO’s Ruthless Pursuit of New Frontiers will be published on November 23 by Henry Holt