The developer of the new St James Quarter which has the controversial "ribbon" hotel as its centrepiece has said John Lewis has agreed to anchor the project after months of negotiation.

The flagship department store will stay open while the £850 million revamp of the eyesore building goes on, TH Real Estate said.

The key move comes after reports of a potential stall in the deal with the largest store in the centre.

Edinburgh St James, which will include up to 85 shops and 30 catering units, is expected to attract a range of operators including "boutique and independent stores, high street retailers, aspirational brands and high end names", as well as international retailers looking to expand into the UK.

Edinburgh-based writer Candia McWilliam said the new "ribbon" hotel plan is an eyesore that resembles "dog dirt" and is an insult to the city's architectural heritage.

The hotel was ridiculed as one of Scotland’s biggest flops in the The List Magazine.

It said: “Lo, the ‘turd hotel’ was born, and Edinburgh World Heritage status is at risk.”

The developer said this year has seen significant progress on Edinburgh St James with planning approval secured in July, followed by approval of the central hotel design in August. Construction work is anticipated to commence onsite in early 2016.

Martin Perry, Director of Development at TH Real Estate, said: "The signing of the John Lewis deal is an important milestone and we are delighted that they will anchor the scheme, in addition to remaining open for business throughout construction.

"It has always been our ambition to deliver a world class destination for Scotland and this important piece of the jigsaw brings us ever closer to starting on site in spring next year."

The Herald: St James Centre's new hotelSt James Centre's new hotel

Jeremy Collins, property director at John Lewis, added: "We’re delighted to have reached agreement with TH Real Estate for these exciting development proposals at the St James Centre.

"John Lewis prides itself on providing an excellent shopping experience to its customers, and we will continue to work closely with the developers to ensure that disruption to our shop is minimised where possible as work progresses.

"We look forward to our shop's full refurbishment being part of Edinburgh’s improved retail experience."

Ms McWilliam said earlier: "For can it be the case that our masters are so blind as to allow to be set at two great axes of the New Town something that for all the fancy talk of 'festival ribbons' and 'high fashion' resembles nothing so much as what citizens are coyly enjoined to pick up after their dogs?"

The 1.7 million sq ft Edinburgh St James development is one of the largest regeneration projects currently under way in the UK.