Skip to content

fix(tui): unblock main — picker_test for switchProviderModel 4-value return#589

Merged
kevincodex1 merged 1 commit into
mainfrom
fix/tui-picker-test-4ret
Jul 8, 2026
Merged

fix(tui): unblock main — picker_test for switchProviderModel 4-value return#589
kevincodex1 merged 1 commit into
mainfrom
fix/tui-picker-test-4ret

Conversation

@Vasanthdev2004

@Vasanthdev2004 Vasanthdev2004 commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

main's Smoke is red. #568 added a fourth return value (bool) to switchProviderModel in internal/tui/command_center.go and updated every call site except one — internal/tui/picker_test.go:771 still assigns three values:

assignment mismatch: 3 variables but m.switchProviderModel returns 4 values

That fails the internal/tui test build on all three Smoke jobs, so every open PR is blocked behind branch protection.

One-line fix: add the missing receiver so the test matches the signature the other five call sites already use. No runtime change.

Merge unblocks CI on the rest of the queue.

Summary by CodeRabbit

  • Tests
    • Updated automated coverage to match a recent change in the app’s provider/model switching behavior.

@coderabbitai

coderabbitai Bot commented Jul 8, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 6f3b0378-ddab-4e92-88e9-ed82973f42ec

📥 Commits

Reviewing files that changed from the base of the PR and between 6eb4b89 and ab26dbf.

📒 Files selected for processing (1)
  • internal/tui/picker_test.go

Walkthrough

A test assertion in picker_test.go was updated to accommodate an additional return value from the switchProviderModel function call, changing a single ignored placeholder to two ignored placeholders.

Changes

Test Update

Layer / File(s) Summary
Update test call to match new return signature
internal/tui/picker_test.go
The switchProviderModel call in TestSwitchProviderModelRecordsRecentHistory now assigns two ignored return values instead of one to match the updated function signature.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Possibly related PRs

  • Gitlawb/zero#568: Directly relates via the same switchProviderModel return signature change and recent-history recording behavior tested in this PR.

Suggested reviewers: gnanam1990, anandh8x

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately reflects the test fix for switchProviderModel’s updated four-value return and the goal of unblocking main.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/tui-picker-test-4ret

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

Zero automated PR review

Verdict: No blockers found

Blockers

  • None found.

Validation

  • [pass] Diff hygiene: git diff --check
  • [pass] Tests: go test ./...
  • [pass] Build: go run ./cmd/zero-release build
  • [pass] Smoke build: go run ./cmd/zero-release smoke

Scope

Head: ab26dbf129e5
Changed files (1): internal/tui/picker_test.go

This deterministic review checks validation status and basic diff hygiene. A human reviewer still owns product judgment and design quality.

@Vasanthdev2004

Copy link
Copy Markdown
Collaborator Author

@kevincodex1 merge this this is the issue of getting ci fails

@kevincodex1 kevincodex1 merged commit 8f15650 into main Jul 8, 2026
9 checks passed
yanalialiuk pushed a commit to yanalialiuk/zero that referenced this pull request Jul 8, 2026
…itlawb#589)

Gitlawb#568 added a bool return to switchProviderModel (model, string, bool,
tea.Cmd) and updated every call site except picker_test.go:771, which
still assigned three values. That broke the internal/tui test build
and turned Smoke red on main. Add the missing receiver here.
CengSin pushed a commit to CengSin/zero that referenced this pull request Jul 8, 2026
fix(tui): update picker_test for switchProviderModel 4-value return (Gitlawb#589)

tea.Cmd) and updated every call site except picker_test.go:771, which
still assigned three values. That broke the internal/tui test build
and turned Smoke red on main. Add the missing receiver here.

fix: make HashTree self-delimiting and fix skills format-output test
- fscopy: tag dir/file type and byte size in HashTree so the stream is
  self-delimiting and two different trees cannot hash identically.
- skills: match the %q-quoted skills root in the format-output test so it
  no longer fails on Windows path escaping.

fix: make HashTree self-delimiting and fix skills format-output test                                                         │  ✓ exec_command
                                                                                                                             │
- fscopy: tag dir/file type and byte size in HashTree so the stream is                                                       │
  self-delimiting and two different trees cannot hash identically.                                                           │
- skills: match the %q-quoted skills root in the format-output test so it                                                    │
  no longer fails on Windows path escaping.
@coderabbitai coderabbitai Bot mentioned this pull request Jul 8, 2026
5 tasks
#568 added a bool return to switchProviderModel (model, string, bool,
tea.Cmd) and updated every call site except picker_test.go:771, which
still assigned three values. That broke the internal/tui test build
and turned Smoke red on main. Add the missing receiver here.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants