Improved error handling in the Core classes
Merge branch 'CoreErrorHandling'