Repository navigation
feat(chat): migrate to charm v2 stack (wish/v2 v2.0.6) — #17343 slice 3 - #17420
Merged
Merged
Conversation
pkgs/chat imported wish only for bubbletea/logging middleware and never registered the SCP middleware (dependency-presence alert #328), but its go.mod pinned the vulnerable wish v1.4.7. Migrate to charm.land/wish/v2 v2.0.6 + charm.land/ssh v0.4.3 + bubbletea/bubbles/ lipgloss v2: - wish/v2 bubbletea MiddlewareWithProgramHandler no longer takes a termenv color profile (the v2 middleware derives options from the session); termenv import dropped. - Model ported to bubbletea v2: View() returns tea.View, key handling switches on tea.KeyPressMsg strings (ctrl+c/esc quit, enter send — same bindings as the v1 tea.KeyMsg Type switch). - bubbles v2: viewport options constructor; textarea styles via Styles()/SetStyles (Focused.CursorLine reset preserved). - Tests ported to the v2 message types (KeyPressMsg{Code: KeyEnter}, recordingModel View() tea.View); all 14 pass. wish no longer appears in pkgs/chat's go.mod/go.sum, removing alert #328's dependency-presence basis. Refs #17343.
|
Important Review skippedBot user detected. To trigger a single review, invoke the
|
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.
Refs #17343 — slice 3 (chat) of the charm-v2 migration. pkgs/tea landed in PR #17389; pkgs/launcher is blocked on the unpublished wishlist v2 (recorded on #17343, comment 7287929441).
What changes
pkgs/chat pinned the vulnerable
github.com/charmbracelet/wishv1.4.7 for bubbletea/logging middleware only (it never registers the SCP middleware — dependency-presence alert #328). This migrates it to the charm v2 stack, mirroring the tea/identity slices:charm.land/wish/v2v2.0.6,charm.land/sshv0.4.3,charm.land/bubbletea/v2v2.1.3,charm.land/bubbles/v2v2.1.1,charm.land/lipgloss/v2v2.0.6.github.com/charmbracelet/wishno longer appears in pkgs/chat's go.mod/go.sum.MiddlewareWithProgramHandlerno longer takes a termenv color profile (options derive from the session); the termenv import is dropped.View()returnstea.View; key handling switches ontea.KeyPressMsgstrings —ctrl+c/escquit andentersend, the same bindings the v1tea.KeyMsgType switch implemented (including the chat: pressing Enter on an empty input broadcasts an empty message to every session #3273 empty-message guard, untouched).Styles()/SetStyles(the Focused.CursorLine reset is preserved).Verification
ok. Localgo build+go vetclean.KeyPressMsg{Code: tea.KeyEnter}, recording modelView() tea.View); no test logic changed.{ "direct_parent": null, "links": [], "lineage": { "design": null, "roadmap_item": null, "priority": null }, "pm_meta": 1, "provenance": { "queue_id": null, "scheduled_start": null, "picked_up_at": null, "work_started_at": null, "created_at": "2026-11-30T18:31:41Z", "session_id": null, "lane": null, "host": "htch-runtime", "worktree": "/home/hatch", "model": null, "lane_start_issues": [], "workspace_ref": { "kind": "worktree", "id": "/home/hatch", "repo": "developing-today/code", "branch": "main", "sha": "1afb80aa405c56b71c8a63176670cb22ba449a92" }, "auth_subject": "xaltha", "stamped_by": "fleet 0.1.0 (native)" } }Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.