(
        self, database: Optional[str], schema: Optional[str]
    )
return to_remove
Get the relations in a schema. Callers should hold the lock.
Get the relations in a schema. Callers should hold the lock.
Get the relations in a schema . Callers should hold the lock .
def _list_relations_in_schema(
        self, database: Optional[str], schema: Optional[str]
    ) -> List[_CachedRelation]:
        """Get the relations in a schema. Callers should hold the lock."""
        key = (lowercase(database), lowercase(schema))

        to_remove: List[_CachedRelation] = []
        for cachekey, relation in self.relations.items():
            if (cachekey.database, cachekey.schema) == key:
                to_remove.append(relation)
        return to_remove
def _list_relations_in_schema ( self , database : Optional [ str ] , schema : Optional [ str ] ) -> List [ _CachedRelation ] : key = ( lowercase ( database ) , lowercase ( schema ) ) to_remove : List [ _CachedRelation ] = [ ] for cachekey , relation in self . relations . items ( ) : if ( cachekey . database , cachekey . schema ) == key : to_remove . append ( relation ) return to_remove