o
    i                     @   sT   d dl Z d dlmZ d dlmZ G dd deZG dd deZG dd	 d	eZdS )
    N)assert_spawning)BaseProcessc                       s>   e Zd ZdZddddi dddf fdd	Zedd Z  ZS )	LokyProcessZlokyN Fc	           	         s<   t  j||||||d |d u ri n|| _| j| _|| _d S )N)grouptargetnameargskwargsdaemon)super__init__envZauthkeyinit_main_module)	selfr   r   r   r	   r
   r   r   r   	__class__r   t/var/www/html/eduruby.in/lip-sync/lip-sync-env/lib/python3.10/site-packages/joblib/externals/loky/backend/process.pyr      s   
zLokyProcess.__init__c                 C   s2   t jdkrddlm} || S ddlm} || S )Nwin32   )Popen)sysplatformZpopen_loky_win32r   Zpopen_loky_posix)Zprocess_objr   r   r   r   _Popen'   s
   
zLokyProcess._Popen)__name__
__module____qualname___start_methodr   staticmethodr   __classcell__r   r   r   r   r      s    r   c                       s.   e Zd ZdZddddi df fdd	Z  ZS )LokyInitMainProcessZloky_init_mainNr   c              	      s   t  j||||||dd d S )NT)r   r   r   r	   r
   r   r   )r   r   )r   r   r   r   r	   r
   r   r   r   r   r   3   s   	
zLokyInitMainProcess.__init__)r   r   r   r   r   r   r   r   r   r   r    0   s    r    c                   @   s   e Zd Zdd ZdS )AuthenticationKeyc                 C   s2   zt |  W n ty   tdw tt| ffS )NzGPickling an AuthenticationKey object is disallowed for security reasons)r   RuntimeError	TypeErrorr!   bytes)r   r   r   r   
__reduce__M   s   zAuthenticationKey.__reduce__N)r   r   r   r%   r   r   r   r   r!   L   s    r!   )	r   Zmultiprocessing.contextr   Zmultiprocessing.processr   r   r    r$   r!   r   r   r   r   <module>   s   #