Skip to content

Startup perf fix#370

Open
sleynsol wants to merge 2 commits into
mainfrom
startup-perf-fix
Open

Startup perf fix#370
sleynsol wants to merge 2 commits into
mainfrom
startup-perf-fix

Conversation

@sleynsol

Copy link
Copy Markdown
Contributor

No description provided.

sleynsol added 2 commits June 19, 2026 16:50
Constructing the PostHog client at import time spawned a consumer thread and a
blocking atexit flush, adding ~5s to the shutdown of every command (including
`mobilerun --help`) because importing mobilerun imports the telemetry module.
Create the client lazily on first capture/flush instead — telemetry behavior is
unchanged. Startup/exit drops from ~5.9s to ~0.7s.
@sleynsol sleynsol requested a review from RasulOs June 19, 2026 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant