lookup.py 文件源码

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

项目:QualquerMerdaAPI 作者: tiagovizoto 项目源码 文件源码
def _check(self, uri, template):
        if template.filename is None:
            return template

        try:
            template_stat = os.stat(template.filename)
            if template.module._modified_time < \
                    template_stat[stat.ST_MTIME]:
                self._collection.pop(uri, None)
                return self._load(template.filename, uri)
            else:
                return template
        except OSError:
            self._collection.pop(uri, None)
            raise exceptions.TemplateLookupException(
                "Cant locate template for uri %r" % uri)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号