
    -e2                        d Z ddlmZ ddlZ ej        e          ZddlZddlZddl	m
Z
 ddlmZ ddlmZ ddlmZmZ ddlmZ d	d
lmZmZ dZddZddZ G d de          ZdS )a  

To display information about Bokeh and Bokeh server configuration,
type ``bokeh info`` on the command line.

.. code-block:: sh

    bokeh info

This will print general information to standard output, such as Python and Bokeh versions:

.. code-block:: none

    Python version      :  3.9.7 | packaged by conda-forge | (default, Sep 29 2021, 19:20:46)
    IPython version     :  7.20.0
    Tornado version     :  6.1
    Bokeh version       :  3.0.0
    BokehJS static path :  /opt/anaconda/envs/test/lib/python3.9/site-packages/bokeh/server/static
    node.js version     :  v16.12.0
    npm version         :  7.24.2
    Operating system    :  Linux-5.11.0-40-generic-x86_64-with-glibc2.31

Sometimes it can be useful to get just paths to the BokehJS static files in order
to configure other servers or processes. To do this, use the ``--static`` option

.. code-block:: sh

    bokeh info --static

This will produce output like what is shown below

.. code-block:: none

    /opt/anaconda/envs/test/lib/python3.9/site-packages/bokeh/server/static

    )annotationsN)	Namespace)__version__)settings)nodejs_versionnpmjs_version)import_optional   )Argument
Subcommand)Infoversion_or_none
str | Nonereturnstrc                
    | pdS )zy helper method to optionally return module version number or not installed

    :param version_or_none:
    :return:
    z(not installed) )r   s    >lib/python3.11/site-packages/bokeh/command/subcommands/info.pyif_installedr   R   s     ///    module_nameattrc                H    t          |           }|rt          ||          nd S )N)r	   getattr)r   r   modules      r   _versionr   Z   s)    [))F$*4764   4r   c                  B    e Zd ZdZdZdZd edd          ffZddZdS )r   zR Subcommand to print information about Bokeh and Bokeh server configuration.

    infoz<Print information about Bokeh and Bokeh server configurationz--static
store_truez+Print the locations of BokehJS static files)actionhelpargsr   r   Nonec           	        |j         r"t          t          j                               dS d}t          dt          j                            |          d                     t          dt          t          dd                                t          dt          t          dd	                                t          d
t                      t          dt          j                                t          dt          t                                            t          dt          t                                            t          dt          j                                dS )z


        
zPython version      :  r   zIPython version     :  IPythonr   zTornado version     :  tornadoversionzBokeh version       :  zBokehJS static path :  znode.js version     :  znpm version         :  zOperating system    :  N)staticprintr   
bokehjsdirsysr(   splitr   r   r   r   r   platform)selfr"   newlines      r   invokezInfo.invokeu   sT    ; 	C(%''(((((GKCK,=,=g,F,Fq,IKKLLL^L)]9[9[,\,\^^___ZL)Y9W9W,X,XZZ[[[9K99:::CH,?,A,ACCDDDLL9I9I,J,JLLMMMKL,I,IKKLLLAH,=,?,?AABBBBBr   N)r"   r   r   r#   )	__name__
__module____qualname____doc__namer!   r   r"   r1   r   r   r   r   r   b   sn         
 DID 
XX>
 
 
 	DC C C C C Cr   r   )r   r   r   r   )r   r   r   r   r   r   )r5   
__future__r   logging	getLoggerr2   logr.   r,   argparser   bokehr   bokeh.settingsr   bokeh.util.compilerr   r   bokeh.util.dependenciesr	   
subcommandr   r   __all__r   r   r   r   r   r   <module>rB      s<  # #P # " " " " " g!!  



             # # # # # # = = = = = = = = 3 3 3 3 3 3 . - - - - - - -0 0 0 05 5 5 5"C "C "C "C "C: "C "C "C "C "Cr   