add debug logging on erlang side too