By David Ignatius Opinion writer October 25  – When the United States fights its wars in the Middle East, it has a nasty habit of recruiting local forces as proxies and then jettisoning them when the going gets tough or regional politics intervene.

This pattern of “seduction and abandonment” is one of our least endearing characteristics. It’s one reason the United States is mistrusted in the Middle East. We don’t stick by the people who take risks on our behalf in Iraq, Egypt, Lebanon and elsewhere. And now, I fear, this syndrome is happening again in Syria, as a Kurdish militia group known as the YPG, which has been the United States’ best ally against the Islamic State, gets pounded by the Turkish military.

The YPG is a special case for me because I had a chance to meet some of their fighters in May at a secret U.S. Special Operations forces training camp in northern Syria. They described battling to the last man — and sometimes woman — as they drove the Islamic State from its strongholds. Special Ops officers embedded with the YPG recounted their battlefield exploits with deep respect, expressing what one called “the brotherhood of the close fight.”

Unfortunately, allying with the United States can be a dangerous proposition in the Middle East. Last Thursday, Turkey said its warplanes shot 18 targets in YPG-controlled areas of northern Syria. The Turks want to block the YPG from linking up with its fighters in a pocket known as Afrin, northwest of Aleppo. The Turks also want to prevent the YPG from playing a leading role in the liberation of Raqqa, the Islamic State’s capital, as the United States had planned.

“If it doesn’t stop, it could preempt all plans for Raqqa,” warns a Pentagon official about the Turkish onslaught. Kurdish sources tell me that because the United States isn’t responding to pleas about Afrin, the YPG is appealing to Russia.

The U.S. alliance with the YPG was forged during the liberation of Kobane from the Islamic State in late 2014. The Kurds were down to a few hundred fighters when U.S. Special Operations forces intervened. The assistance was brokered by Lahur Talabani, the intelligence chief of the Patriotic Union of Kurdistan, or PUK. He sent several of his operatives into Kobane with GPS devices to call in U.S. close air support, via an operations center in the PUK’s headquarters in Sulaymaniyah, Iraq.

“It was the right thing to do,” Talabani told me Tuesday in an interview in Washington. He explained that the YPG’s success against the Islamic State has saved Kurdish lives in Syria and taken pressure off Kurdish forces in Iraq, who are now fighting to liberate Mosul from the extremists.

The Obama administration embraced the YPG because the Kobane victory was the first major battlefield success against the Islamic State. At last, the United States had a partner that could fight. But this alliance was built atop an ethnic fault line. That ruptured in August, when a YPG-dominated force captured Manbij, just south of the Turkish border. A few weeks later, the Turks invaded Syria and began their barrage against YPG targets.

The United States has tried, unsuccessfully, to finesse the Turkish-Kurdish animosity. Before the Manbij offensive began in May, the United States brought to Incirlik Air Base in Turkey a delegation from the Syrian Democratic Forces, a coalition that nominally oversees the YPG. But this effort to paper over Turkish-Kurdish differences crumpled after the attempted coup in Turkey in July. Some of the Turkish generals who met the SDF are now said to be in prison as coup suspects.

Turkey’s regional ambitions have swollen as President Recep Tayyip Erdogan consolidated power after the coup attempt. Even as Turkish forces harass the YPG and consolidate a border strip in Syria, they’re also advancing in Iraq, seeking a role in the liberation of Mosul despite warnings from Iraq and the United States to stay out. Erdogan speaks of Aleppo and Mosul as former Ottoman regional capitals.

“One wild card is how to manage the role of Turkey in both theaters,” says a senior U.S. official. Maybe the Kurds should have known better than to ally with the United States, or to trust Turkey to stay out. Kurdish history is a story of betrayal. Fortunately for the United States, some goodwill remains from “Operation Provide Comfort,” the no-fly zone over northern Iraq that the United States imposed after the 1991 Gulf War, which helped create a thriving Kurdish regional government in Iraq.

But people in the Middle East have learned to be wary of American promises. One Iraqi Christian leader recently rejected the suggestion of new American help, post-Islamic State. “You’ll walk away,” said the priest. “That’s what you do.”

Read more from David Ignatius’s archive, follow him on Twitter or subscribe to his updates on Facebook.