The diffusion of protons and hydroxide ions along water wires provides an efficient mechanism for charge transport that is exploited by biological membrane channels and shows promise for technological applications such as fuel cells. However, what is lacking for a better control and design of these systems is a thorough theoretical understanding of the diffusion process at the atomic scale. Here we focus on two aspects of this process that are often disregarded because of their high computational cost: the use of first-principles potential energy surfaces and the treatment of the nuclei as quantum particles. We consider proton and hydroxide ions in finite water wires using density functional theory augmented with an apolar cylindrical confining potential. We employ machine learning techniques to identify the charged species, thus obtaining an agnostic definition that takes explicitly into account the delocalization of the charge in the Grotthus-like mechanism. We include nuclear quantum effects (NQEs) through the thermostated ring polymer molecular dynamics method and model finite system size effects by considering Langevin dynamics on the potential of mean force of the charged species, allowing us to extract the same "universal" diffusion coefficient from simulations with different wire sizes. In the classical case, diffusion coefficients depend significantly on the potential energy surface, in particular on how dispersion forces modulate water water distances. NQEs, however, make the diffusion less sensitive to the underlying potential and geometry of the wire.