Файловый менеджер - Редактировать - /opt/imh-python/lib/python3.9/site-packages/pylint/lint/__pycache__/utils.cpython-39.pyc
Ðазад
a n�h � @ s� d dl mZ d dlZd dlZd dlZd dlZd dlmZmZ d dl m Z d dl mZ d dlm Z mZ dddd d �dd�Zdd dd �dd�Zddd�dd�Zejddd�dd��ZdS )� )�annotationsN)�Iterator�Sequence)�datetime)�Path)�PYLINT_HOME�full_version� Exception�strr )�ex�filepath�crash_file_path�returnc C s: t t�t�� �t|�� �� }t|dd��}|�� }W d � n1 sH0 Y d}|� � sbd}|d| � d|� d| j j� d�7 }|t� � 7 }|d t� d tj� dt�� � d�7 }z<t|d dd��}|�|� W d � n1 s�0 Y W nH t�y4 } z.td|� d|� d|� d�tjd� W Y d }~n d }~0 0 |S )N�utf8)�encoding� u� First, please verify that the bug is not already filled: https://github.com/pylint-dev/pylint/issues/ Then create a new issue: https://github.com/pylint-dev/pylint/issues/new?labels=Crash 💥%2CNeeds triage 📥 z Issue title: Crash ``a `` (if possible, be more specific about what made pylint crash) ### Bug description When parsing the following ``a.py``: <!-- If sharing the code is not an option, please state so, but providing only the stacktrace would still be helpful. --> ```python z� ``` ### Command used ```shell pylint a.py ``` ### Pylint output <details open> <summary> pylint crashed with a ``z@`` and with the following stacktrace: </summary> ```python zR ``` </details> ### Expected behavior No crash. ### Pylint version ```shell z ``` ### OS / Environment z (z) ### Additional dependencies <!-- Please remove this part if you're not using any of your dependencies in the example. --> �az0Can't write the issue template for the crash in z because of: 'z' Here's the content anyway: �.)�file)r r r �now�strftimer �resolve�open�read�exists� __class__�__name__� traceback� format_excr �sys�platform�system�writer �print�stderr)r r r �issue_template_path�fZfile_content�template�exc� r) ��/root/rpmbuild/BUILDROOT/imh-python39-modules-3.9.7-92.el8.x86_64/opt/imh-python/lib/python3.9/site-packages/pylint/lint/utils.py�prepare_crash_report sF �& ��� ��� ,���r+ )r r% r c C s d| � d|� d�S )NzFatal error while checking 'zs'. Please open an issue in our bug tracker so we address this. There is a pre-filled template that you can use in 'z'.r) )r r% r) r) r* �get_fatal_error_messagek s ��r, z Sequence[str]z list[str])�additional_pathsr c C sR t tj�}g }t� }| D ] }||vr|�|� |�|� q|tj tjd d �<