CI: Print original warnings in `fail_on_warnings`
What does this MR do and why?
We are seeing flaky jobs due to fail_on_warnings
but the printed
warnings aren't helpful.
In order to debug them better we also print the original/unfiltered warnings.
Screenshots or screen recordings
header |
---|
How to set up and validate locally
- Create
foo.sh
#!/bin/bash
warn() {
echo "$*" >&2
}
echo "OK"
warn "Something else"
warn "Type application/netcdf is already registered as a variant of application/netcdf."
warn "Type DIFFERENT is already registered as a variant of application/netcdf."
warn "as long at it matchesType application/netcdf is already registered as a variant of application/netcdf.with a suffix"
warn 'Browserslist: caniuse-lite is outdated. Please run next command `yarn upgrade`'
warn
warn "**** gitlab:sidekiq:sidekiq_queues_yml:check had the following warning(s):"
warn
warn "A warning"
warn
warn
and then
chmod a+x foo.sh
bash # spawn a subshell
source scripts/utils.sh
fail_on_warnings ./foo.sh
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
See #386693 (closed)
Edited by Lin Jen-Shin