AlkantarClanX12
Current Path : /opt/cloudlinux/venv/lib64/python3.11/site-packages/pydocstyle/__pycache__/ |
Current File : //opt/cloudlinux/venv/lib64/python3.11/site-packages/pydocstyle/__pycache__/config.cpython-311.pyc |
� �܋fЂ � �j � d Z ddlZddlZddlZddlZddlZddlmZ ddlm Z ddl mZmZm Z ddlmZ ddlmZ dd lmZ dd lmZ ddlmZmZ ej dk rddlZn ddlZn # e$ r dZY nw xY wd � Z G d� d� � Z G d� d� � Z edd� � Z G d� de!� � Z" edd� � Z#dS )z)Configuration file parsing and utilities.� N)� namedtuple)�Set)� NoOptionError�NoSectionError�RawConfigParser)�reduce)�compile� )�__version__)�log)� ErrorRegistry�conventions)� � c � � � � fd�}|S )z4Check that the configuration object was initialized.c �V �� | j �| j �t d� � � �| g|�R i |��S )Nz$using an uninitialized configuration)� _arguments�_options�RuntimeError)�self�args�kwargs�methods ��b/builddir/build/BUILD/cloudlinux-venv-1.0.6/venv/lib/python3.11/site-packages/pydocstyle/config.py� _decoratorz%check_initialized.<locals>._decorator sA �� ��?�"�d�m�&;��E�F�F�F��v�d�,�T�,�,�,�V�,�,�,� � )r r s ` r �check_initializedr s$ �� �-� -� -� -� -� �r c �L � e Zd ZdZd� Zd d�Zdd�Zd� Zd� Zdd �d �Z d� Z d� ZdS )� TomlParsera ConfigParser that partially mimics RawConfigParser but for toml files. See RawConfigParser for more info. Also, please note that not all RawConfigParser functionality is implemented, but only the subset that is currently used by pydocstyle. c � � i | _ dS )zCreate a toml parser.N)�_config�r s r �__init__zTomlParser.__init__. s � �����r Nc � � t |t t t j f� � r|g}g }|D ]�} t |d� � 5 }t s"t j d|� � ddd� � �=| j � t j |� � � � ddd� � n# 1 swxY w Y n# t $ r Y ��w xY wt |t j � � rt j |� � }|� |� � ��|S )a� Read and parse a filename or an iterable of filenames. Files that cannot be opened are silently ignored; this is designed so that you can specify an iterable of potential configuration file locations (e.g. current directory, user's home directory, systemwide directory), and all existing configuration files in the iterable will be read. A single filename may also be given. Return list of successfully read files. �rbzTThe %s configuration file was ignored, because the `tomli` package is not installed.N)� isinstance�str�bytes�os�PathLike�open�tomllibr �warningr"