Conversation
…ge API The PI-Desktop host now exposes a read-only usage facts surface (pi.usage.listTurns, host PR vastsa/PI-Desktop#503). This switches the plugin's PI-Desktop source from reading pi.sqlite directly to that contract: keyset-paginated completed turns in at-most-365-day windows, walking backward until an empty window, with turnId dedup across page and window seams. - usage.read is declared in the manifest; on hosts without the surface the plugin falls back to the previous local read, so 0.5.0 stays compatible with older releases - soft-deleted sessions are excluded by the contract (a small accounting fix over the direct read, which had no deleted_at filter) - the theme, language, and appearance paths are unchanged Tests: the manifest assertions move from pinning the absence of usage.read to asserting the formal contract usage; the API adapter gets its own unit tests (window walk, cursor paging, dedup, 8-window ceiling, fallback routing); an on-load test's fixed sleep is replaced by polling for the scan's terminal state, which fixes a pre-existing flake on Node 25.
|
@muzimu217 is attempting to deploy a commit to the vastsa's projects Team on Vercel. A member of the Team first needs to authorize it. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Reads PI-Desktop turns through the formal read-only usage facts surface
(
pi.usage.listTurns, host PR vastsa/PI-Desktop#503) instead of openingpi.sqlitedirectly.usage.readis declared in the manifest; on hosts without the surfacethe plugin falls back to the previous local read, so 0.5.0 remains
compatible with older releases
no
deleted_atfilter — a small accounting fix)Implementation
backward until an empty window, 8-window ceiling
window seams
counters (the contract exposes the counters, not a precomputed total)
Tests
usage.read; theformer negative assertion (which pinned the direct-read era) is replaced
by positive assertions on the formal contract usage
fallback routing (hosts without the surface)