Normally I'd say "bad hard drive" but....
...if this is the non-Retina† Macbook Pro 2012, the problem could be the hard drive CABLE. It is a thin ribbon with minimal insulation. After 3-6 years of vibration of normal use and transport, the cable, routed over sharp metal edges in the chassis, can chafe and lose some of its insulation, cause little shorts. The symptoms mimic those of a failing hard drive.
As a new cable costs under US$20 and can be install by a novice computer user, it is worth trying before resorting to more expensive things or binning the computer. I get the cables here:
Apple Hard Drive / SSD Cable For 13-inch MacBook Pro (Mid 2012) main drive bay
and use these instructions:
Hard Drive Cable
The low cost of the cable means you shouldn't even bother inspecting the old one. Many of the wear-related faults are too small to notice anyway.
† — the non-Retina 2012 model shipped with a built-in optical drive.