We let these "allies" get away with declaring war on Japan AFTER we dropped the bomb. This got their foot in the door for a piece of a pie they never paid a drop of blood for. (How many russians died fighting japs?)
In turn, they then gave us the Korean War, the Viet Nam war, and the Cuban missle crisis.
BTW, no one knew if the Japanese would capitulate after only two atom bombs were used. The Russians were an insurance policy. Then, too, we only had two atom bombs ~ and we ended up dropping all of them. What would have done if that hadn't been convincing?
It's noteworthy that Sorge, Stalin's spymaster, was well aware of a Japanese spy present in the Manhattan Project staff ~ he exposed him to American intelligence who then prepared to trip the spy up. He fled before he was caught however.
So, if Stalin's spymaster knew about the Japanese spy, he knew about the Atom Bomb ~ and, in fact, he had his own spies in the program. The Russians weren't all that far behind us in developing nuclear weapons it turned out.
Again, back to the question of how fast the Japanese would surrender ~ given what was going on in China it was probably a darned good idea to have the Russians on our side rather than sitting out the rest of the war.
Hindsight has 20/20 vision.
They WERE our allies.
But we gave them Ronald Reagan. Checkmate.