I guess Truman consulted with the devil prior to nuking Hiroshima and Nagasaki, then.
Not at all.
Your analogy is flawed.
(1) Japan was not our ally - we had formally declared war on them.
(2) Hiroshima and Nagasaki were both military targets.
(3) Japan had control over the outcome - if the Japanese government had granted us the unconditional surrender we requested, Nagasaki would never have happened.
The two situations are radically different.
The only think they have in common is the suggested weapon.