Division in a political party can be a blessing or a curse. And sometimes, it can be both.

In the Democratic Party's struggle to retake the House of Representatives in November 2018, division is a very good thing indeed. But whether it will remain so as the party tries to defeat President Trump's presumed bid for re-election in 2020 is another matter entirely.

First, the good news for Dems: Less than six months out from the midterm elections, lack of consensus about the future direction of the party allows the Democrats to adapt to regional and ideological differences in the electorate. So, in a liberal, wealthy suburb that is appalled by President Trump, a progressive congressional candidate who describes herself as a leader of the "resistance" against incipient authoritarianism might be the perfect Democrat. Meanwhile, in a swing district in the Midwest that has a history of voting Democratic but sided with Trump in 2016, a candidate who combines an economically populist message with a more moderate one on cultural issues (guns, abortion, transgender rights) might be the perfect fit.

That's exactly what we've seen in a series of special elections in which the Democratic candidate has prevailed. As The New York Times notes, these moderates tend to ignore Trump, distance themselves from House Minority Leader Nancy Pelosi, downplay cultural and social issues, and lead with a message about economic decline and the burden of health-care costs (while denying that instituting a single-payer system is a viable option).

Conor Lamb narrowly won a special election in western Pennsylvania with a message like this. The approach was perfectly tailored to voters in his district, who had gone for Trump by 20 points. It's an electoral strategy that's being emulated in similar districts around the country, from Arkansas to New Jersey and California, while candidates in more solidly progressive areas run on a less ambivalently liberal message.

That's the distinctive strength of a diverse party, shape-shifting to meet the demands and expectations of voters in different regions of a big country filled with dissension and disagreement. And it will very likely deliver Democrats the net gain of 23 seats that they need to seize control of the House this fall.

But that flexibility comes with its own problems, too.

For the party's activist base, more energized than at perhaps any time since the early 1970s, it's a source of frustration. As the Times explains, these more consistently progressive voters worry that the election of more centrist candidates could impede efforts to pass sweeping left-leaning legislation if they take narrow control of the House. (It could also make it more difficult to impeach the president.)

This conflict is playing out in an especially rancorous way in Minnesota, where Politico reports that the sons of the late progressive Democrat Sen. Paul Wellstone have been ousted from the governing board of Wellstone Action, an influential training group that was founded after their father's death. The reason for their ouster? Activists within the organization opposed the ambitions of the brothers to try and win back the votes of the mostly white rural and working-class Minnesotans who cast ballots for Trump in 2016. (Trump came within 1.5 percentage points of carrying the state. If he had done so, that would have made Minnesota the fourth state in the Democrats' famed "blue wall" to flip to the Republicans, after Pennsylvania, Michigan, and Wisconsin.)

Instead of fighting to bring these one-time Trump voters back to the party, the Democratic activists at Wellstone Action would rather have the party rely more heavily on consistently progressive urban and suburban voters, whom they hope to rally in full-throated appeals to "communities of color and the LGBTQI community."

Whether this makes sense in the context of the Minnesota electorate will become clearer over the next few election cycles. But however that specific feud gets settled, the underlying conflict is bound to boil over in the country as a whole as the party heads into the 2020 presidential contest. And this could be disastrous for Democratic efforts to make Trump a one-term president.

It's one thing for a party to take advantage of its disagreements to strategically splinter at the local and state level in a midterm election. That's a variation on the classic military strategy of dividing and conquering one's opponents. But a party heading into a nationwide vote has no choice but to take a different approach. A presidential nomination contest can only have one victor. During the 2020 Democratic primaries the party will need to decide which person and which agenda will represent the party as a whole.

Will it be an economic populist who aims to woo back some wayward Trump voters? Or will it be a culture warrior from the left who's convinced that those who were seduced by the Republican in 2016 have no place in a tolerant, multicultural Democratic Party? Will it be a candidate who forges solidarity across ethnic, racial, and gender lines? Or one who works to mobilize minority groups while subtly (or perhaps not so subtly) conveying the message that certain other groups (especially white, rural, and working-class voters) are not welcome?

Such tensions will be exceedingly difficult to paper over as Democrats try to decide on their standard-bearer. That's when the party's divisions — a source of great strength in the midterms — could well become the source of its greatest vulnerability.