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

sbp pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tooling-trusted-release.git


The following commit(s) were added to refs/heads/main by this push:
     new 09c132d  Fix a problem with downloading using rsync
09c132d is described below

commit 09c132df958cdf0473861108ce7fbbc47a43374e
Author: Sean B. Palmer <[email protected]>
AuthorDate: Fri Sep 12 19:20:21 2025 +0100

    Fix a problem with downloading using rsync
---
 atr/ssh.py | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/atr/ssh.py b/atr/ssh.py
index b76fbf4..07a75a5 100644
--- a/atr/ssh.py
+++ b/atr/ssh.py
@@ -184,7 +184,6 @@ async def _step_02_handle_safely(process: 
asyncssh.SSHServerProcess) -> None:
     if not process.command:
         raise RsyncArgsError("No command specified")
 
-    _output_stderr(process, f"Received command: {process.command}")
     log.info(f"Received command: {process.command}")
     # TODO: Use shlex.split or similar if commands can contain quoted arguments
     argv = process.command.split()
@@ -208,6 +207,7 @@ async def _step_02_handle_safely(process: 
asyncssh.SSHServerProcess) -> None:
         ####################################################
         await _step_07a_process_validated_rsync_read(process, argv, 
release_obj)
     else:
+        _output_stderr(process, f"Received write command: {process.command}")
         log.info(f"Processing WRITE request for {release_name}")
         #####################################################
         ### Calls _step_07b_process_validated_rsync_write ###
@@ -522,7 +522,10 @@ async def _step_08_execute_rsync(process: 
asyncssh.SSHServerProcess, argv: list[
     )
     # Redirect the client's streams to the rsync process
     # TODO: Do we instead need send_eof=False on stderr only?
-    await process.redirect(stdin=proc.stdin, stdout=proc.stdout, 
stderr=proc.stderr, send_eof=False)
+    # , stdout=proc.stdout
+    # , stderr=proc.stderr
+    # , send_eof=False
+    await process.redirect(stdin=proc.stdin, stdout=proc.stdout, 
send_eof=False)
     # Wait for rsync to finish and get its exit status
     exit_status = await proc.wait()
     log.info(f"Rsync finished with exit status {exit_status}")


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to