 
           if :ok in res && consolidate_protocols? do
             Mix.Task.reenable("compile.protocols")
-            Mix.Task.run("compile.protocols")
+            mix_compile_each("protocols", [])
           else
             res
           end


    try do
      res = fun.()
      {res, Proxy.stop(proxy_gl)}
    after
      Process.group_leader(self(), original_gl)
      Process.exit(proxy_gl, :kill)

        end
      end)

    cond do
      :error in res -> {:error, out}
      :ok in res    -> :ok
      true          -> :noop
    end
  end

