After losing the race for president in 2008, Hillary made plans to ensure that never happened again.

She believed—no, she was certain—that history had chosen her to be the first woman president of the United States. All the years of acting the role of First Lady, all the public humiliation with Bill’s sex life strewn across TV, it would all finally pay off.

And she wrote a damn good script. Once again swallowing her pride, Hillary came to publicly support Barack Obama, taking as her prize the job of secretary of state. As secretary, she amassed hours of B-roll footage of herself traveling around the world empowering women, talking tough to dictators, and showing concern.

About a year ago, everything looked good. She had a summer autobiography out with a not-running-for-president book tour to get her into the news ahead of a fall announcement to run. Bill was again at her side, the Old Dog returning some big favors by sharing his popular image. The Democratic National Committee made sure the fix was in, ensuring that she’d have as “competition” only the loyal punching bag Martin O’Malley, who’d fight the good fight for a while before graciously disappearing forever.

And just in case, the superdelegate system was tweaked up to guarantee Hillary didn’t even need to win too many primaries. That would also bank campaign funds for the general election. She’d be on the offensive the whole time, controlling the message, basically running an 18-month general-election campaign.

And on the Republican side, Hillary faced no real challenge. A limp Jeb, a frustrating Mario, an unsteady Cruz and some has-beens and never-will-bes. It’d be a turkey shoot.

But … but … Hillary just couldn’t stop being herself. Her lies and parsing and prevarications made her end up as the only candidate in U.S. history running for office while under investigation by the FBI.

She is now struggling to stay above water, limping toward the nomination based on some funny delegate math and a few earlier victories in the South. If she is the nominee, she’ll be the least popular and least trusted nominee from her party in its history, with a negative campaign based nearly 100 percent on hoping people dislike Trump just a bit more than they dislike her. And she did it all by herself.

Her endless paranoia led her to create that private email server as secretary of state, despite advice to the contrary (as well as common sense). She tried to hide it—until she got caught. Her reaction then was to sound like a desperate lawyer without much of case, parsing words and claiming she was once again the victim of a vast right-wing conspiracy. Under pressure, she later issued a faux apology and pleaded with people to forget the whole thing. Served by a compliant media, she was pretty successful.

She and her aides are being subpoenaed in multiple Freedom of Information Act cases. The State Department—her State Department—issued a scathing inspector-general report blowing holes in her assorted explanations for the server. State still has an open and ongoing conflict-of-interest investigation into Clinton’s decision to have senior aide Huma Abedin employed simultaneously by Clinton, the State Department, a Clinton-connected private firm, and the Clinton Foundation. Accusations and investigations into the foundation’s shady finances and overseas donations swirl.

If any of this would have caught the public’s eye a few months sooner, Bernie Sanders would already have the Democratic nomination. If somehow the primary season had a few more months to go, Bernie Sanders would have the nomination.

As it is, the game is not over, as Clinton must survive the final primaries, an FBI report on her mishandling of classified materials on her email server, the convention, and of course the general election itself. Trump will be a rough opponent, and Clinton will be on the defensive much of the time. It is unclear how many of Sanders’ supporters will come over to her after such a bitter primary season.

Clinton may yet sneak through all this to claim her prize, floating on a new standard for the presidency: “At least she’s not under indictment.” But is that really the way we want to choose our leaders?

Peter Van Buren blew the whistle on State Department waste and mismanagement during the “reconstruction” of Iraq in his bookWe Meant Well: How I Helped Lose the Battle for the Hearts and Minds of the Iraqi People. He writes about current events at We Meant Well. His latest book is Ghosts of Tom Joad: A Story of the #99Percent. His next work will be a novel,Hooper’s War.