Better management of exceptions