improved error message of calling invalid scope method.