Image caption Michael Palin's last major role in a TV drama was in 1991's GBH on Channel 4

A new BBC Two drama set on the battlefields of World War I will see Michael Palin in his first on-screen TV acting role in more than two decades.

Written by Ian Hislop and Nick Newman, The Wipers Times is based on the true story of a satirical newspaper produced by soldiers in the trenches.

Alongside Palin, the cast includes Ben Chaplin, Julian Rhind-Tutt, Steve Oram and Emilia Fox.

The Monty Python star is now best known on TV for his travel series.

Palin's last TV drama role was in Alan Bleasdale's GBH in 1991, in which he played a school headmaster intimidated by a newly-elected city council leader, played by Robert Lindsay.

Palin said in a Bafta interview earlier this year that he considered the role one of his career highlights.

Image caption Kate (Emilia Fox) and Roberts (Ben Chaplin) in The Wipers Times

In its official announcement on Tuesday, the BBC described The Wipers Times as "a story of the extraordinary resilience of the human spirit in the face of overwhelming adversity".

Ben Chaplin plays Captain Fred Roberts, who discovers a printing press in the bombed-out ruins of Belgian town Ypres in 1916 and uses it to publish The Wipers Times (named after the army slang for Ypres).

The paper's subversive humour proves popular with soldiers on the front line but goes down less well with their superior officers.

"Just like the original Wipers Times, this new history drama will be filled with jokes, spoofs and amazing examples of courage behind the laughs," said Janice Hadlow, controller of BBC Two.

As the war continued, the paper changed its name as the soldiers from the 12th Battalion Sherwood Foresters - who produced it - changed location. Its other titles included The Somme Times and, after the Armistice, The Better Times.

Private Eye editor Ian Hislop and writing partner Nick Newman's other projects include BBC children's sitcom My Dad's the Prime Minister.

The drama will be shown on BBC Two later this year.