This is an automated email from the ASF dual-hosted git repository.

kaxilnaik pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/airflow.git


The following commit(s) were added to refs/heads/main by this push:
     new 0d6d5f23a2e AIP-72: Close sockets after sending start up msg (#44497)
0d6d5f23a2e is described below

commit 0d6d5f23a2e3861e49b3ea5effeeeb42db4ded94
Author: Kaxil Naik <[email protected]>
AuthorDate: Sat Nov 30 11:55:25 2024 +0000

    AIP-72: Close sockets after sending start up msg (#44497)
---
 task_sdk/src/airflow/sdk/execution_time/supervisor.py | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/task_sdk/src/airflow/sdk/execution_time/supervisor.py 
b/task_sdk/src/airflow/sdk/execution_time/supervisor.py
index 1fdcf309dff..4bbfcc665c6 100644
--- a/task_sdk/src/airflow/sdk/execution_time/supervisor.py
+++ b/task_sdk/src/airflow/sdk/execution_time/supervisor.py
@@ -347,12 +347,12 @@ class WatchedSubprocess:
             logs=read_logs,
         )
 
+        # Tell the task process what it needs to do!
+        proc._send_startup_message(ti, path, child_comms)
+
         # Close the remaining parent-end of the sockets we've passed to the 
child via fork. We still have the
         # other end of the pair open
         proc._close_unused_sockets(child_stdin, child_stdout, child_stderr, 
child_comms, child_logs)
-
-        # Tell the task process what it needs to do!
-        proc._send_startup_message(ti, path, child_comms)
         return proc
 
     def _register_pipe_readers(

Reply via email to