The Democratic primary battle for Pittsburgh mayor, between incumbent Mayor Ed Gainey and Allegheny County Controller Corey O’Connor, looks to be yet another Western Pennsylvania-centered test case on the strength of the state’s progressive movement.

Gainey, a progressive Democrat , has stumbled throughout his term and is widely seen as an under­performing official. Meanwhile, O’Connor is another son of a well-known Democratic officeholder — his father was city council president and briefly served as mayor until his death in 2006. He is perceived as less progressive than Gainey, though there’s a competency angle here, too, that the controller will emphasize.

A recent internal poll from Team O’Connor, recently leaked to Axios, showed the challenger up 12 points over the incumbent, 47% to 35%. There are details on whether this ballot test question was the initial ballot — meaning it was the first such question asked in the poll — or an informed ballot test (asked after voters had been given information about the candidates).

We’ve seen this story play out before in Western Pennsylvania. As I wrote in RealClearPennsylvania shortly after the 2023 primary, “The most high-profile progressive candidate on the ballot Tuesday was a Pittsburgh state representative, Sara Innamorato. She vanquished three well-known and financed men in Allegheny County’s Democratic primary for county executive — including County Treasurer John Weinstein and City Controller Michael Lamb.”

Super-liberal Innamorato, a Democratic Socialist, faced a stiff challenge that year from moderate Republican Joe Rockey in the general election for county executive. But in this mayor’s race, it’s clear that if there is to be change in the city, it’ll need to take place in the Democratic primary.

This fight with the local Democratic Party has been playing out since 2018. The city’s member of the Squad, U.S. Rep. Summer Lee, usually finds herself facing a primary challenge from a less liberal Democrat. And over the past six years, several old-timey, relatively moderate Democratic state House members in and around the city have been vanquished in the primary by more liberal members of their own party (a la Dom Costa, etc.).

So is it déjà vu all over again in Allegheny County? This primary is the first big race for Democrats since their statewide shellacking in last year’s general election, where the GOP went 5 for 5: Trump, McCormick for Senate, Garrity for treasurer, DeFoor for auditor general and Sunday for attorney general.

Unlike most challengers, O’Connor has more dollars than his opponent and holds comparable overall name ID. And big outside money is lining up to take down Gainey in the primary, some of it Republican, as the Guardian notes.

In a sure sign of discontent within the county Democratic committee, O’Connor snatched the county Democratic endorsement away from Gainey by just four votes.

Does that ripple spread throughout the city’s Democratic establishment? Well, neither City Controller Rachael Heisler nor Senate Democratic Leader Jay Costa are publicly taking sides in the primary.

Look for this to be a very busy primary race, with significant amounts of outside money coming into play, in addition to what the candidates have themselves. Given these recent poll numbers, his less than stellar fundraising and the county party deserting him, Gainey’s in for a tough race.