api.py 文件源码

python
阅读 25 收藏 0 点赞 0 评论 0

项目:sndlatr 作者: Schibum 项目源码 文件源码
def get_model(self):
        if not isinstance(self.json, dict):
            raise HTTPSuccess()
        key = self.json.get('key', None)
        if not key:
            logging.warn('send handler called without key')
            raise HTTPSuccess()
        key = ndb.Key(urlsafe=key)
        job = key.get()
        if job is None:
            logging.warn('job {} not found'.format(key))
            raise HTTPSuccess()
        return job
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号