Skip to content

v1.8.2

Pre-release
Pre-release

Choose a tag to compare

@github-actions github-actions released this 25 Jun 14:15

Pi Desktop v1.8.2 β€” Token Stats Fix πŸ”§

A patch release fixing stale token/cost display when switching between sessions via the content cache introduced in v1.8.1.

Note: This is a personal fork of gustavonline/pi-desktop.


πŸ› Fixes

Token usage now resets on cached session switch

After v1.8.1's session content cache, switching between sessions could leave the token ring, cost, and context-usage display showing the previous session's values instead of the newly-selected session.

Root cause: the cache-hit path in prepareForSessionSwitch was pre-setting the session-file marker to the new session, which caused refreshFromBackend's session-boundary detection to skip its sessionStats reset (the marker matched the incoming session, so the code thought nothing changed). The stale token/cost values from the prior session persisted in the composer.

Fix: removed the pre-assignment so the boundary detection fires normally β€” sessionStats resets to nulls, then the async stats refresh repopulates with the correct session's data.


πŸ“¦ Download

This fork builds Windows (.exe) and macOS (.dmg).

⚠️ Unsigned builds

Windows: Click More info β†’ Run anyway on SmartScreen.

macOS: xattr -cr "/Applications/Pi Desktop.app" after mounting.


βš™οΈ Requirements

  • Pi Coding Agent CLI: npm install -g @earendil-works/pi-coding-agent
  • Node.js β‰₯ 22

πŸ™ Credits

Built on gustavonline/pi-desktop.

πŸ“„ License

MIT β€” see LICENSE.