[Code health] Stop catching `Throwable`
If we need to catch all errors, catch Exception instead.
Also, we should avoid using Kotlin error() except for unrecoverable exceptions.
We may also want to avoid using runCatching, as it requires us to remember to explicitly the exception type in fold or other handler lambdas.
From Kotlin docs (link):
The root of the Kotlin exception hierarchy is the Throwable class. It has two direct subclasses, Error and Exception:
The Error subclass represents serious fundamental problems that an application might not be able to recover from by itself. These are problems that you generally would not attempt to handle, such as OutOfMemoryError or StackOverflowError.
The Exception subclass is used for conditions that you might want to handle. Subtypes of the Exception type, such as the RuntimeException and IOException (Input/Output Exception), deal with exceptional events in applications.
@scolsen @shobhitagarwal1612 @anandwana001 FYI, apologized if I recommended catching Throwable and may have used error() in the past.