How can a nation that – once independent – pledges to be progressive, small and European reconcile those values with the blatant, entrenched racism against the Irish and Catholic?

It all happened very quickly. On the 29th of August, three Rangers fans were arrested for singing sectarian songs; on the 2nd of September, Nicola Sturgeon said to the Scottish Parliament that she takes “the view that anybody who chooses to live in Scotland… this is their home”.

It was a clever sentence: it simultaneously condemned anti-Irish racism and neatly invoked the idea of an independent Scotland acting as a small, European and forward-facing nation. And thanks to Tess White’s fatuous “unless you’re English” retort, the real issue at hand was swept under the carpet.

But anti-Irish and anti-Catholic racism in Scotland is a pernicious and deep-set threat to Scottish independence. How can a nation that – once independent – pledges to be progressive, small and European reconcile those values with the blatant, entrenched racism against the Irish and Catholic?

Despite narratives protesting otherwise, Scotland has an ugly and stubborn history of religious intolerance and discrimination. Nowhere is this clearer than with the Irish. Irish immigration to Scotland peaked in the years after the Great Famine of the 1840s, a flight from hunger and hopelessness.

By 1851, 7.2 per cent of the Scottish population was Irish, compared with only 2.9 per cent in England and Wales. This rate of immigration kept up until the eve of the First World War. Today, 14 per cent of the Scottish population describe themselves as Roman Catholic, compared with only 9.6 per cent in England and Wales. This is a direct result of the higher levels of Irish immigration to Scotland.

However, the picture isn’t quite as clear as it may seem. Hordes of starving southern Irish immigrants flocking to Glasgow is a mostly a myth. Most of the Irish immigrants of that time actually came from Ulster (the traditional province in the north of the island of Ireland), and between a quarter and a fifth of them were Ulster Protestants.

What this meant was that the tribal hatreds of Ulster were passed over to the west coast of Scotland, particularly in the industrialised regions such as Glasgow. Therefore, it would seem that the anti-Catholic, anti-Irish prejudice is an import from Ulster, not a native product.

But not quite. Ulster Protestantism is an offspring of the Presbyterian Scots who’d dispossessed native Irish Catholics in the seventeenth century Ulster Plantations, the colonisation of Ulster. And so, when Orangeism and Ulster Protestantism were imported back into Scotland following the Great Famine, it made common cause with the fervently anti-Papist Scottish Calvinism – its long-lost father.

Every so often, some newspaper in Scotland or an MSP claims that sectarian bigotry is dead. And yet, what may seem like ancient history has a very real present. In 1999, Donald Findlay – a prominent lawyer and Rector of the University of St Andrews – was taped singing the bloodthirsty Orange anthem ‘The Sash’.

That same night at an Old Firm game a Celtic fan had his throat slashed and another was shot by a crossbow bolt. And then there’s the incident I’m referring to: Rangers fans singing the Famine Song, with lyrics like “From Ireland they came, brought us nothing but trouble and shame. Well, the famine is over, why don’t they go home?”

It’s perhaps worth rehashing that the Irish famine led to the deaths of about a million people.

The fault line of anti-Irish prejudice runs deep in Scotland. And its threat to the cause of Scottish independence is a very real one. How would a new Scotland, with its history of religious intolerance, welcome newcomers? How can a tolerant, progressive society emerge with such entrenched prejudice?

I’d argue that there needs to be a careful look at the history of Scotland again. At the moment, it’s presented as if the Scottish people were always a homogenised and coherent body, which accepts immigrants such as the Irish and, later, the Italians. But Scottish identity has never been simple or single.

The forgotten histories of the Dalriadic kingdom – which spanned over the north of Ireland and the west coast of Scotland and Ireland – the Picts in the north and east of Scotland, the Votadini in modern Edinburgh, and their interactions with the Angles, the Saxons and the Jutes need to be reworked into the popular Scottish consensus.

Scottish nationalism presents itself as an intelligent, thoughtful movement – especially in comparison to its coarse English cousin. Over time, the intellectuals of Scottish nationalism have asked themselves about when Scotland was truly Scotland. Was it during the Scottish Enlightenment? At Culloden, with Bonnie Prince Charlie and the Jacobites?

At the moment, it seems centred on King Robert I ‘The Bruce’. This question: ‘When was Scotland?’ needs to be asked again. It needs to tell the story of how Scottish identity is complicated and nuanced. It’s the only way of building the more ethnically tolerant and progressive society that an independent Scotland dreams of.