o
    e                     @   s`   d dl mZ d dlmZ d dlmZ defddZdefddZdefd	d
Z	de
fddZdS )    )
ModuleType)Version)versionreturnc                  C   s   d} zt d}t|t| k rtd|  d| dd l}|W S  tyB } ztd|  d|  d|  d	|  d
|jd  
|d }~ww )Nz1.4.0
vegafusionz'The vegafusion package must be version  or greater. Found version r   zVThe "vegafusion" data transformer and chart.transformed_data feature requires
version z or greater of the 'vegafusion-python-embed' and 'vegafusion' packages.
These can be installed with pip using:
    pip install "vegafusion[embed]>=zR"
Or with conda using:
    conda install -c conda-forge "vegafusion-python-embed>=z" "vegafusion>="

ImportError: )importlib_versionr   ImportErrorr   args)min_versionr   Zvferr r   GD:\Projects\ConvertPro\env\Lib\site-packages\altair/utils/_importers.pyimport_vegafusion   s:   	r   c                  C   s   d} zt d}t|t| k rtd|  d| dd l}|W S  ty? } ztd|  d|  d|  d	|jd  |d }~ww )
Nz0.13.0zvl-convert-pythonz.The vl-convert-python package must be version r   r   zLThe vl-convert Vega-Lite compiler and image export feature requires
version zz or greater of the 'vl-convert-python' package. 
This can be installed with pip using:
   pip install "vl-convert-python>=z@"
or conda:
   conda install -c conda-forge "vl-convert-python>=r   )r	   r   r
   Z
vl_convertr   )r   r   Zvlcr   r   r   r   import_vl_convert   s6   r   c                  C   s   d} zt d}t|t| k rtd|  d| dd lm} |W S  tyA } ztd|  d|  d|  d	|jd  |d }~ww )
Nz11.0.0Zpyarrowz$The pyarrow package must be version r   r   z=Usage of the DataFrame Interchange Protocol requires
version zd or greater of the pyarrow package. 
This can be installed with pip using:
   pip install "pyarrow>=z6"
or conda:
   conda install -c conda-forge "pyarrow>=r   )r	   r   r
   Zpyarrow.interchangeZinterchanger   )r   r   pir   r   r   r   import_pyarrow_interchange7   s6   r   c                   C   s"   zt   W dS  ty   Y dS w )NTF)r   r
   r   r   r   r   pyarrow_availableP   s   r   N)typesr   Zpackaging.versionr   importlib.metadatar   r	   r   r   r   boolr   r   r   r   r   <module>   s    