Work on the last of four submarines being converted for the Canadian navy has been completed at the Barrow shipyard in Cumbria.
The submarine is one of four going to Canada
HMS Upholder was built for the British Royal Navy, but was declared surplus to requirements.
The vessels have been sold to Canada in a multi-million pound deal.
The Upholder submarines are state of the art, but are diesel electric powered.
They were declared surplus to requirement by the Ministry of Defence when the Royal Navy upgraded to a nuclear powered fleet.
The Barrow shipyard, which played a part in the vessels' construction, has been carrying out the work to make them seaworthy and modify them to Canadian requirements.
The final refitted vessel was being rolled out of the Barrow yard's Devonshire dock hall for the last time on Friday.
To mark the event, a short ceremony was being held with Mary Rowland, the widow of the man in charge of building the submarine in Barrow, the guest of honour.
HMS Upholder will leave Barrow next summer, after sea trials, after which she will be renamed Her Majesty's Canadian Ship Chicoutimi.