Skip to content

fix: read archived session usage without source sync - #1163

Draft
shunkakinoki wants to merge 1 commit into
kenn-io:mainfrom
shunkakinoki:agent/kyber-yc50ay-usage-readonly
Draft

shunkakinoki wants to merge 1 commit into
kenn-io:mainfrom
shunkakinoki:agent/kyber-yc50ay-usage-readonly

Conversation

@shunkakinoki

Copy link
Copy Markdown
Contributor

Request agentsview session usage --no-sync when collecting usage so background cost lookups read the archive without requesting source synchronization. Full subagent attribution remains enabled, and missing sessions or absent token/cost data still return no usage for existing retry handling.

This requires a released AgentsView CLI with session usage --no-sync support. Unsupported CLIs report the provider error; the legacy token-use fallback is removed because it cannot guarantee the no-sync contract. The configured HTTP endpoint path is unchanged. Keep this draft pending the companion AgentsView change and a release containing it.

T3 thread

@roborev-ci

roborev-ci Bot commented Sep 12, 2026

Copy link
Copy Markdown

roborev: Combined Review (ec247cd)

Verdict: Changes require fixes for 1 finding.

Medium

  • internal/tokens/tokens.go:220: --no-sync is passed unconditionally, so AgentsView versions that support session usage but not this flag return an error instead of providing token counts, contradicting documented older-version support. On an unsupported-flag error, fall back to the prior compatible usage command and legacy token-use path where needed, or remove older-version support and update the affected documentation.

    Reported by: codex


Reviewers: 2 done | Synthesis: codex, 6s | Total: 1m48s

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant