tezos-reward-distributor-organization / tezos-reward-distributor

Tezos Reward Distributor (TRD): A reward distribution software for tezos bakers.
https://tezos-reward-distributor-organization.github.io/tezos-reward-distributor/
GNU General Public License v3.0
87 stars 51 forks source link

exit status is always 0 even when TRD fails (in single-shot mode) #653

Closed nicolasochem closed 1 year ago

nicolasochem commented 1 year ago

A simple example is when the lock file is present and TRD runs unattended. This happens:

│ Tezos Reward Distributor (TRD) is Starting                                                                                                                                        │
│ Lock file present. Please check if another process is running.                                                                                                                    │
│ Are you sure that no other process is running and want to force the app start process? (y/n)                                                                                      │
│ 2023-01-24 22:12:24,750 - MainThread - ERROR - [Process Life Cycle completing With Failure] Error Details: EOF when reading a line                                                │
│ 2023-01-24 22:12:24,753 - MainThread - INFO - TRD is shutting down...                                                                                                             │
│ 2023-01-24 22:12:24,753 - MainThread - INFO - --------------------------------------------------------                                                                            │
│ 2023-01-24 22:12:24,754 - MainThread - INFO - Sensitive operations are in progress!                                                                                               │
│ 2023-01-24 22:12:24,754 - MainThread - INFO - Please wait while the application is being shut down!                                                                               │
│ 2023-01-24 22:12:24,754 - MainThread - INFO - --------------------------------------------------------  

But the exit status is zero.

If it was non-zero, my orchestration system would alert me.

Can we fix it? Either for this specific case or in a more general case.