Bug #5652
closed
[SDKs] There is no way to silence arv-put and arv-get
Added by Abram Connelly almost 10 years ago.
Updated over 7 years ago.
Description
On successful upload, 'arv-put' spits out a message of the form "Collection saved ...". There is no way to silence this output short of redirecting stderr to /dev/null. 'arv-put' and 'arv-get' should at least have an option to silence non-error stderr messages.
This came up in the context of trying to automate 'arv-put' upload through a cron job. Since 'arv-put' sends a message on successful upload to keep, the only way to silence spurious email reporting is to redirect stderr to /dev/null, precluding the possibility of catching real errors.
- Subject changed from There is no way to silence arv-put and arv-get to [SDKs] There is no way to silence arv-put and arv-get
- Category set to SDKs
- Target version changed from Bug Triage to Arvados Future Sprints
- Story points set to 0.5
- Assigned To set to Lucas Di Pentima
- Target version changed from Arvados Future Sprints to 2017-07-19 sprint
- Status changed from New to In Progress
Updates at 446e64dc1
Test run: https://ci.curoverse.com/job/developer-run-tests/382/ (not sure if they're working now)
Added --silent
flag to arv-put
so that it doesn't produce any output on normal operations.
Added related tests.
For the arv-get
command, I believe that passing the already existing --no-progress
flag would produce the desired outcome.
- "Do not produce any output unless an error happens." => "Do not print any debug messages to console. (Any error messages will still be displayed.)" ?
- test_no_progress_when_stderr_not_a_tty
Can you please throw in a new line between the two test blocks (is tty and not tty)? Also, moving the comment “Confirm that progress is written to stderr when is a tty” and its counterpart to before setting the tty flag might improve readability of each of the code blocks
- test_silent_mode => test_silent_mode_no_errors? Also, you might want to consider saying "no console output will be printed" instead of "no output will be printed" in the comments in the tests.
Thanks.
- Status changed from In Progress to Resolved
- % Done changed from 0 to 100
Applied in changeset arvados|commit:247d202b57d7c65e4192e0667446d533e552bed7.
Also available in: Atom
PDF