Adding first implemtnation of exception handling