-
Notifications
You must be signed in to change notification settings - Fork 49
Don't use logrus Fatalf() method #630
Comments
In the topmost level of Lokomotive (which is
Which functions for example are we talking about? |
Assuming that we should almost have no code in |
I'd say all functions which can be/should be unit tested. |
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Refs #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Also, it no longer requires logger, so argument has been removed. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Also, it no longer requires logger, so argument has been removed. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Also, it no longer requires logger, so argument has been removed. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Also, it no longer requires logger, so argument has been removed. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Also, it no longer requires logger, so argument has been removed. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Also, it no longer requires logger, so argument has been removed. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Also, it no longer requires logger, so argument has been removed. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Also, it no longer requires logger, so argument has been removed. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate it strictly from *cobra.Command, so it is easier to move this code around in the future. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Also, it no longer requires logger, so argument has been removed. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Also, it no longer requires logger, so argument has been removed. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate it strictly from *cobra.Command, so it is easier to move this code around in the future. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To remove a dependency on log.Entry to make moving this code around easier and to avoid hiding function complexity from logger. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io> Signed-off-by: knrt10 <kautilya@kinvolk.io>
To soften the dependency on log.Entry and to separate the functionality from CLI code. This also makes code easier to move around and avoids hiding function complexity. Part of #630 Signed-off-by: Mateusz Gozdek <mateusz@kinvolk.io> Co-authored-by: knrt10 <kautilya@kinvolk.io>
This is now done. We only use |
Fatalf()
after printing given message makes process exit with code 1, which can be used instead of usingreturn
statements in the function, which in my opinion hides the complexity of the functions. We should make functions return errors and then we can callFatalf()
once.The text was updated successfully, but these errors were encountered: