This fixes dependency issues that were experienced in notably #425 and other master commits I've tried to restart on 12/08/17