Most people use stud finders to ensure they know where the studs are before predrilling a hole for a screw or driving in nails. What do people do also to ensure that the stud doesn't have cpvc or copper pipes going through the exact point that they plan to do the work at?
I know, most builders install steel plates to protect these intersections, but not all do. Even some studfinders can locate copper tubing, but not necessarily cpvc tubing.
Thermal imaging equipment aside, there's no way to determine where plastic water lines, fire suppression system lines, or DWV pipes run through studs.
For this reason, the code has minimum requirements for protection of plastic pipes. If they're within 1-1/2" of the face of the stud, they need nailguards. Hopefully that code was enforced on the house that you're working on.