
    ziC                    b    d Z ddlmZ ddlZ G d de          Z G d de          ZeZddZ	dS )z)Sphinx deprecation classes and utilities.    )annotationsNc                      e Zd ZdS )RemovedInSphinx80WarningN__name__
__module____qualname__     ]/var/www/tmov.alphamb/tmov_inventario/venv/lib/python3.11/site-packages/sphinx/deprecation.pyr   r              Dr   r   c                      e Zd ZdS )RemovedInSphinx90WarningNr   r
   r   r   r   r      r   r   r   modulestr	attributecanonical_nameremovetuple[int, int]returnNonec                   |dk    rt           }n#|dk    rt          }nd|d}t          |          |  d| }|r
d|d|d}n|d	}t          j        |d
z   |d           dS )a  Helper function for module-level deprecations using __getattr__

    Exemplar usage:

    .. code:: python

       # deprecated name -> (object to return, canonical path or empty string)
       _DEPRECATED_OBJECTS = {
           'deprecated_name': (object_to_return, 'fully_qualified_replacement_name', (8, 0)),
       }


       def __getattr__(name):
           if name not in _DEPRECATED_OBJECTS:
               msg = f'module {__name__!r} has no attribute {name!r}'
               raise AttributeError(msg)

           from sphinx.deprecation import _deprecation_warning

           deprecated_object, canonical_name, remove = _DEPRECATED_OBJECTS[name]
           _deprecation_warning(__name__, name, canonical_name, remove=remove)
           return deprecated_object
    )   r   )	   r   zremoval version z is invalid!.z
The alias z is deprecated, use z	 instead.z is deprecated.z, Check CHANGES for Sphinx API modifications.   )
stacklevelN)r   r   RuntimeErrorwarningswarn)r   r   r   r   warning_classmsgqualified_namemessages           r   _deprecation_warningr%      s    > '?	6		077773,,,,N 76 6 6(6 6 6 $666M'JJA/ / / / / /r   )
r   r   r   r   r   r   r   r   r   r   )
__doc__
__future__r   r   DeprecationWarningr   PendingDeprecationWarningr   RemovedInNextVersionWarningr%   r
   r   r   <module>r+      s    / / " " " " " " 	 	 	 	 	1 	 	 		 	 	 	 	8 	 	 	 7 // // // // // //r   