+
    ‚°ñjÓ  ã                  óÈ   a € 0 t $ R t^ RIHt ^ RIt^ RIHt  ^ RIHt Rt]! RRR7       ! R	 R
4      4       tR R ltRR R lltR#   ]	 d   t
Rt]
tR]R&    Rt
A
L<Rt
A
ii ; i)a£  Hashes a file and returns the stat it proved describes those exact bytes.
Identity, size and mtime are sampled before the read, on the open handle at
both ends of it, and once more afterwards; if any sample disagrees the file
moved under the reader and the result is discarded rather than returned.
Callers persist the stat that comes back, which is what makes a stored hash and
a stored size describe one observation.
)ÚannotationsN)Ú	dataclass)Úblake3zImportError | NoneÚ_BLAKE3_IMPORT_ERRORT)ÚfrozenÚslotsc                  ó@   € ] tR t^t$ R]R&   R]R&   R]R&   R]R&   RtR# )Ú	_SnapshotÚintÚdevÚinoÚmtime_nsÚsize© N)Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__annotations__Ú__static_attributes__r   ó    ÚEC:\Ai_Coding\apps\studio\ComfyUI\app\assets\services\snapshot_hash.pyr	   r	      s   ‡ à	ƒHØ	ƒHØƒMØ
‡Ir   r	   c               ó    € V ^8„  d   QhRRRR/# )é   Ústat_resultzos.stat_resultÚreturnr	   r   )Úformats   "r   Ú__annotate__r      s   € ÷ ñ ˜>ð ¨iñ r   c                óp   € \        V P                  V P                  V P                  V P                  R 7      # ))r   r   r   r   )r	   Úst_devÚst_inoÚst_mtime_nsÚst_size)r   s   &r   Ú	_snapshotr#      s3   € ÜØ×ÑØ×ÑØ×(Ñ(Ø× Ñ ô	ð r   c               ó$   € V ^8„  d   QhRRRRRR/# )r   ÚpathÚstrÚ
chunk_sizer
   r   z!tuple[str, os.stat_result] | Noner   )r   s   "r   r   r   (   s$   € ÷ 0ñ 0Ø
ð0Øð0à&ñ0r   c                ó¶  € \         f   \        R\         24      \        h \        \        P
                  ! V 4      4      p\        4       p\        V R4      ;_uu_ 4       p\        \        P                  ! VP                  4       4      4      pVP                  V4      ;p'       d   VP                  V4       K,  \        \        P                  ! VP                  4       4      4      pR R R 4       \        P
                  ! V 4      p\        T4      p	\        TXXT	04      ^8w  d   R # TP                  4       T3#   + '       g   i     LY; i  \         d     R # i ; i)Nz@blake3 is required for asset hashing but could not be imported: Úrb)r   ÚModuleNotFoundErrorr   r#   ÚosÚstatÚopenÚfstatÚfilenoÚreadÚupdateÚFileNotFoundErrorÚlenÚ	hexdigest)
r%   r'   Úpre_statÚhasherÚfileÚ	open_statÚchunkÚpost_hash_statÚpost_stat_resultÚ	post_stats
   &&        r   Úsnapshot_hashr=   (   s  € ô ‚~Ü!ØNÜ#Ð$ð&ó
ô $ð	$ð
ÜœRŸWšW T›]Ó+ˆÜ“ˆÜ�$˜×Ô Ü!¤"§(¢(¨4¯;©;«=Ó"9Ó:ˆIØŸ9™9 ZÓ0Ð0�%Ö0Ø—‘˜eÖ$Ü&¤r§x¢x°·±³Ó'>Ó?ˆN÷	 ô
 Ÿ7š7 4›=Ðô Ð*Ó+€IÜ
ˆH�i °Ð;Ó<ÀÔAÙØ×ÑÓÐ/Ð/Ð/÷ ×ûô ô Úðús1   ¡=E	 ÁAD6Â%A D6Ã%E	 Ä6E	ÅE	 Å	EÅE)i  € )Ú__conditional_annotations__Ú__doc__Ú
__future__r   r+   Údataclassesr   r   r   ÚImportErrorÚerrorr   r	   r#   r=   )r>   s   @r   Ú<module>rD      s{   øðôõ #ã 	Ý !ð Ýð
  Ðñ �$˜dÔ#÷ð ó $ðõ÷0ñ 0øð1 ô 5Ø€FØ/4ÐÐ,×4Ð4ûð5ús   ˜A ÁA!Á	AÁA!