Bug 853849 - log-delete writes errors to server log and not to stderr
Summary: log-delete writes errors to server log and not to stderr
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Beaker
Classification: Retired
Component: scheduler
Version: 0.9
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Dan Callaghan
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-09-03 06:34 UTC by Dan Callaghan
Modified: 2019-05-22 13:43 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-10-11 23:50:22 UTC
Embargoed:


Attachments (Terms of Use)

Description Dan Callaghan 2012-09-03 06:34:21 UTC
If log-delete gets an unexpected exception while deleting logs, it will be logged to /var/log/beaker/server-debug.log but not printed to stdout or stderr, and the exit status will still be 0. That means if something is failing (for example bug 853848) it is very likely the admin will never notice.

Comment 1 Raymond Mancy 2012-09-03 06:40:09 UTC
The logging of errors and continuing of deletion is by design. We can have thousands of files to delete and I don't think we would want errors with some of them stopping us from deleting the rest.

However a more obvious (read 'correct') place for the logs is in order.

Comment 2 Dan Callaghan 2012-09-03 06:46:13 UTC
The script already tries to send its logs to stderr, line 36 has:

    log_to_stream(sys.stderr)

but something must be going wrong with that.

Comment 3 Dan Callaghan 2012-09-04 03:31:01 UTC
On Gerrit: http://gerrit.beaker-project.org/1317

Comment 5 Dan Callaghan 2012-10-11 23:50:22 UTC
Beaker 0.9.4 has been released.


Note You need to log in before you can comment on or make changes to this bug.