Skip to content

Conversation

@rtomek
Copy link

@rtomek rtomek commented Dec 10, 2025

Added support for a --quiet option for download-single and download-multiple commands.

After updating to the latest gen3-client.exe file, our python scripts at MIDRC stopped working due to these functions needing an actual terminal window to generate the progress bars, and attempted workarounds to generate a console weren't working. Since this issue only seems to occur when used with a script wrapper, we can assume that the scripter should have a way to track progress (whether they choose to track progress or not is up to them).

Link to JIRA ticket if there is one:

New Features

Added a --quiet flag for download-single and download-multiple

Breaking Changes

None

Bug Fixes

If a progress bar could not be generated due to not finding a suitable terminal window, gen3-client would create a zero byte file and exit.

Improvements

Dependency updates

Deployment changes

We may need to update web docs to notify users of this new flag. The flag documentation when using e.g. ./gen3-client download-single --help in included with this PR.

Copilot AI review requested due to automatic review settings December 10, 2025 18:58
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds a --quiet flag to the download-single and download-multiple commands to suppress progress bar output. This addresses an issue where Python scripts calling gen3-client would fail when progress bars couldn't be rendered due to the absence of a terminal window.

Key changes:

  • Added --quiet flag to both download commands with conditional logic to skip progress bar initialization and updates
  • Modified downloadFile and batchDownload functions to accept a quiet parameter and conditionally create progress bars

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.

File Description
gen3-client/g3cmd/download-single.go Added --quiet flag with short option -q and passed the quiet parameter through to the downloadFile function
gen3-client/g3cmd/download-multiple.go Added --quiet flag (without short option), updated downloadFile and batchDownload functions to conditionally initialize and manage progress bars based on the quiet flag

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant