Vivid memories of a violent past protect Portugal from populists
As far-right populism sweeps so much of Europe - though the results of the recent Dutch elections suggest it may already be losing some of its momentum - it can be just as instructive to examine where it has failed to gain a foothold.
While certain ingredients - flailing economies and concerns over immigration - have fed the rise of ultra-nationalist and Eurosceptic movements in various parts of the continent, in other places particular historical contexts have helped to immunise.
Take Portugal, where far-right populism is absent. On a recent visit to Lisbon, Portuguese officials explained how their country had avoided the populist trap partly due to grim - and still vivid - memories of the era of Antonio Oliveira Salazar, Europe's longest-serving dictator.
Salazar's repressive regime, which included secret police notorious for their brutality, lasted for over four decades until he was overthrown in 1974.
Just as Irish people of a certain generation view Ireland's joining of the EU in 1973 as an opening up in so many ways, Portuguese old enough to remember the dark days of Salazar consider securing EU membership in 1986 a key step in their transition from dictatorship.
Portuguese also say their experience of immigration has been different.
Those who have moved to the country from former colonies like Brazil, Angola and Mozambique plus eastern Europe are considered relatively well integrated.
Prime Minister Antonio Costa has boasted he is the first person of Indian origin - his family roots are in Goa, the former Portuguese enclave in India - to lead a European country.
Portugal has offered to host more refugees than had been determined by the EU quota system. The strikingly designed pink minaret of Lisbon's 20-year-old central mosque rises above a central district of the capital, serving a congregation largely drawn from the African diaspora.
Other Portuguese say a careful balance of political dynamics has ensured more radical elements - whether of the right or of the left - are kept in check several years after the country got a bailout when the financial crisis bit hard.
"You can be popular without being populist," says President Marcelo Rebelo de Sousa, who helped write Portugal's constitution in 1976 and was a well-known TV pundit before he was elected last year.
As president, the centre-right Mr Rebelo de Sousa's role is largely ceremonial - his penchant for selfies has become something of a trademark - but his political cohabitation with Socialist prime minister Mr Costa has helped burnish the latter's centrist credentials.
When Mr Costa took office in November 2015, he built a coalition with the far left that raised some eyebrows.
Conservatives labelled the resulting government the 'geringonca', which translates along the lines of an unlikely contraption built of spare parts. Mr Costa's pledges to row back austerity measures while at the same time meeting tough fiscal targets were also met with scepticism.
But in the 16 months since he became prime minister, Mr Costa has defied the expectations of many, both inside and out of Portugal.
According to figures released last month, his government slashed the budget deficit last year by more than half to just under 2.1pc of GDP.
Under Mr Costa, state pensions, wages and working hours have been restored to what they were before Portugal's bailout. The country's economy has experienced an arc of growth for a couple of years now: in the third quarter of 2016 it recorded a faster growth rate than any other EU member state. Unemployment is at a five-year low.
But there are still dark clouds. As the European Commission warned this week, the situation of Portugal's banks remains precarious and public debt continues to rise, making the country more vulnerable than most to any future shocks to the eurozone, such as a possible victory for the far-right Eurosceptic Marine Le Pen in the forthcoming French presidential elections.
One way Portugal seeks to stave off further economic woes is through more foreign investment. Its tourism sector is booming, capturing holidaymakers concerned about security in places like Morocco, Tunisia and Egypt.
The government has also set up a task force to lure investment away from the UK following the Brexit vote, presenting itself as a haven of relative stability in a continent beset by political upheaval.