A man forced his way into a house armed with a device minutes before an explosion went off that killed both him and his ex-partner, police said.