improved error handling, centralized message generation for later
improvements