utils.py 文件源码

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

项目:Turbo 作者: jaydenkieran 项目源码 文件源码
def parse(filename):
        """
        Parse a YAML file
        """
        try:
            with open(filename) as f:
                try:
                    return yaml.load(f)
                except yaml.YAMLError as e:
                    log.critical("Problem parsing {} as YAML: {}".format(
                        filename, e))
                    return None
        except FileNotFoundError:
            log.critical("Problem opening {}: File was not found".format(filename))
            return None
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号