argo-workflows
argo-workflows copied to clipboard
chore: Fixes #2308 Structured Logging migration for Fatal logs
Fixes #2308 (Partially)
Changes:
- Replace
"log"
import withlog "github.com/sirupsen/logrus"
as needed (need to experiment more on this due to issues) - Replace
log.Fatal(err)
with its structured versionlog.WithError(err).Fatal(err.Error())
- If these changes look good, I can work on the remaining
Fatal
logs with fields, i.e.Fatalf
ones. - Is there any specific formatting that should be applied for the logger globally?
Please do not open a pull request until you have checked ALL of these:
- [x] Create the PR as draft .
- [x] Run
make pre-commit -B
to fix codegen and lint problems. - [x] Sign-off your commits (otherwise the DCO check will fail).
- [x] Use a conventional commit message (otherwise the commit message check will fail).
- [x] "Fixes #" is in both the PR title (for release notes) and this description (to automatically link and close the issue).
- [ ] Add unit or e2e tests. Say how you tested your changes. If you changed the UI, attach screenshots.
- [x] Github checks are green.
- [ ] Once required tests have passed, mark your PR "Ready for review".
If changes were requested, and you've made them, dismiss the review to get it reviewed again.