Assuming the USA gets their bomb on schedule and a German city or two gets instant sunshine, everybody in the big power game is going to want one. This is especially true for those who see themselves at odds with the USA. Even if somehow Japan avoids war with the USA Japanese and US interests in the Pacific and China are at odds. Japan won't "withdraw" from China, the only way Japan stops is if there is some sort of peace settlement they can call victory. At a minimum this formally concedes Manchuria/Manchukuo and probably some other land as well, with economic concessions and extraterritoriality.
In 1945 the Japanese supply of engineers and scientists is even more limited than Germany, so devoting a lot of human resources to this project is going to be difficult until more are trained and that takes time. Those they have are good, but like Germany they have many tasks. If japan is digesting parts of China, and continuing to colonize and absorb Manchuria those are resource sinks. They can't short conventional forces because they face the USSR literally across a land border. All of this means that no matter how much they want it, they cannot throw the resources at it the USA (or USSR) did. Lastly one can argue about how much the "atomic spies" helped the Soviet program, but help it they did. Japan has no such network.
The question becomes will the atomic bomb be ready and used before the war in Europe ends. OTL it came several months too late to be used there. If the USA is in the war against Germany, say by spring 1942 as the naval war escalates, and no war in the Pacific, that means you have a great deal more US resources directed against Germany Many more troops and planes, full naval concentration on the Atlantic/U-boats, no issue of dividing landing craft between the German War and and the Japanese War and so forth. IMHO this should lead to an earlier defeat of Germany - 6 months is reasonable, a year is possible. The race to produce a bomb was going as fast as possible, so if the war ends 6-12 months earlier, is the project slowed down? Even if they test in July, 1945 you don't see actual use. Absent actual use, and the reality of what one 20kt bomb can do, how much a hurry/crash program will other folks be doing, and probably US development postwar will be much slower with improved designs...