Perhaps put the value we got in the exception? That might be handy for debugging. Also, the `direction` param should now either be mandatory or have a valid default value.