Gisborne's main water supply pipe was identified as at unacceptable risk of catastrophic failure months before Cyclone Gabrielle wrecked it.
The cyclone broke the pipe in 10 places, plunging the city's 39,000 people into a month-long water supply crisis. They are still labouring under level three water restrictions.
The Gisborne District Council completed its first government-ordered water safety plan just three months before Gabrielle hit.
The plan shows the safeguards around the main 40km supply pipe were not enough to reduce the "high" risk to an acceptable level.
It rated such a loss of supply as "possible" with "catastrophic" consequences.
The end result was a bright-red "unacceptable" risk rating.
RNZ asked if the council did enough quickly enough to address the risk its own experts had identified.
"The risk ... cannot be eliminated and can only be partially controlled, with the nature of such extreme events as a direct hit of a cyclone and flooding or a major earthquake," the council told RNZ.
After it got the report, it took two immediate steps, it said: It did a stocktake of critical spares, and assessed the pipe for cathodic protection from corrosion.
But it did not address the threat of forestry slash, and the safety plan does not specifically mention slash or what to do about it.
Slash debris smashed into bridges carrying the pipe as it zigzags across the Waingake River.
"Nine were damaged or destroyed with sections of the pipe severely damaged," the council said on its website.
Gisborne District Council's director of lifelines Dave Wilson said it had been working on how to protect the pipe well before Gabrielle, but affordability was a problem.
"We knew the pipe was a problem before the report was done," he said.
"Part of that's the very nature of the country that it goes across ... very steep, highly erodable soils.
"So we had been doing some work on how we were going to protect that better."
That was in the council's earlier long-term infrastructure strategy, Wilson said.
They had been working to upgrade pipe bridges and stablise the land.
"When the pine plantation was put in, that was to help secure the pipe, and that was around holding up the hillsides that were falling."
However, a lot of the Gabrielle damage came from landslides and entire trees hitting the pipe, he said.
In addition, ironically, the forests were now also a source of slash hazard, the source hazard report stated.
That report said large areas of the Pamoa forest in the catchment had recently been harvested.
"Slash left from harvesting activity is both a fire risk and poses hazards to the supply pipeline during flooding events.
"Areas of exotic plantation in proximity of the supply pipeline remain that present very high risk during future harvest activity and post-harvest due to steep topography and erosion of clear-felled land."
It would take years working with iwi to revert the land to native bush, it said.
"The years between without substantive vegetation cover, soil erosion and landslides are hazards to pipeline and pipe-bridge structures.
"Risk to infrastructure will remain high for years until plantings are established and land is stabilised."
The water safety plan, for its part, said the long-term goal was to refurbish the pipe and bridges, and turn the surrounding area back into mostly native bush, instead of slip-prone, council-owned pine forest.
About 100km of the 285km of water pipe network was damaged.
Shortly after the cyclone, the population was warned to drastically cut water use.
It took 45 days to fix the pipes.
The city still only has one and a half day's storage in the city's reservoirs if something else goes wrong.
The new water safety plan in November also rated 13 other risks to the water supply as "unacceptable", among the 117 hazards it assessed - many of them around contamination, such as from animals, not physical damage.
It shows that work to address the threat of damage taking out mains piped supply entirely, as happened with Gabrielle, is just one out of 24 "high priority" areas for improvement.
It is not clear how the council was deciding what to do first, among this long list of high priorities.
It was considering getting its water from somewhere else or shifting the pipe, it told RNZ.
"Longer term we are considering the potential for other supply location options and bulk main realignment options," it said.
The pipe was snapped by a landslide in 2014, taking out water supply for a week.
Last year Gisborne's spending on roads and paths was six times greater than the $7m it spent on water supply.
Its annual report said: "Customers continue to be very satisfied with the water supply system ... highlighting council's successful approach to providing high quality water to our community."
The water safety plan shows a recurring problem in combating the risks was high turnover of water staff at its contractor, Fulton Hogan.
The council has acknowledged slash played a big role in wrecking the pipe during Gabrielle, though it is still investigating just how much.
Its annual report last year said climate change was the most significant long-term issue facing Tairāwhiti and it was expecting "damage to infrastructure such as roads and pipes because of erosion".
Despite this recognition, some of its key plans do not appear to have been updated: Its water main emergency response plan dates from 2011, and its quality management plan from 2012 - well before the 2014 water-pipe break and the triple storms around 2017.
The water safety plans are a new requirement imposed on councils and other major water suppliers by the Crown water watchdog Taumata Arowai.
Gisborne District Council alone has three main reports that run to 150 pages. There are now thousands of such plans nationwide.
The annual report shows the council had more than $2m generated from forestry harvesting last year to push that on.
Its private forestry partner Juken New Zealand has denied that any current harvesting contributed to wrecking the water pipe.
Gisborne has been harvesting the forests in stages since 2018 - prior to which it has admitted to doing little monitoring of slash - with the aim of turning 1200ha back to native forest to secure the pipeline.
Deputy mayor Josh Wharehinga has previously called for more protection of the water pipe in the council-owned Pamoa forestry block.