o
    _~#g                     @   s   d dl mZ d dlmZ d dlZd dlZd dlZd dlmZ e	dZ
de
j_de
j_de
j_dd Ze	
ddeeddf fddZdd ZdS )    )	Generator)contextmanagerN)HDFStoretables   c                 C   s2   z| d ur|    W d S W d S  ty   Y d S w )N)closeOSError)store r
   /var/www/static.ux5.de/https/Moving-Object-Detection-with-OpenCV/env/lib/python3.10/site-packages/pandas/tests/io/pytables/common.py
safe_close   s   r   aFreturnc              	   c   s    t  3}t|| }t|||||d}|V  W d    n1 s#w   Y  W d    d S W d    d S 1 s;w   Y  d S )N)mode	complevelcomplib
fletcher32)tempfileTemporaryDirectorypathlibPathr   )pathr   r   r   r   
tmpdirnametmp_pathr	   r
   r
   r   ensure_clean_store   s    
"r   c              	   C   s*   z|  | W dS  ttfy   Y dS w )z
    For tests using tables, try removing the table to be sure there is
    no content from previous tests using the same table name.
    N)remove
ValueErrorKeyError)r	   keyr
   r
   r   _maybe_remove*   s
   r   )r   NNF)collections.abcr   
contextlibr   r   r   pytestpandas.io.pytablesr   importorskipr   
parametersMAX_NUMEXPR_THREADSMAX_BLOSC_THREADSMAX_THREADSr   r   r   r
   r
   r
   r   <module>   s"    
	