raise errors when map used incorrectly