Give a failed submission a code, and put the cause in the log
A download that died on an HTTP 403 told the submitter "HTTP Error 403: Forbidden" and told the log "error: exit status 1". The tool's stderr went into status_msg and nowhere else, so the one person who could act on it saw nothing. Exactly backwards. Failures now go through a.fail: the submitter gets a sentence and an eight character code, the log gets that code, the stage, the submission, the source URL and the stderr tail. Quote the code, grep the log, find the line. Every record carries file:line now, and LOG_LEVEL sets the threshold — failures are logged at error, so no level hides them.
This commit is contained in:
@@ -9,6 +9,10 @@ ADMIN_NAME=Ylläpito
|
||||
# Set to false only for local development over plain HTTP.
|
||||
SECURE_COOKIES=true
|
||||
|
||||
# debug, info, warn or error. debug adds the per-request noise; failures are logged at error
|
||||
# regardless, with the same code the submitter is shown.
|
||||
LOG_LEVEL=info
|
||||
|
||||
# Public address of the site. Used to build pasteable invite links on the admin page.
|
||||
# Unset falls back to a relative link, which is fine locally.
|
||||
PUBLIC_URL=https://levyraati.example.com
|
||||
|
||||
Reference in New Issue
Block a user