WHATEVER smug feelings Hillary Clinton and her team enjoyed over the gaffe-strewn Republican National Convention in Cleveland last week died quickly, on July 25th, in Philadelphia. The Democratic Party, which is holding its convention there for four days, ending on July 28th, has serious problems of its own. Most obvious is the refusal of a raucous minority of Democrats to accept Mrs Clinton as their nominee. Philly has already seen protests far bigger than anything witnessed in Cleveland; the police said they expected as many as 50,000 protesters in all. On a sweltering first day, marked by thunder claps and torrential rain, packs of disgruntled supporters of Mrs Clinton’s beaten rival, Senator Bernie Sanders, traipsed through Philadelphia, alongside anti-capitalists, anarchists, and a group of pro-cannabis campaigners parading a 30-foot-long inflatable spliff.

“Fuck the DNC! We’ll never bend the knee!” chanted a group of Sandernistas. They were maddened by revelations, detailed in e-mails published by WikiLeaks on July 24th, that some officers of the Democratic National Committee had displayed a naked preference for Mrs Clinton over their man during the primaries.

The revelations, allegedly engineered by Russian hackers, conceivably with the aim of boosting Mrs Clinton’s Republican rival, Donald Trump, had already claimed an important scalp. On the eve of the convention, Debbie Wasserman Schultz, a congresswoman from Florida, announced that she would step aside as the DNC’s chairwoman after the convention. Yet Mr Sanders’s incensed supporters were not placated by this. When Ms Wasserman Schultz appeared at a breakfast for delegates from Florida she was loudly jeered. It was swiftly announced that she would take no public role in the convention.

Her temporary replacement as chairman of the DNC, Donna Brazile, issued an apology to Mr Sanders’s over the WikiLeaks revelations: “On behalf of everyone at the DNC, we want to offer a deep and sincere apology to Senator Sanders, his supporters and the entire Democratic Party for the inexcusable remarks made over e-mail.” But Mr Sanders’s delegates, who had been primed by the senator to continue fighting for the nomination long after Mrs Clinton appeared to have beaten him, were anything but mollified.

At a midday meeting with the nearly 1,900 delegates he won in the primaries, Mr Sanders urged them to back Mrs Clinton in November against Donald Trump. Some of his supporters booed; others began chanting, “Bernie, Bernie”. Mrs Sander’s wife Jane was reduced to tears, according to a delegate from Indiana who was standing next to her, as it became clear that Mr Sanders could not control his supporters. “Brothers and sisters!” he implored them, raising his right hand, “This is the real world we live in.”

To hear Mr Sanders’s fans list their gripes, as they roamed the corridors of the Wells Fargo Arena, wearing “Feel the Bern” badges and the Robin Hood hats that have some have adopted as a uniform, that is open to dispute. “This is a contested convention,” said Susie Talevski, a Sanders delegate from Indiana—though it really isn’t, Mrs Clinton having won over 2,800 delegates, around 400 more than she needed for the nomination. “We are fighting every step of the way for Bernie to be the nominee.”

As the convention got under way, boos rang out at any mention of Mrs Clinton’s name. The fact that the rowdiest pro-Sanders’ supporters, in the California and Oklahoma delegations, were sitting close to a bank of television cameras probably exaggerated the size of their protest. Yet it looked at one stage to involve at least a couple of hundred delegates. A comical interlude, by Senator Al Franken, a former comedian, and Sarah Silverman, an actor and Sanders supporter who is now backing Mrs Clinton, threatened to deteriorate into a chaos of shouted Bernie chants. Ms Silverman paused to address the holdouts directly: “Can I just say, to the Bernie-or-bust people: you’re being ridiculous?”

Things quietened down a bit thereafter—mainly because the comics were followed by Michelle Obama, who is too revered by Democrats for almost anyone to dare interrupt. She gave an uplifting speech, connecting Mrs Clinton, as the first female nominee of either major party, to the overarching progress of justice and equality that her husband’s election also represented.

“I wake up every morning in a house that was built by slaves,” said Mrs Obama, in a speech punctuated only by thunderous applause. “And I watch my daughters, two beautiful, intelligent black young women playing with their dogs on the White House lawn. And because of Hillary Clinton, my daughters and all our sons and daughters now take for granted that a woman can be president of the United States.” It was a more elegant argument for Mrs Clinton’s election to the presidency than she herself has managed in over a year of campaigning.

The Sanders diehards were by no means done, however. As Elizabeth Warren, a senator from Massachusetts, with similarly left-wing populist views to their champion, took the stage, a chorus of, “We trusted you!” rang out. Mrs Warren’s decision to endorse Mrs Clinton last month, after the former secretary of state’s lead over Mr Sanders became unassailable, had laid the ground for Mr Sanders’s own, rather begrudging, endorsement of his rival.

When Mr Sanders himself followed Mrs Warren, to give the last speech of the night, he was greeted by deafening cheers that lasted for three minutes. Mrs Clinton will nonetheless have been somewhat reassured by the speech that followed. Its early sections contained many of the promises, of wealth redistribution and a political revolution, contained in Mr Sanders’s stump speech; it did not sound at all like an endorsement or surrender speech. Yet Mr Sanders’s got there in the end. He warmly praised Mrs Clinton’s adoption of one or two of his pledges, including a hike in the federal minimum wage to $15, then counted the ways, for the environment, the economy, the composition of the Supreme Court, in which she would serve liberals as president better than would Mr Trump.

There will be more rowdiness and dissent yet—including during the formal tallying of delegates, which some Sanders supporters see as a last opportunity to make their stand, due on July 26th. Yet such displays of disunity are not the Democrats’ biggest problem. In fact, they may not be much of a problem at all. Polls suggest regular Democratic voters are much less divided than the party’s delegates are; nine in 10 Democratic primary voters say they will back Mrs Clinton. A much trickier problem for the party, and, given her opponent, also for America, is Mrs Clinton’s weakness as a candidate. Mr Sanders’s unpredicted insurgency was to some degree a testament to that.

As Mrs Clinton prepares to accept her party’s nomination, her ratings have never been lower. According to a poll for CNN, only 30% of Americans say she is honest. By comparison, 43% say that of Mr Trump, though his campaign pronouncements have been so packed with falsehoods—concerning the state of the economy, his record, you name it—as to make a mockery of the notion of rectitude in public life.

Her perceived shadiness goes a long way to explaining why Mrs Clinton is currently trailing Mr Trump—the most divisive presidential candidate of recent decades—in the polls. A poll released on July 26th showed Mr Trump three percentage points ahead of Mrs Clinton; another showed him in a dead heat with her on 42%.

That is a remarkable achievement for a Republican candidate who has insulted many parts of American society (women, Hispanics, the disabled…), is disapproved of by most Republican officials, and whose campaign is undermanned, underfunded and based on little in the way of coherent policy. It is also a dreadful indictment of Mrs Clinton’s performance.

Democrats will find, amid their internal dramas, plenty of reason for cheer in the coming days, including speeches from Barack Obama and Bill Clinton. Compared to the shallow circus that Mr Trump produced in Cleveland, which was shunned by most Republican heavyweights, their convention appears packed with charismatic, popular speakers. But Mrs Clinton is not one of them and, her wretched polls suggest, if she is to win the White House, she will have to win it herself.

A veteran of three decades in the front-rank of Democratic politics, she needs a breakout moment of her own in this convention. Her party, contrary to appearances, is unified enough. Her task, in what will be one of her last good opportunities to appeal to Americans on terms of her choosing, is to somehow raise herself in their estimation. It is not obvious how she will manage that.