Skip to content

fix: 0.13 backport, Windows gateway start and Feishu import stall (#38025, #37927) - #39396

Closed
buluoray wants to merge 2 commits into
release/0.13.0from
crew/slack/backport-0.13-p0-1119
Closed

buluoray wants to merge 2 commits into
release/0.13.0from
crew/slack/backport-0.13-p0-1119

Conversation

@buluoray

Copy link
Copy Markdown
Contributor

Problem / Motivation

Goal: 0.13 users get two fixes Bolin flagged as P0 when #39387 replaced #39342: the Windows desktop app starts its gateway when netstat cannot finish, and a slow Feishu SDK import no longer restarts the gateway.

Both are merged on main but in neither #39387 nor the release branch. Bolin named them in his closing comment on #39342 as P0 fixes that "cherry-pick cleanly onto #39387's base and can follow separately".

Why it matters

PR what breaks for 0.13 users without it
#37927 With Feishu enabled on a filesystem where importing the lark-oapi SDK takes tens of seconds, the import trips the stall watchdog. The gateway restarts in a loop, taking every other channel and the dashboard down with it.
#38025 On Windows, when the desktop app's netstat port check cannot finish, the app stops at "can't verify what's using port 5476". The dialog only offers Quit and reopening repeats the check, so the user is locked out without a terminal.

Not a goal

What changed (motivation → approach → change)

Two clean git cherry-pick -x of the main commits, in main's order, no conflicts and no prerequisites:

Backwards compatibility

Compatible: both are code already on main; nothing that works on 0.13 stops working.

Removes nothing: no setting, route or stored value changes.

Tests

The tests each fix added come with it. On this branch:

  • test/test_feishu*.py: 286 passed, 1 skipped. flake8 and mypy on src/kiro_crew/feishu pass.
  • Electron gateway-stop, windows-port and windows-recovery-port-probe tests (node test runner): 105 passed, 1 skipped.

Proof: not provable -- other: a backport of fixes whose proof ran on their own main PRs (#37927, #38025)

Manual verification

N/A — each fix was verified on its own main PR; this PR only carries them.

Related Issues

Flagged by Bolin on #39342 when #39387 replaced it.

Sibling sweep

Siblings: none -- a backport; each fix's sweep is recorded on its own main PR

Pattern harvest

Not generalizable: a backport; the patterns are recorded on #37927 and #38025

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title (feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

jeeshofone and others added 2 commits November 19, 2026 04:50
…not trip the stall watchdog (#37927)

Fixes #37902

(cherry picked from commit b5d70c5)
@buluoray
buluoray requested review from a team and KiroCrewCaptain as code owners November 19, 2026 04:53
@buluoray
buluoray requested review from cruisercohen and removed request for a team November 19, 2026 04:53
@github-actions github-actions Bot added the readiness: checking Automated validation is still running label Nov 19, 2026
@github-actions

Copy link
Copy Markdown
Contributor

UX Review (Opus 5.5) — ✅ PASS

UX-level review of f4552b673bad893fe904f85379570b318362cde7 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

UX-Verdict: PASS

Nothing to check. The diff adds and changes no on-screen controls, labels or dialog text. It only touches backend Feishu import timing, how the Electron app checks the Windows port, log lines and a guide, so no screenshot is needed.

[UX-REVIEWED] f4552b6

Description read

[DESCRIPTION-READ] 957a3fd6bf5ef4039769037f180fbe273703422c1d5d6db3ad2e47ade7741ffc

That sha256 names everything this verdict read: the PR description, plus the 3 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5) — ✅ PASS

Design-level review of f4552b673bad893fe904f85379570b318362cde7 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

Design-Verdict: PASS

Both picks are clean backports of fixes already on main, and the seams they depend on (live.watch().replay, degraded_sections, dispatcher._config_sub) exist on the 0.13 base.

Notes

[DESIGN-REVIEWED] f4552b6

Description read

[DESCRIPTION-READ] 22c5dc5d1cf51e1e99fff3e2f42ea47e3bea55728491e1769e5b91bab77089e7

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

github-actions Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

GPT 6.1 Review — ✅ no blocking findings

GPT 6.1 completed its review of f4552b673bad893fe904f85379570b318362cde7 and found no blocking issues.

This comment is updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] f4552b6

False positive or not applicable? A repository writer can comment:
/ai-review override gpt f4552b673bad893fe904f85379570b318362cde7 false-positive: <reason, 20 to 500 characters>

@github-actions github-actions Bot added readiness: action required A blocking check or review needs attention and removed readiness: checking Automated validation is still running labels Nov 19, 2026
@github-actions

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5) — ✅ PASS

Premise-level review of f4552b673bad893fe904f85379570b318362cde7 — why this exists and whether the shipped surface is the smallest honest version. Updated in place on each push. A BLOCK verdict blocks PR readiness; PASS does not.

First-Principles-Verdict: PASS

Two undeclared riders ship beside the declared fixes. Both remove a real harm, and neither carries a product-shape change.

Notes

  • Item 2 — undeclared: the description says only "imports lark-oapi in a worker thread". It never mentions that the transport's allow-list now comes from live.snapshot() and is replayed through dispatcher._config_sub. That changes who gets authorized at boot, an allow-list boundary for multiple humans. It has a real cause: the new await opens a window in which a config edit finds no transport. A reader of the backport is still not told about it.
  • Item 4 — undeclared, rides along: { timeout, windowsHide: true } on every netstat and taskkill call. The lockout is already fixed by item 3 without it. Its own harm, a console window opening for each probe, is named only in a code comment: "every probe this GUI app runs gets a new console of its own".

What this change ships

Inventory (6 items) — 4 justified

Intent: 0.13 users get two P0 fixes from main: the Windows gateway starts when netstat cannot finish, and a slow Feishu SDK import no longer causes a restart loop. This is a FIX (backport).

  1. Feishu SDK modules now load on a worker thread before the client starts — justified
  2. Feishu allow-list at boot now comes from the live config (nobody when the section is degraded), then the config is replayed — undeclared
  3. Windows: if netstat fails, a successful bind lets the gateway start; a refused bind still fails closed — justified
  4. netstat and taskkill no longer open a console window — undeclared, rides along
  5. Windows install guide describes the bind fallback — justified
  6. Feishu client docstring reworded about which loop the SDK's loop global binds to — justified

[FIRST-PRINCIPLES-REVIEWED] f4552b6

Description read

[DESCRIPTION-READ] 749a549bc924201c3ccf39f30edafe86a7624ca3ecf0f34edce7a4b4088f1e71

That sha256 names the PR description this verdict read. Recompute it with .github/scripts/pr-description-capture.sh; if it differs, the description changed after this verdict was formed and any finding drawn from the description is unproven.

@github-actions

Copy link
Copy Markdown
Contributor

Opus 5.5 Review — ✅ no blocking findings

Reviewed f4552b673bad893fe904f85379570b318362cde7 — this comment is updated in place on each push.

Review details

No findings.

[OPUS-REVIEWED] f4552b6

Verdict parsed from the review's SHA-scoped output markers for commit f4552b673bad893fe904f85379570b318362cde7.

False positive or not applicable? A repository writer can comment:
/ai-review override fable f4552b673bad893fe904f85379570b318362cde7 false-positive: <reason, 20 to 500 characters>

@buluoray

Copy link
Copy Markdown
Contributor Author

Closing: #39397 (merged 04:57Z) already carries #37927 and #38025 on release/0.13.0, so this PR is redundant. Its tree differs from the release tip only by the version bump. The two CI reds here (test_kas_policy_hidden_readiness, the memory-UI E2E) also fail on the release tip's own runs, and #39417 fixed the first.

@buluoray buluoray closed this Nov 19, 2026
@github-actions github-actions Bot removed the readiness: action required A blocking check or review needs attention label Nov 19, 2026
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