Seems to me that conclusion from Milgram experiment are usually overblown. I would guess that 'teachers' just assume safety of the procedure and consent of 'learners' based on context. So it is not really about obedience vs moral imperatives but more about trust of authority vs. doubts based on personal observation.
But that is precisely the point. Trust in authority vs direct observation, and the shifting of the Overton window to create reduced trust in direct observations vs authoritative direction.
It has been repeated under a bunch of different circumstances, including with real dogs being shocked. Sidestepping conclusions because of hypothetical escape hatches in the original methodology isn't a great idea.