raise ValueError when trying to delete a key with no name (#1328)

Alternate pull request as discussed in #1336 with @oozie