env.py 文件源码

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

项目:WhatTheHack 作者: Sylphias 项目源码 文件源码
def consider_single_directory(self, directory, item):
        """Searches for ``item`` within ``directory``. Is able to
        resolve glob instructions.

        Subclasses can call this when they have narrowed done the
        location of a bundle item to a single directory.
        """
        expr = path.join(directory, item)
        if has_magic(expr):
            # Note: No error if glob returns an empty list
            return self.glob(directory, item)
        else:
            if path.exists(expr):
                return expr
            raise IOError("'%s' does not exist" % expr)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号