types: fix error return when None is in Enum

Whe None is set as a valid value in an Enum, the error string that is
meant to be returned is built with a join() call on valid values.
However, that doesn't work as None isn't not a string.
Calling map(str, values) fixes this problem.

Also, if the value is invalid, the error code returned is 500 as if it
was the server fault. 400 should be returned instead, so rather than
raising a ValueError we raise an InvalidInput error.

Change-Id: I92695594676da2a247cef4e1e8fe277aa0972dea