Skip to content

refactor: remove taskHistory from GlobalState type and webview state #1544

Description

@edelauna

Part of #1541. Cleanup after #1542 and #1543.

Remove taskHistory from the GlobalState zod schema so the compiler enforces that nothing new can accidentally read the key. Also removes the now-redundant destructure omissions in the lightweight state-post helpers.

Changes

  • packages/types/src/global-settings.ts line 113: remove taskHistory field from GlobalState schema
  • ClineProvider.ts lines 2719, 2758: remove { taskHistory: _omit, ...rest } destructures in postChatStateToWebview / postTaskStateToWebview (become no-ops once the key is gone)
  • ClineProvider.ts lines ~704–715: remove or guard the legacy migration block that reads globalState.get<HistoryItem[]>("taskHistory") (can be kept for one release cycle to drain old installs, then deleted)

Safety

Land last, after #1542 and #1543. The type removal makes the compiler catch any future accidental reads at build time.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions