Skip to content

fix: clean up Tempo sessions after use#15093

Merged
mattsse merged 3 commits into
foundry-rs:masterfrom
0xKarl98:cleanup
Jun 7, 2026
Merged

fix: clean up Tempo sessions after use#15093
mattsse merged 3 commits into
foundry-rs:masterfrom
0xKarl98:cleanup

Conversation

@0xKarl98
Copy link
Copy Markdown
Collaborator

@0xKarl98 0xKarl98 commented Jun 7, 2026

Step closer to OSS-162 ,

Previously, cleanup could fail during revoke preflight and leave the session entry active with local key material still present. This kept the session usable locally after the intended command lifecycle had ended.

Now treat revoking as a cleanup state that clears local session key material while keeping the session metadata available for revoke retries.

Also:

  • Marks successful cast wallet session --for runs as revoking before revoke preflight, so local key material is erased even if on-chain revoke must be retried.
  • Keeps failed wrapped commands retiring the local session as failed.
  • Preserves existing terminal statuses instead of downgrading them during cleanup.
  • Adds forge script --session as a convenience alias for --tempo.session.
  • Makes the new alias participate in Tempo session detection, including Tempo network selection and the --unlocked conflict check.
  • Updates tests for revoking key cleanup and forge script --session parsing/behavior.

Copy link
Copy Markdown
Member

@mattsse mattsse left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@mattsse mattsse merged commit e0ef56e into foundry-rs:master Jun 7, 2026
19 checks passed
@github-project-automation github-project-automation Bot moved this to Done in Foundry Jun 7, 2026
@0xKarl98 0xKarl98 deleted the cleanup branch June 7, 2026 16:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants