Politics is aways a part of war. US wars have heavy political influence, and so does the war in Ukraine right now (on both sides).
The problem is that the politics can strongly interfere with military reality, and lead to disaster.
Stalin's problems in 1941 was that 1. he purged the army, but likely not to the extent popularly believed 2. no retreat policies, leading to huge defeats 3. misjudged the political situation and allowed the Russian army to reorganize. The Germans attacked when their motorized forces were half-formed and trying to train/assemble into cohesive units.
Hitler from 1943 onward was doing the same thing with no retreat policies. Although for Germany by 1943 they were so massively outnumbered that they had no chance of winning.