+
    {ij                        R t ^ RIHt ^ RIt^ RIHt ^ RIHtHtH	t	 ^ RI
Ht ]'       d   ^ RIHt ^ RIHt R R	 ltR
 R ltR R ltR R ltR# )zHealth check: Base environment protection.

Checks if the base environment is protected (frozen) and offers to
protect it by cloning to a default environment and resetting base.
)annotationsN)TYPE_CHECKING)OK_MARKPREFIX_FROZEN_FILEX_MARK)
PrefixData)	Namespace)ConfirmCallbackc                    V ^8  d   QhRRRR/# )   prefixstrreturnbool )formats   "Hlib/python3.14/site-packages/conda_self/health_checks/base_protection.py__annotate__r      s                c                (    V \         P                  8H  # )z2Check if the given prefix is the base environment.)sysr   )r   s   &r   is_base_environmentr      s    SZZr   c                   V ^8  d   QhRR/# )r   r   r   r   )r   s   "r   r   r      s        4  r   c                 ~    \        \        P                  4      P                  \        ,          p V P                  4       # )z4Check if the base environment is protected (frozen).)r   r   r   prefix_pathr   exists)frozen_files    r   is_base_protectedr      s+    SZZ(447IIKr   c               $    V ^8  d   QhRRRRRR/# )r   r   r   _verboser   r   Noner   )r   s   "r   r   r       s!     ; ;# ; ;$ ;r   c                    \        V 4      '       g   \        R4       R# \        4       '       d   \        \         R24       R# \        \         R24       \        R4       R# )zhHealth check: Verify base environment protection status.

Only runs when checking the base environment.
z;Skipping base protection: not running on base environment.
Nz) Base environment is protected (frozen).
z$ Base environment is not protected.
z(Run 'conda doctor --fix' to protect it.
)r   printr   r   r   )r   r   s   &&r   checkr#       sM    
 v&&LM	CDE=>?9:r   c               (    V ^8  d   QhRRRRRRRR/# )	r   r   r   argsr   confirmr	   r   intr   )r   s   "r   r   r   0   s.     r r r9 r r3 rr   c           	     j   ^ RI Hp ^ RIHp ^RIHp \        V 4      '       g   \        R4       ^ # \        4       '       d   \        R4       ^ # ^ RI	p^ RI
p^ RIHpHp	 ^ RIHp
 ^ R	IHpHp ^ R
IHp ^ RIHp ^ RIHp ^RIHpHp ^RIHp ^RIHpHp TpRpV! \>        P@                  4      pVPC                  \E        V4      RVPF                  R7      pVPH                  '       gG   \        RV R24       VPJ                  '       d&   \        R\M        VPJ                  4       RV R24       V! R4       VR,          V,          pVPO                  4       p\P        PR                  ! V4      pVPU                  4       '       d    V! RV R24       V! VPV                  4       M,VPO                  4       '       d   V! RVPV                   R24       VR,          V,          p VPX                  P[                  R4      pVPH                  '       g   \        RV 24       VP]                  VP_                  V4      4       VPH                  '       g   \        R!V R"24       \        R#4       VPH                  '       d   V	! VPa                  4       4      MV! 4       pT;_uu_ 4        V! \E        V4      \E        VPV                  4      R$R%R&7       V'       d   V! 4       V! V4      ,          pV! VR'7       MV! V! 4       R'7       RRR4        V\b        ,          p T P]                  V'       d   VPe                  R(V/4      MR)4       TPH                  '       g   \        R+T R,24       T
Pi                  4       ;_uu_ 4       p"T"Pk                  R-\E        TPV                  4      4       RRR4       TPH                  '       g   \        R.T 24       ^ #   T d"    TPH                  '       g   \        R 4        ELi ; i  + '       g   i     L; i  \f         d   p!T! R*T! 24      T!hRp!?!ii ; i  + '       g   i     L; i)/zFix: Protect the base environment.

This clones the base environment to a new 'default' environment,
resets base to essentials, and freezes it.
)Path)context)DEFAULT_ENV_NAMEz*Skipping: not running on base environment.z&Base environment is already protected.N)nullcontextredirect_stdout)ConfigurationFile)CondaOSErrorCondaValueError)rm_rf)	clone_env)Environment)RESET_FILE_BASE_PROTECTIONRESET_FILE_INSTALLER)permanent_dependencies)names_from_explicitresetz3Protected by Base Environment Protection health fixbase)nameplatformzThis will clone 'base' to 'z', reset base, and freeze it.z%  Warning: Base environment contains zg non-conda package(s) that will become non-functional after reset.
  They are preserved in the cloned 'z' environment.zProceed?z
conda-metazEnvironment 'z&' already exists. Remove and recreate?zDirectory exists at 'z'. Continue?explicitzSaving snapshot to z1  Skipping snapshot (non-conda packages present).zCloning 'base' to 'z'...zResetting 'base' environment...FT)verbosequiet)uninstallable_packagesmessage zCould not protect environment: z Setting default environment to ''default_activation_envz,
Done! To use your packages: conda activate )6pathlibr)   conda.base.contextr*   	constantsr+   r   r"   r   iojson
contextlibr,   r-   conda.cli.condarcr.   conda.exceptionsr/   r0   conda.gateways.disk.deleter1   
conda.miscr2   conda.models.environmentr3   r4   r5   queryr6   r8   r7   r   r   from_prefixr   subdirr>   external_packageslenr   r   	from_nameis_environmentr   plugin_manager"get_environment_exporter_by_format
write_textexportStringIOr   dumpsOSErrorfrom_user_condarcset_key)#r   r%   r&   r)   r*   r+   rG   rH   r,   r-   r.   r/   r0   r1   r2   r3   r4   r5   r6   r7   r8   default_envr@   base_prefixenvinstaller_snapshotuse_snapshotdest_prefix_datasnapshot_fileexplicit_exporter
stdout_ctxkeepfrozen_patheconfigs#   &&&                                r   fixrl   0   s    *,v&&:;6773>0$4L.2"KCGszz"K

!
!Kv " C ===+K=8UVW   7C<Q<Q8R7S T77Bm>S
 J %|36JJ%,,.L "++K8&&((-},RST**+		 	 	"	"'(8(D(D'E\RS  ,.1KKM	G#22UU
 }}}'78  !2!9!9#!>?
 ===#K=56/0 4;===/kmJ	 ,,-		
 )+.ABT.UUD.)?)AB 
I!$667tzz9g*>?PRS
 ===0Q?@		,	,	.	.&/5E5Q5Q1RS 
/ ====k]KLM  G}}}EFG 
"  I<QC@AqHI 
/	.sU   ,O 
.O AO0P #P 5&P"O-O-,O-0P 	PPP"P2	)__doc__
__future__r   r   typingr   conda.base.constantsr   r   r   conda.core.prefix_datar   argparser   conda.plugins.typesr	   r   r   r#   rl   r   r   r   <module>rt      s<    # 
   D D -"3 
 ; rr   