Renfrewshire commuters can breathe a sigh of relief after rail unions called off strike action.
Rail workers' union the RMT had been on a collision course with Abellio ScotRail bosses over a pay deal for their members.
The situation looked bleak when a vital teatime deadline in talks involving the two sides and the Scottish Government passed last night without resolution.
But an eleventh hour deal was finally struck later, which resulted in the industrial action being scrapped.
RMT General Secretary, Mick Lynch, welcomed the deal, saying: "Following further discussions between RMT and ScotRail an agreement has been reached and the proposals have been accepted by the union.
"As the disputes are resolved strike action has been cancelled and RMT members have been advised to work normally."
Don't miss the latest headlines from around Renfrewshire. Sign up to our newsletters here.
Union chiefs had pledged to pull workers out during the COP26 summit, set to begin on Sunday.
And the move would have caused misery for commuters across the county after warnings were issued that the Renfrewshire roads network is also expected to be hard hit.
The knock-on effect of road closures close to the UN Climate Change Conference site at Glasgow's SEC campus is expected to cause congestion in the area.
Glasgow Airport is also expected to be the entry point for many of the 120 world leaders and 25,000 delegates due to attend.
The situation looked bleak on Wednesday evening, as a crunch deadline passed without resolution.
But an agreement was finally reached at the eleventh hour, where union chiefs okayed a pay offer which gives members a 2.5 per cent one year deal backdated to April 1, a £300 one-off sweetener for staff to back COP26 working and enhancements for staff who work rest days.
ScotRail's Chief Operating Officer,Ian McConnell, added: "We have reached a pay agreement with the RMT trade union that resolves strike action. We look forward to Scotland’s Railway playing its part in delivering a successful COP26 next week."
Rail bosses also acknowledged "the pressures" on Scotland's railways and have agreed to work together with unions in a bid to "explore future productivity initiatives" to ensure a sustainable future.
Commenting on the breakthrough, Scottish Government Transport Minister Graeme Day said: "Following recent discussions we are pleased that all four trade unions have now agreed to accept this very good pay offer on behalf of their members. We are proud to have brokered and funded a deal which gives Scotland’s rail workers a decent pay rise and improved terms and conditions, in contrast to conditions for rail workers under the UK Government."
He added: "As well as getting the pay rise they deserve, railway workers can now go back to delivering rail services for people right across Scotland and as well as for those attending COP26. Allowing everyone who works in Scotland’s Railways to play their part in welcoming the world to our country and showcase our efforts towards building a greener, cleaner railway."
Download the FREE Renfrewshire Live app now for all the latest news, features and sport in your area. Available on both Android and Apple. Download here: smarturl.it/RenfrewLiveSocial