it was a chain reaction of treaties.
the only one germany 100% caused unneeded trouble for was belgium.
As for both world wars, france has a habit of pushing germany to fight because they get to arrogant.
Furthermore france actually did go on a genocidal bent right after ww2 in algeria, and even place nazi collaborators in charge of this algerian genocide!
the allies are a lot less clean than we pretend.
We can acknowledge the nazis were evil without simultaneously over-demonizing the german empire and over-praising the allies.
ww1 was a war caused by treaties and hubris
ww2 was a war caused by angry people electing a maniac