diff --git a/telemetry_api/lib/telemetry_api/periodically.ex b/telemetry_api/lib/telemetry_api/periodically.ex index 81bd8240e..21ba1639f 100644 --- a/telemetry_api/lib/telemetry_api/periodically.ex +++ b/telemetry_api/lib/telemetry_api/periodically.ex @@ -48,14 +48,14 @@ defmodule TelemetryApi.Periodically do PrometheusMetrics.new_gas_price(gas_price) {:error, error} -> - IO.inspect("Error fetching gas price: #{error}") + Logger.error("Error fetching gas price: #{inspect(error)}") end {:noreply, %{}} end defp fetch_operators_info() do case Operators.fetch_all_operators() do :ok -> :ok - {:error, message} -> IO.inspect("Couldn't fetch operators: #{IO.inspect(message)}") + {:error, message} -> Logger.error("Couldn't fetch operators: #{inspect(message)}") end end @@ -67,7 +67,7 @@ defmodule TelemetryApi.Periodically do Operators.update_operator(op, %{status: string_status(status)}) error -> - Logger.error("Error when updating status: #{error}") + Logger.error("Error when updating status: #{inspect(error)}") end end) :ok diff --git a/telemetry_api/lib/telemetry_api/traces.ex b/telemetry_api/lib/telemetry_api/traces.ex index cc2336491..bcea07229 100644 --- a/telemetry_api/lib/telemetry_api/traces.ex +++ b/telemetry_api/lib/telemetry_api/traces.ex @@ -96,7 +96,7 @@ defmodule TelemetryApi.Traces do ) IO.inspect( - "Operator response included. merkle_root: #{IO.inspect(merkle_root)} operator_id: #{IO.inspect(operator_id)}" + "Operator response included. merkle_root: #{inspect(merkle_root)} operator_id: #{inspect(operator_id)}" ) :ok @@ -129,11 +129,6 @@ defmodule TelemetryApi.Traces do | subspans: Map.delete(trace.subspans, :batcher) }) - with {:ok, _trace} <- set_current_trace(merkle_root) do - Tracer.end_span() - TraceStore.delete_trace(merkle_root) - end - :ok end end