Protect the pattern, not the exact lift
When pain shows up, the first question is rarely whether training is possible. The first question is which pattern still needs to be trained and which version of that pattern is now too expensive. A lifter with shoulder irritation may still be able to row, press on an incline, use dumbbells, or shorten range of motion. A lifter with a cranky lower back may still be able to squat to a box, split squat, or use a machine hinge. Keeping the pattern in view is what stops pain from collapsing the whole program.
This is why the better articles in this topic stay away from one-size-fits-all replacement lists. The right substitution depends on what hurts, what does not, and what adaptation the session was meant to drive. A useful modification keeps the training goal recognizable while lowering symptom cost. That is a tighter standard than simply finding any exercise that feels different.