golden hour
/usr/local/lib/python3.6/site-packages/virtualenv/config/__pycache__
⬆️ Go Up
Upload
File/Folder
Size
Actions
__init__.cpython-36.pyc
147 B
Del
OK
convert.cpython-36.pyc
3.28 KB
Del
OK
env_var.cpython-36.pyc
690 B
Del
OK
ini.cpython-36.pyc
2.27 KB
Del
OK
Edit: ini.cpython-36.pyc
3 ��f� � @ sR d dl Z d dlZd dlmZ d dlmZ d dlmZ ddlmZ G dd� d�Z dS ) � N)�ConfigParser)�Path)�user_config_dir� )�convertc @ sN e Zd ZdZdddd�ZdZddd �Zd d� Zdd � Zdd� Z e dd� �ZdS )� IniConfigZVIRTUALENV_CONFIG_FILEzfailed to parse�active�missing)NTF� virtualenvNc C s |d krt jn|}|j| jd �}|d k | _|d krHttddd��d }nt|�}|| _i | _d }d | _ y| jj � | _ W n& tk r� } z |}W Y d d }~X n`X | j r�| jj� | _t � | _y| j� | jj| j�| _W n& tk r� } z |}W Y d d }~X nX |d k �rtjd||� d S )Nr Zpypa)�appname� appauthorzvirtualenv.iniz(failed to read config file %s because %r)�os�environ�get�VIRTUALENV_CONFIG_FILE_ENV_VAR� is_env_varr r �config_file�_cache�has_config_file�exists�OSError�resolver � config_parser�_load�has_section�section�has_virtualenv_section� Exception�logging�error)�self�envr � exception�exc� r$ �;/tmp/pip-build-ni_5055i/virtualenv/virtualenv/config/ini.py�__init__ s0 zIniConfig.__init__c C s$ | j jd��}| jj|�S Q R X d S )N�rt)r �openr � read_file)r Zfile_handlerr$ r$ r% r . s zIniConfig._loadc C st ||f}|| j kr| j | S y0d}| jj| j|j� �}t|||�}||f}W n tk rd d }Y nX || j |<