Don't fail horribly if not a state server.

The agent code still fails, but with a specific error code if it is missing.
The call site is then able to be intelligent.

(Review request: http://reviews.vapour.ws/r/529/)