fix logging setup inside EM run-loop