Five days later, after she had weathered rounds of punishing criticism, the responses were reversed, with 46 percent saying she should stay and 34 percent that she should go. A bungled coup by hard-line Brexiteers in her own party — who want a more complete break from the European Union than she has proposed — had left her most aggressive detractors looking isolated and foolish.

And many in Westminster began speaking confidently of a new wrinkle. Mrs. May might not muster enough Parliamentary support to pass the bill in mid-December, according to Rob Ford, a professor of politics at the University of Manchester. But if her government survives long enough to put it to a second vote, he said, she has a good chance of getting it through.

“The groups that dislike it will realize that there is no way of getting their preferred outcome,” he said. “The deal could be as popular as leprosy with the public and that strategic calculus would not have changed one iota.”

Leprosy indeed. Remainers don’t like it because they did not want to leave the European Union in the first place. Hard-line Brexiteers don’t like it because it leaves Britain in too many European structures. Soft Brexiteers — who want, well, a softer break — don’t like it because it removes the country from too many structures. The only people who are satisfied are those primarily concerned with immigration, and polls, Mr. Ford said, suggest that group is rapidly shrinking.

Even the Daily Mail newspaper, which, under its former editor, Paul Dacre, pushed Brexit with unbridled ferocity and policed the political class for the slightest hint of apostasy, has softened under Mr. Dacre’s successor, Geordie Greig, offering lukewarm support for the prime minister.

It was difficult to recall, in the gloom and resignation of this week, that Brexit had at one point made some people happy.