As the junction of pipe to cylinder is metal to metal the seal is made by the softer metal of the swaged end of the pipe deforming to fit the conical shape inside the cylinder. When fitting a new cylinder to an existing pipe, just occasionally, because it was forced to fit the shape of the old cylinder, it just can't be made to seal. In this situation a new pipe is the only answer - don't be tempted to mess about with liquid gasket etc in an attempt to obtain a seal because, under emergency braking the pressure can become extreme and might well "spit out" any sealing material! On longer pipes you might find it possible to cut off the defective swaged end and remake it but usually it's just simpler to make a new pipe. There's also the fact that cheaper pipe forming (flaring) tools don't work too well on steel pipes so on many cars reflaring a pipe is not a good option anyway. I see what PB is saying about local factors being able to supply pipes. Mine do this. You just take the old pipe in and they do it on the spot. I know a number of the locals use this service. Long ago, when we lived out in the country - so once the car was disabled it was very difficult to get into town, I decided I wanted to be able to do this myself. I have a couple of cheaper flaring tools and both work well so I would have no hesitation in making up my own pipes if needed. If you've never made up a pipe before though then the Factor option is very attractive.
I've myself had the problem of defective new cylinders on more than one occasion in years gone by - haven't seen one for quite some time though, maybe quality control is better these days? Or maybe I'm just not doing so much now I'm "old". Although rare I've seen both casting defects in cylinder bores and damaged seals, I would presume during assembly? I never use a cylinder now without popping the pistons out and having a good look at both the cylinder walls and seal condition.