+
    jHàju  ã                  ó¼   a € 0 t $ R t^ RIHt ^ RIHtHt ^ RIHt ^ RI	H
t
HtHt ]! RR7       ! R R4      4       t]! R	R
R7      tR]R&   R R ltR R ltR R ltR
# )ud  Which cron execution the current code runs inside, for plugins (``ctx.current_cron_execution()``).

The scheduler binds it once it has won the execution's ``claimed`` â†’ ``running`` transition (or a
restart-safe worker adopted it) and resets it when the fire ends. It is a ContextVar, so it follows
the agent onto the threads the scheduler already runs it on via ``contextvars.copy_context()`` and
never leaks to another concurrently firing job or profile. Model output cannot reach it: tool
subprocesses do not share the interpreter. Delegated children read ``None`` â€” they are not the
scheduled occurrence.
)Úannotations)Ú
ContextVarÚToken)Ú	dataclass)ÚAnyÚMappingÚOptionalT)Úfrozenc                  ó^   € ] tR t^t$ R]R&   R]R&   R]R&   R]R&   R]R&   R]R&   R]R	&   R
tR# )ÚCronExecutionÚstrÚjob_idÚjob_nameÚexecution_idÚsourcezOptional[str]Úscheduled_instantÚ
started_atÚprofile© N)Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__annotations__Ú__static_attributes__r   ó    Ú</home/ubuntu/.hermes/hermes-agent/cron/execution_identity.pyr   r      s(   ‡ àƒKØƒMØÓØƒKØ$Ó$ØÓØ‡Lr   r   Úhermes_cron_executionN)Údefaultz#ContextVar[Optional[CronExecution]]Ú_CURRENTc               ó(   € V ^8„  d   QhRRRRRRRR/# )é   ÚjobzMapping[str, Any]r   r   ÚrecordÚreturnr   r   )Úformats   "r   Ú__annotate__r&      s+   € ÷ ñ Ð/ð ¸sð ÐL]ð Ðbgñ r   c                ó|  € ^ RI Hp \        P                  \	        \        V R,          4      \        V P                  R4      ;'       g
    V R,          4      \        V4      \        VP                  R4      ;'       g    R4      VP                  R4      VP                  R4      V! R4      ;'       g    RR	7      4      # )
zRBind this fire's identity from *record*, the ledger row of the running transition.)Úcurrent_profile_nameÚidÚnamer   Ú r   r   r   )r   r   r   r   r   r   r   )Úhermes_cli.profilesr(   r   Úsetr   r   Úget)r"   r   r#   r(   s   &&& r   Úenter_cron_executionr/      sŽ   € å8ä�<‰<œÜ�3�t•9‹~Ü�S—W‘W˜V“_×1Ð1¨¨D­	Ó2Ü˜Ó&Ü�6—:‘:˜hÓ'×-Ð-¨2Ó.Ø Ÿ*™*Ð%8Ó9Ø—:‘:˜lÓ+Ù$ YÓ/×<Ð<°9ôó ð r   c               ó    € V ^8„  d   QhRRRR/# )r!   ÚtokenzOptional[Token]r$   ÚNoner   )r%   s   "r   r&   r&   .   s   € ÷ ñ ˜ð °4ñ r   c                ó<   € V e   \         P                  V 4       R # R # )N)r   Úreset)r1   s   &r   Úexit_cron_executionr5   .   s   € ØÒÜ�‰�uÖñ r   c               ó   € V ^8„  d   QhRR/# )r!   r$   zOptional[CronExecution]r   )r%   s   "r   r&   r&   3   s   € ÷ Dñ DÐ 7ñ Dr   c                 óT   € ^ RI Hp  V ! 4       '       d   R# \        P                  4       # )é    ©Úis_delegated_child_contextN)Úagent.delegation_contextr:   r   r.   r9   s    r   Úcurrent_cron_executionr<   3   s   € ÝCá-×/Ò/ˆ4ÐC´X·\±\³^ÐCr   )Ú__conditional_annotations__Ú__doc__Ú
__future__r   Úcontextvarsr   r   Údataclassesr   Útypingr   r   r   r   r   r   r/   r5   r<   )r=   s   @r   Ú<module>rC      s`   øðôõ #ç )Ý !ß )Ñ )ñ �$Ô÷ð ó ðñ 1;Ð;RÐ\`Ô0a€Ð
-Ó aõõ÷
Dr   