apache / apache/maka

refactor(storage): remove the unused legacy Usage session scanner

Open
#4,059 3 comments 0 reactions 1 assignee Claimed by @heeoneie View on GitHub
good first issue help wanted
Dominant language
TypeScript
Stars
5.4k
Forks
502
Avg merge
1d 2h
Merged PRs (30d)
715

Description

## Context

Desktop Usage now reads canonical data through the selected Runtime Host. The legacy Storage path remains in SettingsStore, but repository-wide production-call-site inspection finds no consumer outside its own definition and dedicated tests.

## Scope

- Remove SettingsStore.usageStats and its readUsageStats import.
- Remove packages/storage/src/usage-stats-store.ts.
- Remove dedicated legacy-reader tests and stale public-entrypoint expectations.
- Verify repository-wide references, package entrypoints, Storage tests, Desktop tests, typecheck, and dependency analysis.

## Non-goals

- Removing SettingsStore itself.
- Removing projectDesktopUsageStats; it still projects Host Session IDs into Desktop namespaces.
- Changing Runtime Host Usage, provenance, pricing, or UI behavior.
- Changing the Runtime Host wire contract or compatibility epoch.

## Acceptance

- No production or test reference remains to the legacy scanner.
- Desktop Usage continues to use the selected Runtime Host.
- Storage and Desktop focused validation remains green.

## Related

- #2128 tracks Usage coverage/presentation.
- #2641 is the superseded broad implementation branch.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.