'Returns boolean indicating whether or not this access token is still valid.'

def check_valid(self):

    if getattr(self, 'revoked', False):
        return False
    try:
        client = OAuth2Client._byID(self.client_id)
        if client.deleted:
            raise NotFound
    except AttributeError:
        g.log.error('bad    token    %s:    %s', self, self._t)
        raise
    except NotFound:
        return False
    if self.user_id:
        try:
            account = Account._byID36(self.user_id)
            if account._deleted:
                raise NotFound
        except NotFound:
            return False
    return True
