The New York Democratic primary on Thursday night might appear, at first glance, to have been a letdown for New York progressives. The attention-grabbing statewide nominating races — most notably actress and activist Cynthia Nixon’s attempt to unseat two-term incumbent governor Andrew Cuomo — all ended in defeat for the insurgent left challengers, albeit to varying degrees.

Casual observers might now be asking what chance the left wing of the Democratic Party stands in the rest of the country if it can’t even win a primary in a state as liberal as New York. They might even wonder whether the surprise victory of self-described democratic socialist Alexandria Ocasio-Cortez in the state's congressional primaries back in June was a mere flash in the pan.

But actually, it’s a miracle any progressive challengers won at all, and many state legislative candidates did just that.

In a deeply liberal state like New York, with its entrenched systems of political patronage, the odds are stacked against progressive primary challengers in a way they are not in red states, where the Democratic establishment is weaker. So while New York is indeed a blue stronghold, it’s also one of the most corrupt states in the nation — home to a powerful machine that Cuomo, whose father served three terms as governor in the 1980s and 90s, currently sits atop.

For example, a former top aide of Cuomo’s, Joseph Percoco, was convicted of three corruption charges in March. Or, take the fact that Cuomo once created an independent body called the Moreland Commission to investigate corruption in state government, only to block and subsequently disband it when it got too close to his own office. And story after story has come out just this year about companies and people who have suddenly found success in New York after donating to the governor's campaign.

Through a deeply entrenched system of favor-trading, Cuomo and his cronies seemingly do the bidding of monied interests, like finance and real estate, in exchange for hefty contributions. Cuomo outspent Nixon by more than eight-to-one in this election, which is easy to do when your opponent takes no corporate money. He can also apply pressure like nobody’s business: New York’s major unions, for example, endorsed Cuomo. They did so not because their rank and file members necessarily supported him, but because they knew he’d punish them if he won — while Nixon, on the off chance that she won, would not.

Plus the state hardly makes it easy to vote in primaries: It's one of a very few states that forces citizens to declare 11 months in advance their party registration in order to be eligible to vote. And, even if voters clear that hurdle, the New York City Board of Elections is so dysfunctional that even Democratic National Committee unity commission member Nomiki Konst found herself missing from the rolls when she showed up to vote on Thursday. The board admitted in 2017 to illegally purging 117,000 Brooklyn voters, but the reforms it agreed to don’t kick in until 2020. It might not be a conspiracy by the New York Democratic Party to limit the power of non-machine candidates, but, seeing as this dysfunction benefits incumbents, nobody’s been in a rush to fix it.

But despite the hurdles and the losses on the top of the ticket, many progressive challengers did succeed on Thursday. Of the eight members of the Independent Democratic Caucus — Democrats who caucus with the Republicans and swing the balance of power in the State Senate to the right — six were unseated by progressive challengers. (Cuomo claims that he has no connection to the IDC, but sources tell Politico this is false. The understanding is that, with a presidential run in his sights, he feels that the less progressive legislation that ever makes it to his desk, the less he has to anger liberal voters by vetoing it, or centrist donors by signing it.)

A seventh incumbent, Martin Dilan, who is a machine politician cozy with real estate, was unseated by 27-year-old Julia Salazar, an open socialist and member of the Democratic Socialists of America. (I’m an active member of NYC DSA and volunteered for her campaign.) Salazar did this despite weeks of negative national press coverage unusual for a small state legislative race and personal attacks from Dilan.

Like the Ocasio-Cortez win this summer, these victories were driven by small donors and grassroots operations that marshaled volunteers in numbers large enough to make an impact. Considering where progressives are at nationwide, local races are a crucial first step as we build politicians and institutions capable of taking on the establishment at the state and ultimately national levels. As numerous DSA members noted about Nixon's race this summer, the number of volunteer shifts required to make an impact on the gubernatorial race were about ten times what we did for Ocasio-Cortez, and we’re just not there yet. But that doesn’t mean we never will be.

The American left needs to think in the long term: It's only been seven years since Occupy Wall Street brought class politics to the forefront of the conversation and made everyone wonder what the deal is with capitalism. It’s been three years since "democratic socialism" bubbled its way up into the national consciousness with the Bernie Sanders campaign. We’re going to lose most of the time at this point, but that we’ve already won as much as we have should inspire everyone to the left of the Clintons to clear their calendars.

We can debate the finer points of social democracy and democratic socialism once we’ve defeated the reactionary right and neoliberal center.

Of course, it’s going to take more than some good politicians to win the world we deserve: As history has shown, it takes massive direct actions and a large and militant labor movement to create enough pressure for our elected officials to pass even the mildest of social democratic reforms. But it certainly can’t hurt to have people in the halls of power whose message of economic democracy empowers their constituents to ask for more— people who aren’t paid to run for office by the same power players who profit off keeping us hungry, sick and poor. We inched one step closer to that goal last night. Let’s keep our eyes on the prize.