If a respectable professor writes the same recommendation letter for all students they recommend, especially when it looks like merely a character certificate, i.e. the professor knows the student X, s/he is good, sincere, hardwarking, qualified XYZ; but does not mention any details of strengths and weaknesses of the student; does it make a bad impression of the recommended student (X)?
Since a candidate might only get to submit 3 LORs, if one is worthless, that can't possibly be as good as 3 strong ones offering actual reasons why they're such a great candidate. So, yes, I think it would hurt, maybe enough to matter, maybe not, depending on the competition. It's important to carefully choose someone you trust.
As an instructor writing an LOR, there's really no excuse for submitting empty drivel. But if someone's doing that, I think they're an exception. I think most instructors appreciate that when you agree to write an LOR, you accept responsibility to take it seriously and put some thought into it.
It's just not that hard to write a helpful LOR. It's okay for the letter to be formulaic (most are, since we do them over and over for so many students) but it has to provide helpful information beyond just the final grade.
Even if all I know about a student is that they were one of 1000 in my intro CS class and they got an A, I can still write a useful LOR explaining what that A means by providing additional objective information, e.g., specifics about the nature and difficulty of the class, the projects, number of lines of code in them, how the student performed, especially class rank, not just final grade.
To go beyond that, I'll ask the student for copies of their transcript, any statement of purpose or other essays they expect to submit, a paragraph or two describing the sort of career they want, and anything else like awards and achievements they'd like me to mention, even if they weren't in my class. If I don't know them well already, I'll suggest they drop by office hours to chat about the future they want.
This allows me to mention those awards or achievements and report that I've talked to the student, describe their interests and plans, and state that I support them. I'll close by inviting them to contact me if they have questions or would like to discuss my letter, but that's only happened once.
To add to Buffy's good answer: It also depends on the reputation of the professor. If a Nobel price laureate writes a letter that means something. Since they get so many requests, they will not be able to write something specific for each person, and they usually will not accept many requests.
Sometimes you are required to provide three letters of reference, but you only have two people that can write such a letter. The third one will be a canned one by necessity.
Committees that screen are made up of people that are asked to write letters of recommendation frequently. They will be able to read between the lines and accept that a canned letter is just saying that this appears to be a good student, but they do not know them very well. If you did an undergraduate research project with one professor, that letter will be important.
This probably varies by place. If LoRs are relatively unimportant then such a thing is probably fine. This student isn't an idiot.
But in a place like the US, where LoRs are quite important, such a letter is just noise to the committee. It isn't exactly bad, but it gives no support where support is needed.
I'd suggest not asking people for letters if they are known to behave like this. Find someone who you trust and who will write you a more personalized and positive letter.