The notorious far-right mayor of Béziers, Robert Ménard, thought he had found the perfect solution for his town's dog poo problem.
The plan: Simply collect all the pet dogs' DNA so that excrement left lying around Béziers could be quickly traced back to the owners.
These owners would receive a letter with a €38 fine in the mail, presumably without the offending dog poo (although you wouldn't put it past Ménard).
And while we can all empathize with the desire for pavements free of dog poo, the administrative court of nearby Montpellier said on Wednesday that DNA tests weren't the way to do it.
The judge decided that the measure was "not intended to keep the public safe nor to prevent offence, but was purely repressive".
The court suspended the order from the mayor that he had launched in early June.
Opponents to the DNA system included the deputy prefect of Béziers, Christian Pouget.
"The moment you make dog owners declare in a file that they're just taking their pet for a walk then it becomes disproportionate," he said.
"And just because you're taking a dog for a walk doesn't mean you're not respecting health rules."
For his part, Mayor Ménard said his idea was "a measure of common sense".
"Local residents are in favour of the idea, because it would make the city cleaner and save money," he told France Bleu.
Menard made headlines last year for a "witch hunt" of refugees in his town and for also saying he would ban more kebab restaurants from opening.
Dog poo on the streets of France has long been a hotly contested topic, and there has been no shortage of creative ideas to stop the scourge.
The most recent includes a 2.000-strong "anti-incivility brigade" that hit the streets of Paris on Monday to crack down on dog owners leaving a mess, as well as cigarette tossers and public pee-ers.
In June this year, a Frenchman told The Local about his new smartphone app that maps out dog poo across the city for street cleaners to find.
Back in 2014, security guards armed with fluorescent paint took to "pink-bombing" piles of poo left behind by unscrupulous dog owners in the north western town of Arras.