def getTasks(self, tags = [], without_tags = [], show = 'open'):
        assert(show in ('all', 'open', 'closed'))
        query = Task.query

        tags = make_list(tags)
        for tag in tags:
            query = query.filter(Task.tags.any(title = tag))

        without_tags = make_list(without_tags)
        for tag in without_tags:
            query = query.filter(not_(Task.tags.any(title = tag)))

        if show != 'all':
            query = query.filter_by(done = (show == 'closed'))

        return query.all()
dataset/ETHPy150Open svetlyak40wt/gtdzen/gtdzen/__init__.py/GTD.getTasks/original