Fix TypeError: promote_joins() got an unexpected keyword argument 'unconditional', need tests