D ONALD TRUMP’S tendency to judge others by his own standards often leads his diplomacy astray. Witness his dire relationship with Angela Merkel. Yet in his appraisal of Pakistan’s “lies & deceit”, the president was spot-on. “The United States has foolishly given Pakistan more than 33 billion dollars in aid…They give safe haven to the terrorists we hunt in Afghanistan…!” he fulminated, in his first tweet of 2018.

America has been played for a fool by the generals who call the shots in Pakistan, either overtly or from behind a pliant civilian—such as the incumbent prime minister, Imran Khan. Forced by the events of 9/11 to stop supporting the Taliban openly, and to provide America with a land route to Afghanistan, the generals have since bagged billions in American aid. They have meanwhile given at best limited help in rooting out the Taliban and other jihadist leaders who fled across their border. They protest that they have rival security concerns. Over 30,000 Pakistanis have been killed in violence unleashed by extremists in response to the army’s sporadic efforts against them. Nonetheless, the fact that a lavishly rewarded “major non- NATO ally”—a status Pakistan shares with Australia, Israel and Japan—has consistently undermined America in its longest-ever war is outrageous. Mr Trump’s decision to suspend $2bn in military aid to Pakistan, among other punitive measures, could not have been more richly deserved. Yet it has achieved nothing.

The Pakistanis have not been moved to restrain the Taliban, whose leaders are directing an insurgency from Karachi and Quetta that has overrun half of Afghanistan. Nor have they responded to the administration’s other demands, which include releasing a Pakistani doctor, Shakil Afridi, imprisoned for helping America trace Osama bin Laden. Not even after the Trump administration hit the generals where it really hurts—by cutting back on the training junkets to America that Pakistani army officers and their wives adore—have they moved an inch. Wearily then, and as inevitably in the course of America-Pakistan relations as night follows day, the administration switched this week to a more conciliatory tack.

Mr Trump sent a friendly letter to Mr Khan to accompany a visit to Islamabad by Zalmay Khalilzad, an American diplomat charged with starting negotiations to end the war in Afghanistan. According to the Pakistanis, it suggested the countries find a way to “renew [their] partnership”. Mr Trump wants Mr Khan to persuade the Taliban, whose representatives Mr Khalilzad has already met in Doha, to come to the peace table. Given that the president is itching to withdraw the remaining 14,000 US troops from Afghanistan, and wants a deal with the Taliban to cover that retreat, nothing America has hitherto demanded of Pakistan may matter more.

The administration’s move is well-timed. To avert a balance-of-payments crisis, Pakistan has asked the IMF for its umpteenth bail-out, which gives Mr Trump leverage. Mike Pompeo, the secretary of state, has suggested America could block the bail-out. Mr Khan, in a way, looks like another opportunity. The generals have long warned America not to squeeze them hard for fear of inciting an anti-American blowback and the rise of a Taliban-style leader. Yet Mr Khan, a former star cricketer who has embraced Islam and every conspiracy theory that comes his way, is as extremist and anti-American a leader as Pakistan is likely to get. Over lunch with him, Lexington once listened as Mr Khan tried to convince another cricketing legend (the Antiguan genius Sir Vivian Richards) that America was “destroying” Pakistan and the 9/11 attacks were some sort of a put-up job. He is not an ally Mr Trump need cosset. He is also, despite his image as a man of principle, an opportunist. If Mr Khalilzad can persuade him it would be in his interest to order the Taliban to negotiate, he will do so.

But he and the generals probably do not think it is in their interest. A peace settlement would strengthen the government in Kabul, which is backed by India. Alternatively, a hasty American withdrawal and victory for the Taliban would probably lead to the break-up of Afghanistan and more trouble along Pakistan’s north-west frontier. The current stalemate suits Pakistan better. Moreover, if Mr Khan did summon the Taliban leaders to negotiate, they might refuse, which would be embarrassing.

A more expansive view of Pakistan reveals the insanity of this. Servitude to its generals and their strategic obsessions has produced a weak democracy, abysmal governance and an economic performance that makes Bangladesh—once one of Pakistan’s poorest parts—look like an Asian Tiger. The post-9/11 catastrophe Pakistan’s leaders should be grappling with is not a pro-India government in Kabul, but their inability to address the basic needs of a population that has grown by 50m in that time. But they do not think this way. And the tragedy for the Trump administration, because it reflects a broader collision with global reality that is fast approaching, is there may not be much it can do about that.

Over and out

On Pakistan, as on Afghanistan, China, Iran and North Korea, Mr Trump saw a big foreign-policy problem that was not moving America’s way. His error was to assume this was mainly due to a lack of American will. Despite a lot of heated rhetoric, his foreign policy has been more realistic. On Pakistan and otherwise, he has been more belligerent than Barack Obama was, but perhaps no more than Hillary Clinton would have been. Only Mr Trump’s trade policies have been far outside normal bounds. Yet the hot rhetoric persists, and so long as the world resists Mr Trump’s injunctions, the question is whether rhetoric will turn into action.

On Pakistan, that would mean not war, but disengagement. America has already tried that, in the 1990s, after the cold war ended. The result was nuclear-arms proliferation, a threatened Indo-Pakistan nuclear war, and the rise of the Taliban. Pakistan, as Mr Trump has observed, is just about the worst American ally imaginable. That is why America has little choice but to persist with it.