I don't know if my experience is typical or not but I do know that several times in my career I have encountered or been put into a position where it was clear that 'success' was tied to doing something which I felt was also wrong. I have always chosen not to set aside my principles for that success.
And still I know people who have made the immoral choice and reaped the rewards, and then they have used that success to step into places of higher influence or control. They would no doubt argue that they were in a much better place to do good now, because they chose to do something wrong once before.
It is not surprising that this conflict is the underpinning of many dramatic stories.
And even if - wave a very large magic wand - every AI/ML engineer in the United States pledged to not work on military applications, the U.S, would just contract that same work out from the U.K., Canada, etc...
This is true if the engineer is in such a position of power within the company that he can effectively influence things towards the ethical goal. Most of typical for-profit corporation engineers who care about that ethical goal have no such position. If they strongly disagree with what they contribute to, the best decision for them and the ethical goal is to quit.
There is a school of thought that recommends “moral” people doing “immoral” work because if those people left then other “immoral” people will take those jobs and more readily implement “immoral” features. So the “moral” engineers have an incentive to stay and act as a front line against “immoral” actions, or at least have an insider’s position for whistleblowing.
Military drones are here to stay, and whether or not the US builds them, other military powers certainly will.
Ultimately, I don’t think this changes anything.