Joe Crowley, who was considered a possible candidate to replace Nancy Pelosi as Democrat leader, suffers shock defeat.

A 28-year-old activist who worked in the campaign of former presidential candidate Bernie Sanders has overthrown a top House Democrat, Joe Crowley in New York primary elections, an upset, which observers say could force the opposition party to confront their own internal divisions.

Crowley, the Number 4 House Democrat and until Tuesday considered a possible candidate to replace Nancy Pelosi as leader, becomes the first Democratic incumbent to fall this primary season. He was beaten by underfunded challenger Alexandria Ocasio-Cortez, who caught fire with the party’s left wing.

Crowley’s loss echoed across the political world, sending the message that divisions between the Democratic Party’s pragmatic and more liberal wings may be widening heading into the high-stakes November midterm elections.

It also exposed a generational divide among Democrats still struggling with their identity in the era of Republic President Donald Trump.

“The community is ready for a movement of economic and social justice. That is what we tried to deliver,” Ocasio-Cortez said in an interview with the Associated Press news agency.

Born in New York’s Bronx area to a mother from Puerto Rico and a father who died in 2008, she said she knew she could connect with the district, which includes Queens and part of the Bronx.

“I live in this community. I organised in this community. I felt the absence of the incumbent. I knew he didn’t have a strong presence.”

Trump, on social media at least, seemed equally excited about Crowley’s defeat.

“Perhaps he should have been nicer, and more respectful, to his President!” Trump tweeted, oddly taking credit for a victory by a candidate more liberal than Crowley.

He added: “The Democrats are in Turmoil!”

Reason to celebrate

All in all, Trump had reason to celebrate Tuesday night as all three of his endorsed candidates survived primary challenges that could have embarrassed him and the party.

Those included New York Representative Dan Donovan, who defeated convicted felon Michael Grimm in New York City’s only Republican stronghold, and former Republican presidential nominee Mitt Romney, who once branded Trump “a fraud” but has warmed to the president in the past two years.

Yet none of the day’s contests mattered more to Trump than the one in South Carolina, a Republican-leaning southern state.

Governor Henry McMaster, one of the president’s earliest and strongest supporters, survived an unusually tough challenge from a political newcomer, self-made Republican millionaire John Warren.

The White House went all-in for the governor in recent days, dispatching the president and the vice president to the state in an effort to prevent a political debacle.

Trump’s party did just that on Tuesday, though the president has a mixed track record when weighing in on party primaries: His preferred candidates have suffered stinging losses in Alabama and western Pennsylvania in recent months.

Democratic divisions

With the November general election a little more than four months away, more than half the states had selected their candidates after the day’s final votes were counted in seven states across the country.

History suggests that Trump’s Republican Party, like the parties of virtually every first-term president dating back to Ronald Reagan in 1982, will suffer losses this fall.

Yet Crowley’s loss in New York suggests that Democrats must overcome intraparty divisions if they hope to take control of Congress and key governors’ offices nationwide.

“These results are also a shot across the bow of the Democratic establishment in Washington: a young, diverse, and boldly progressive Resistance Movement isn’t waiting to be anointed by the powers that be,” said Matt Blizek, of MoveOn.

Ocasio-Cortez, the winner, cast Crowley as an elitist out of touch with the community.

“This race is about people versus money. We’ve got people, they’ve got money,” Ocasio-Cortez said in biographical web ad that followed her through mundane New York life, dressing for work, walking, changing into high heels on the subway platform.

“Women like me aren’t supposed to run for office.”

Romney defeated little-known state Representative Mike Kennedy in the western state of Utah. He was endorsed by Trump despite his aggressive criticism of the president before his election.

Trump cheered Romney’s win on social media: “I look forward to working together – there is so much good to do. A great and loving family will be coming to DC.”

In Maryland, Ben Jealous, former president of the civil rights group, NAACP, seized the Democratic governor’s nomination. He would become the state’s first African-American governor if he beats Republican incumbent Governor Larry Hogan in November.