| Server IP : 35.80.110.71 / Your IP : 216.73.216.221 Web Server : Apache/2.4.58 (Ubuntu) System : Linux ip-172-31-21-44 6.17.0-1019-aws #19~24.04.1-Ubuntu SMP Tue Jun 23 18:53:06 UTC 2026 x86_64 User : ubuntu ( 1000) PHP Version : 8.3.31 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /lib/python3/dist-packages/fs/__pycache__/ |
Upload File : |
�
��ob�
� � � d Z ddlmZmZ ddlZddlmZ ddlmZmZ ddl m
Z
mZmZm
Z
ej rddlmZmZmZmZmZ dd lmZ d
� Zdd�Zd� Zd
� Zy)z2Miscellaneous tools for operating on filesystems.
� )�print_function�unicode_literalsN� )�errors)�DirectoryNotEmpty�ResourceNotFound)�abspath�dirname�normpath�recursepath)�IO�List�Optional�Text�Union)�FSc � � t t |� � } |dvr"| j |� t |� }|dvr�!yy# t $ r Y yw xY w)z�Remove all empty parents.
Arguments:
fs (FS): A filesystem instance.
path (str): Path to a directory on the filesystem.
)� �/N)r r � removedirr
r )�fs�paths �*/usr/lib/python3/dist-packages/fs/tools.py�remove_emptyr sR � � �8�D�>�"�D�
��)�#��L�L����4�=�D� �)�#�� �
��
�s �$= � A �A c �~ ��� |�dn|�| j �|j }t ��fd�d� D ]
} ||� � y)a Copy data from one file object to another.
Arguments:
src_file (io.IOBase): File open for reading.
dst_file (io.IOBase): File open for writing.
chunk_size (int): Number of bytes to copy at
a time (or `None` to use sensible default).
Ni c � �� �� � xs d S �N� )�_chunk_size�reads ��r �<lambda>z copy_file_data.<locals>.<lambda>4 s �� ��[�!�)�T� � )r �write�iter)�src_file�dst_file�
chunk_sizer# �chunkr r s @@r �copy_file_datar) $ sE �� � ",�!3�+��K��=�=�D��N�N�E��)�4�� �� �e��r"