�
]�g � �* � d dl mZ d dlmZmZ d d�ZdS )
� )�annotations)�IO�Callable� file_like�IO[str]�return�
int | Nonec �d � t | dd� � }|� |� � S # t $ r Y dS w xY wdS )z�Get fileno() from a file, accounting for poorly implemented file-like objects.
Args:
file_like (IO): A file-like object.
Returns:
int | None: The result of fileno if available, or None if operation failed.
�filenoN)�getattr� Exception)r r s �\/home/asafur/pinokio/api/open-webui.git/app/env/lib/python3.11/site-packages/rich/_fileno.py�
get_filenor sV � � (/�y�(�D�'I�'I�F�
�� ��6�8�8�O��� � � � �4�4� ����
�4s � �
-�-N)r r r r )�
__future__r �typingr r r � � r �<module>r sM �� "� "� "� "� "� "� � � � � � � � �� � � � � r