o
    wvXjÏ  ã                
   @   st  d Z ddlmZmZmZ ddlZddlZddlZddlm	Z	 ddl
mZ dZdZd	Zd
ZdZdZdZdZd ee¡Ze	ddƒZe de¡ ¡ Zeeed ƒeed ƒeed ƒed p\ddƒ ZZ[[ej d¡r}ddlm Z  dddde j!fdd„Z"e"e _!dZ#de$ƒ dddd…  %¡ < e#rÉddl&m'Z' ddl(m)Z) dd l*m+Z+ dd!l,m-Z- dd"l.m/Z/m0Z0 dd#l1m2Z2m3Z3m4Z4m5Z5m6Z6m7Z7m8Z8m9Z9m:Z: dd$l;m<Z< dJd%d&„Z=d'd(„ Z>d)d*„ Z?		dKd+d,„Z@ejAeBfi d-g d.¢d/gd0d1gg d2¢d3gd4œ“d5d6d7i“d8d9“d:eC“d;eD“d<e “d=e“d>e“d?e“d@e“dAe“dBe“dCe“dDe“dEe“de“dFe“d,e@“d&e=“dGe“dHe“dIe“Ž\ZEZFdS )LzDistributed Task Queue.é    )Úabsolute_importÚprint_functionÚunicode_literalsN)Ú
namedtupleé   )ÚlocalÚcliffsz4.4.5z	Ask Solemzauvipy@gmail.comzhttp://celeryproject.orgÚrestructuredtextz*task job queue distributed messaging actor)ÚCeleryÚ	bugreportÚshared_taskÚtaskÚTaskÚcurrent_appÚcurrent_taskÚmaybe_signatureÚchainÚchordÚchunksÚgroupÚ	signatureÚxmapÚxstarmapÚuuidz	{0} ({1})Úversion_info_t)ÚmajorÚminorÚmicroÚreleaselevelÚserialz(\d+)\.(\d+).(\d+)(.+)?é   é   Ú Ú
C_IMPDEBUG)Úbuiltinséÿÿÿÿc                 C   sP   |pt tdd d d… ƒdƒj}|r| d¡pd}td || ¡ƒ || ||||ƒS )NÚ	emarfteg_r%   r   Ú__name__Úunknownz-- {0} imports {1})ÚgetattrÚsysÚ	f_globalsÚgetÚprintÚformat)ÚnameÚlocalsÚglobalsÚfromlistÚlevelÚreal_importÚglobÚimporter_name© r7   úL/var/www/html/myproject/venv/lib/python3.10/site-packages/celery/__init__.pyÚdebug_import9   s   r9   TFÚkcah_acitats)r   )r
   )r   )r   )r   r   )	r   r   r   r   r   r   r   r   Úsubtask)r   c                 C   s”   t | ƒD ]8\}}| d¡r<|r.| d¡r.| d¡\}}}||v r.|r&|  S | |d    S |r<||v r<| |d    S qtd |pGg | pGg ¡ƒ‚)z¬Search argv for options specifying short and longopt alternatives.

    Returns:
        str: value for option found
    Raises:
        KeyError: if option not found.
    ú-z--ú=r   ú|)Ú	enumerateÚ
startswithÚ	partitionÚKeyErrorÚjoin)ÚargvÚ
short_optsÚ	long_optsÚiÚargr/   ÚsepÚvalr7   r7   r8   Ú_find_option_with_argV   s   
€rK   c                  C   sD   dd l } dd l} |  ¡  ttj dd¡ƒ}|r | j ||¡ d S d S )Nr   ÚEVENTLET_NOBLOCK)	ÚeventletÚeventlet.debugÚmonkey_patchÚfloatÚosÚenvironr,   ÚdebugÚhub_blocking_detection)rM   Úblockdetectr7   r7   r8   Ú_patch_eventleti   s   ÿrV   c                  C   sD   dd l } ddl m}m} | ¡  | jd dkr tdƒ}||_d S d S )Nr   )ÚmonkeyÚsignalrX   )ÚgeventrW   rX   Ú	patch_allÚversion_infoÚ
__import__)rY   rW   Úgevent_signalÚ_signalr7   r7   r8   Ú_patch_gevents   s   
ür_   c                 C   s¢   | r| nt j} |r|ndg}|r|ndg}|r|nttdœ}zt| ||ƒ}W n
 ty0   Y dS w z|| }W n	 ty@   Y nw |ƒ  ddlm} | |¡ dS )a  Apply eventlet/gevent monkeypatches.

    With short and long opt alternatives that specify the command line
    option to set the pool, this makes sure that anything that needs
    to be patched is completed as early as possible.
    (e.g., eventlet/gevent monkey patches).
    z-Pz--pool)rM   rY   r   )ÚconcurrencyN)	r*   rD   rV   r_   rK   rB   Úceleryr`   Úget_implementation)rD   rE   rF   ÚpatchesÚpoolÚpatcherr`   r7   r7   r8   Úmaybe_patch_concurrency   s&   	
ÿÿÿrf   Ú	by_module)r
   r   r   r   r   r   )
Ú	Signaturer   r   r   r   r   r   r;   r   r   r   )z
celery.appzcelery.app.taskzcelery._statezcelery.canvaszcelery.utilsÚdirectr   zcelery.taskÚ__package__ra   Ú__file__Ú__path__Ú__doc__Ú__version__Ú
__author__Ú__contact__Ú__homepage__Ú__docformat__r   ÚVERSIONÚSERIESÚVERSION_BANNERr[   r   r   r   )NN)NNNN)Grm   Ú
__future__r   r   r   rQ   Úrer*   Úcollectionsr   r"   r   rt   rn   ro   rp   rq   rr   Ú__keywords__Ú__all__r.   ru   r   ÚmatchÚgroupsÚ_tempÚintrs   r[   rR   r,   Úfiver$   r\   r9   ÚSTATICA_HACKr1   ÚupperÚ
celery.appr   Úcelery.app.baser
   Úcelery.app.utilsr   Úcelery.app.taskr   Úcelery._stater   r   Úcelery.canvasr   r   r   r   r   r   r   r   r;   Úcelery.utilsr   rK   rV   r_   rf   Úrecreate_moduler'   rk   rl   Ú
old_moduleÚ
new_moduler7   r7   r7   r8   Ú<module>   sÊ   	
ÿÿ*ÿ
ÿ,


ÿ!ÿ÷þóòòñññððïïïîîîíìëêéèç