Improve error message for cases of invalid or missing namespaces.

Resolves: https://www.pivotaltracker.com/story/show/82412616