Skip to content

Conversation

@da-viper
Copy link
Contributor

The logging markers for incoming ("<--") and outgoing ("-->") messages were incorrectly reversed. from #7790d69

The logging markers for incoming ("<--") and outgoing ("-->")
messages were incorrectly reversed. from #7790d69
@llvmbot
Copy link
Member

llvmbot commented Mar 16, 2025

@llvm/pr-subscribers-lldb

Author: Ebuka Ezike (da-viper)

Changes

The logging markers for incoming ("<--") and outgoing ("-->") messages were incorrectly reversed. from #7790d69


Full diff: https://github.com/llvm/llvm-project/pull/131544.diff

1 Files Affected:

  • (modified) lldb/tools/lldb-dap/Transport.cpp (+2-2)
diff --git a/lldb/tools/lldb-dap/Transport.cpp b/lldb/tools/lldb-dap/Transport.cpp
index db2d7228d3fb7..a721662a345eb 100644
--- a/lldb/tools/lldb-dap/Transport.cpp
+++ b/lldb/tools/lldb-dap/Transport.cpp
@@ -103,7 +103,7 @@ Expected<std::optional<Message>> Transport::Read() {
   if (raw_json->length() != length)
     return createStringError("unexpected EOF parse DAP message body");
 
-  DAP_LOG(m_log, "<-- ({0}) {1}", m_client_name, *raw_json);
+  DAP_LOG(m_log, "--> ({0}) {1}", m_client_name, *raw_json);
 
   return json::parse<Message>(*raw_json);
 }
@@ -114,7 +114,7 @@ Error Transport::Write(const Message &message) {
 
   std::string json = formatv("{0}", toJSON(message)).str();
 
-  DAP_LOG(m_log, "--> ({0}) {1}", m_client_name, json);
+  DAP_LOG(m_log, "<-- ({0}) {1}", m_client_name, json);
 
   std::string Output;
   raw_string_ostream OS(Output);

@JDevlieghere
Copy link
Member

Huh, you're right, the direction was changed, but I actually think the current direction is more intuitive.

@ashgti did you change this on purpose?

@JDevlieghere JDevlieghere requested a review from ashgti March 17, 2025 01:32
@ashgti
Copy link
Contributor

ashgti commented Mar 17, 2025

Huh, you're right, the direction was changed, but I actually think the current direction is more intuitive.

@ashgti did you change this on purpose?

I didn’t mean to change it but I’m fine with either form.

@da-viper da-viper merged commit 3af6c9f into llvm:main Mar 17, 2025
13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants