Keeping a mobile phone with a pre-dialled number close-by, organising an emergency escape route from the surgery and installing a panic button attached to a monitored alarm system were just three suggestions officers made.

Documents – seen by the Evening News – were issued to councillors following the death of 41-year-old Labour MP Mrs Cox, who was killed outside her constituency surgery in Birstall, near Leeds, on June 16.

City councillor Alex Lunn, who has been a victim of threatening messages in the past, said he was taking the advice from police seriously.

He said: “Easy access for the public to councillors, MSPs and MPs is a cherished part of Scottish democracy and must be protected at all costs.

“Many of the measures being proposed are sensible. However, we have to remember that most councillor surgeries happen in public places like libraries, schools and community centres, often with members of the public and council staff nearby. In the unlikely event someone wishes to attack a councillor physically, then the safety of those nearby also needs to be considered.”

While police said they recognised surgeries take place in a range of environments, and that the advice given might not be relevant to particular venues, they urged councillors to ensure another trusted person is present during meetings.

Councillor Gavin Corbett said: “It is quite right that councillors should have heightened awareness of safety. But that equally extends to lots of staff, whether in public or private sectors, who are providing direct services to members of the public, sometimes in stressful circumstances. The important thing is to take sensible steps to be aware of safety without diluting the need to be accessible.”

Councillor Jason Rust insisted trust was a key part of his relationship with residents and it was important that wasn’t eroded.

The documents also provide councillors with IT security measures, advice on how to deal with a suspicious package and in what circumstances to report inappropriate communication or harassment to police.

A spokeswoman for Police Scotland said: “Police Scotland’s priority is to keep people safe. We do not comment on specific security arrangements or advice for individuals.”

A city council spokesman said: “We will continue to work closely with Police Scotland on safety issues across the city to ensure that Edinburgh remains a safe place.”