Doueiri was briefly detained at Beirut's Rafic Hariri airport late Sunday and his passports confiscated after arriving in Lebanon to promote a new movie that received critical acclaim at the Venice Film Festival recently. Following his release, Doueiri's lawyer reportedly told media assembled outside the court that Doueiri had been freed following several hours of investigation and given back his travel documents.
At issue was the earlier film, The Attack, which was released in 2012. The Attack, about a suicide bombing in the Israeli city of Tel Aviv, was filmed in part in Israel and banned in Lebanon.
In a statement to the French news agency before his appearance in court, Doueiri said, "I am profoundly hurt. I came back to Lebanon with a prize from Venice. The Lebanese police have authorized the broadcast of my film (The Insult). I have no idea who is responsible for what has happened."
Doueiri had flown from the Venice Film Festival, where The Insult, his fourth film, had won the Coppa Volpi best actor prize for Palestinian actor Kamel El Basha. The Insult is set in Beirut and focuses on the escalation of a minor argument between a Palestinian refugee and a Lebanese Christian.
Doueiri was offered the support of Lebanon's culture minister, Ghattas Khoury, following the brief detention. "Ziad Doueiri is a great Lebanese director and that has been honored across the world," Khoury tweeted, before adding, "Respecting and honoring him is a duty."
Doueiri, however, angered many Lebanese when the earlier movie, The Attack, was released.
According to Ayman Mhanna, director of Lebanon-based free speech NGO SKeyes, Doueiri's appearance in court was symptomatic of an unpredictable approach within the government regarding the director's time in Israel.
Although Mhanna "did not question" the laws preventing Lebanese visits to Israel, he told VOA that Doueiri had visited Lebanon numerous times without repercussion.
The government's response was "chaotic" and "destabilizing," he added, with one part of it endorsing Doueiri and another seeking to detain him. Mhanna noted that the Ministry of Culture recently backed Doueiri's latest film, The Insult, to represent Lebanon in the foreign film category at next year's Academy Awards in the United States.
Meanwhile, the trying of civilians in military courts has also attracted criticism.
A report by Human Rights Watch earlier this year highlighted the use of such courts to try civilians involved in protests against the Lebanese government's handling of the country's waste crisis.
Bassam Khawaja, of Human Rights Watch, told VOA, "Regardless of detentions being brought, Doueiri should not be tried in a military court.
"Unfortunately military courts are still used in Lebanon to try civilians on a broad range of charges, in violation of their due process rights and international law.
"These trials largely take place behind closed doors, with limited grounds for appeal, and it is difficult to see how he would get a fair trial there."
There is a a long history of perceived moments of Israeli acknowledgment or collaboration drawing swift rebuke in Lebanon, which was first invaded by its southern neighbor in 1978.
In May, global box office hit Wonder Woman was barred from Lebanese theaters because it starred former Israeli army soldier Gal Gadot. Last month, Swedish-Lebanese dual citizen Amanda Hanna was stripped of her title Miss Lebanon Emigrant after those behind the event discovered she had visited Israel using her Swedish passport in 2016.
Doueiri is one of the most acclaimed Lebanese directors of his generation. He first made a name for himself with Lebanese civil war classic West Beirut, which was released in 1998.
He began his career as first camera assistant for Quentin Tarantino on the director's films Reservoir Dogs, Pulp Fiction, and Jackie Brown.