locations.py 文件源码

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

项目:RealtimePythonChat 作者: quangtqag 项目源码 文件源码
def virtualenv_no_global():
    """
    Return True if in a venv and no system site packages.
    """
    # this mirrors the logic in virtualenv.py for locating the
    # no-global-site-packages.txt file
    site_mod_dir = os.path.dirname(os.path.abspath(site.__file__))
    no_global_file = os.path.join(site_mod_dir, 'no-global-site-packages.txt')
    if running_under_virtualenv() and os.path.isfile(no_global_file):
        return True
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号