A French far-Left politician has been arrested for apparently celebrating the death of a gendarme hailed as a hero for offering himself in place of a hostage taken by an Islamist gunman.

Stéphane Poussier was detained after tweets posted from his account said: “Every time a gendarme gets whacked… I think of my friend Rémi Fraisse,” an environmental protester who died after police threw a concussion grenade during demonstrations in 2014.

“And this time it was a colonel, great! It also means one less vote for (President Emmanuel) Macron,” said the tweet, which was quickly deleted and the Twitter account closed after it sparked an outcry.

Lieutenant Colonel Arnaud Beltrame was shot and stabbed after taking the place of a woman whom Radouane Lakdim, who had already killed three people, was using as a human shield during his attack on Friday at a supermarket in Trebes in southwestern France.