@classmethod<EOL><INDENT>def unpack_scope(cls, scope):<DEDENT>
query = {}<EOL>projection = {}<EOL>options = {}<EOL>if isinstance(scope, tuple):<EOL><INDENT>if len(scope) > <NUM_LIT:3>:<EOL><INDENT>raise ValueError("<STR_LIT>")<EOL><DEDENT>if len(scope) >= <NUM_LIT:1>:<EOL><INDENT>query = scope[<NUM_LIT:0>]<EOL><DEDENT>if len(scope) >= <NUM_LIT:2>:<EOL><INDENT>projection = scope[<NUM_LIT:1>]<EOL><DEDENT>if len(scope) == <NUM_LIT:3>:<EOL><INDENT>options = scope[<NUM_LIT:2>]<EOL><DEDENT><DEDENT>elif isinstance(scope, dict):<EOL><INDENT>query = scope<EOL><DEDENT>else:<EOL><INDENT>raise ValueError("<STR_LIT>")<EOL><DEDENT>return query, projection, options<EOL>
Unpacks the response from a scope function. The function should return
        either a query, a query and a projection, or a query a projection and
        an query options hash.