Throw a wrench into something.

This idiom or expression means:

Make something fail.
Screw something up.

A. Did you get your loan approved?
B. Almost, but my ex wife throw a wrench into the process by telling them I was broke!!

Also:
Throw in a monkey wrench.