Well for starters, when John first arrives he still has time left till hes a target. Its made quite clear just before this that you are not supposed to target him before the kill order is finalized.
When he is attacked in the Library by the big guy, presumably the guy would not have been able to claim the bounty or would have been excommunicated also.
As for why the doctor doesn't shoot him after the time is up and John is still there, well that's most likely because the doctor has morals and a code of honor that is a present theme in the movie. He is also quite clearly not an active assassin either so does not actively target people anyway.