Sometimes, a film arrives at exactly the right time. In Brexitland 2017, that film is The Hatton Garden Job, a nostalgia-rich and semi-fictional crime caper loosely based on the case also known as the Hatton Garden safe-deposit burglary. The turnaround has been quick. You will remember the Easter weekend two years ago, when parties unknown drilled through 18in of concrete under central London to steal £14m worth of gold, cash and jewellery. And how, when arrests were finally made, the movie pitched itself – the principal gang members aged between 60 and 76, The Best Exotic Marigold Hotel with a swag bag.

The gift kept giving. The heist involved no violence, granting the story family-friendliness. Then there was “Basil” – the unknown security expert who remains at large with his share of the proceeds, allowing it a hint of sun-kissed escape. Bingo! Or indeed blingo, as in “the biggest blingo blag in history”, the phrase with which the theft is described on screen by Phil Daniels, a fine actor doomed to be remembered by many as the voice of Blur’s Parklife.

This may not be all. Another version of the same events awaits up the pipeline, a high-end affair from producers Working Title to star – of course – Michael Caine, the script adapted from a piece in Vanity Fair. Elsewhere on the industry spectrum, a third movie already exists – Hatton Garden the Heist, from Terry Lee Coker, writer-director of gangland opus Essex Vendetta. The Hatton Garden Job falls somewhere between the two, made of plyboard but with means enough for Daniels to be joined by Larry Lamb as veteran thief Brian Reader. Fancier yet, the police theory that Basil was younger than his associates is used to justify casting actual movie star Matthew Goode, 38, gamely if erratically dropping his Hs.

Goode brings with him not just his fame, but the memory of his role in Downton Abbey, a link with a counter-intuitive logic. Across generations and classes, his new film is as giddy with the past as anything from the quill of Julian Fellowes. This, it reminds us loudly and often, is a tale of the old school – proper chaps in dowdy East End boozers, observant of the criminal code. One scene takes place at West Ham’s deserted Upton Park, abandoned in the club’s move to the Olympic Stadium, for no reason the script elects to mention. In truth, the east London thing is a stretch. Reader came from Dartford in Kent and his colleagues were from Enfield; their meet-ups were held in an Islington gastropub offering craft ales and a brunch menu. You suppose a detail like that might spoil the salute to tradition restored, the kind of criminals they don’t make any more doing the kind of crime they don’t do – in the words of yet another pending British gangster film, We Still Steal the Old Way. With all that the Old Way implies.

A clue to the mood comes with Goode’s voiceover, clearly written with one eye on the Farage barmy army. The problem with modern life, he tells us, is “the lucky elite”, presumably on nodding terms with the much-despised liberal variety. The term soon crops up again, Hatton Garden itself a “playground for the lucky elite” – office workers buying lunch-hour engagement rings not in picture. The optics of the film can be unfortunate. Among a group of young loudmouths, only the one black kid, Isaac (Sam Adewunmi), ends up in a row with his all-white elders. Eventually, the gang are nabbed by a black cop, played by Sarah Jane Crawford, although in a David Brent-ish touch, she barely gets a line.

The director, Ronnie Thompson, is frank about his relationship to the case behind his movie. “I’m not making a kitchen-sink drama, it’s more entertainment,” he says in the publicity material. “It’s not reality,” he adds, to rule out misunderstanding. “It’s filmic reality.”

In summer 2015, I interviewed Brian Helgeland, the American director of Legend, the slick biopic of the Kray twins with Tom Hardy starring as both Ronnie and Reggie. Surely, with Helgeland, one-time co-writer of LA Confidential, whipping up a shiny cartoon of sharp tailoring and swinging London, this was a film made for the US. A British audience knew this stuff already, right? And would see the approach was silly, even tasteless? I put a mealy-mouthed spin on that to Helgeland. He peered back. “It was definitely made for the UK,” he said. “It’s for you guys.”

He was right. Legend enjoyed a record-breaking opening weekend at the domestic box office, eventually taking £18.4m in the UK. We love a gangster movie here, of course, a chunk of British identity wrapped up in the racing Minis of The Italian Job, James Fox wigging out in Performance, The Long Good Friday’s brilliant premonition of the future London Docklands. But none of these were nostalgic. And in The Hatton Garden Job, their influence comes pre-digested by another film heaving with freeze-frames and Walford Square voiceover – Lock, Stock and Two Smoking Barrels.

Released in 1998 at the dog-end of Britpop, Lock, Stock was a chirpy medley of every British gangster movie before it, the politics and kinks stripped out, a thick coat of ad-agency visuals applied. The masterminds were director Guy Ritchie and producer Matthew Vaughn, well-bred pheasant shooters portraying London as run by a white working-class underworld in a way it hadn’t really been for a generation. The look was pilfered from Martin Scorsese, the tone expertly knockabout. As a formula it made both men millions and sparked a uniquely awful wave of imitators.

Ritchie has since slipped further into a mythic English past, from Sherlock Holmes to the impending King Arthur: Legend of the Sword. Vaughn’s action romp Kingsman strolled down memory lane, too, painting London council estates as crime-ridden hellholes rather than places largely terrorised by buy-to-let landlords. And now, 20 years later, all of us skinter and sadder, The Hatton Garden Job gives us a copy of a copy – two nostalgias for the price of one, a big-screen Sports Direct mega deal.

Facebook Twitter Pinterest Bob Hoskins in The Long Good Friday.

But tempting as it is to blame Ritchie and Vaughn for, well, everything, the process didn’t start with them. In postwar Britain, violent crime was rising. In 1947, motorcyclist Alec de Antiquis was shot dead outside a London jewellers while trying to foil a robbery. A year later, the gangster Jack Spot attempted a raid at Heathrow that ended in a battle of coshes and iron bars. MPs referred to a “vast crimewave”. British film responded with a gritty and popular police drama, The Blue Lamp. But the same writer, TEB Clarke, soon offered a different take on the crime movie. The new film was The Lavender Hill Mob, the Ealing comedy about a bullion heist carried out by a loveable ragbag of crooks and clerks. A wonderful movie, it won the Oscar for best screenplay, and an enduring place in the national self-image. This vision of British crime lodged in our psyche – comical, comforting, non-violent. You know, British. But even then, we were kidding ourselves.

Later, the US would have Scorsese, making gangster movies of high style that also recognised the brutishness of their subjects. Here, the white lie of The Lavender Hill Mob grew into the con of Lock, Stock, so that while the far end of the market was left to gurning tat about Essex vendettas, the mainstream British crime movie became a gift shop snowglobe, filled with old rogues and tiepins, free of social comment or blood on the carpet. Pop it next to the jams, Theresa.

As always, it’s interesting to see what’s not in the script. There is no sign, for instance, in The Hatton Garden Job of the shooting of criminal John “Goldfinger” Palmer, rumoured to be in on Basil’s identity; or of Brian Reader’s involvement in the 1983 Brink’s Mat robbery, after which a police officer was stabbed to death in his presence. Unmentioned too is the man responsible, the infamous Kenneth Noye, a longtime associate now serving life for a road-rage murder, connected in turn to gangster Clifford Norris, whose son David helped kill Stephen Lawrence.

I know. It’s only a movie, mate. Whatever the facts of the case that inspired it, it’s not meant to be real. So what better film could there be for a Britain where nothing is real and facts are for mugs, a nation that just wants to have a laugh and get back to a past we mostly made up. That’s entertainment. The biggest blingo blag in history.