Skip to content
This repository was archived by the owner on Sep 15, 2026. It is now read-only.

Throttle CodexBar session refreshes - #48

Merged
VdustR merged 2 commits into
mainfrom
codex/issue-47-throttle-session-refresh
Sep 2, 2026
Merged

VdustR merged 2 commits into
mainfrom
codex/issue-47-throttle-session-refresh

Conversation

@VdustR

@VdustR VdustR commented Sep 2, 2026

Copy link
Copy Markdown
Owner

TL;DR

Reduce near-continuous CodexBar process churn by increasing Agent Touch Bar’s default session refresh TTL from 0.75 to 10 seconds. Session state remains bounded to an interactive update interval.

Closes #47

Problem

codexbar sessions --json-v2 takes 1.5–5.1 seconds on the affected Mac. Agent Touch Bar waited only 0.75 seconds after each completed collection before starting another, so a CodexBar child process was present nearly continuously.

Change

  • Set the default session TTL to 10 seconds.
  • Name the default as DEFAULT_SESSION_TTL and lock it with a regression test.
  • Document that the interval starts after the previous collection completes.
  • Preserve immediate initial collection and the existing no-overlap guard.

Verification

  • PYTHONPATH=src python3 -m unittest discover -s tests -v — 72 tests passed
  • pyright src tests — 0 errors
  • python3 -m compileall -q src tests
  • swift test --package-path native — 9 tests passed
  • shell syntax checks for build, install, uninstall, and setup scripts
  • git diff --check

Validation boundary

The configuration and regression tests verify the new cadence contract. Live installed-process cadence and CPU readback remain for post-merge installation verification on the affected Mac.

@changeset-bot

changeset-bot Bot commented Sep 2, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 0843c46

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@VdustR
VdustR marked this pull request as ready for review September 2, 2026 03:02
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 2, 2026

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-02T03:06:12.902496Z 0843c46 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@VdustR

VdustR commented Sep 2, 2026

Copy link
Copy Markdown
Owner Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 🚀

Reviewed commit: 0843c46a23

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@VdustR
VdustR merged commit 8ebed12 into main Sep 2, 2026
1 check passed
@VdustR
VdustR deleted the codex/issue-47-throttle-session-refresh branch September 2, 2026 03:07
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Throttle expensive CodexBar session refreshes

1 participant