Skip to content

fix(shells): reconcile Bash publication across session lifecycle events (#579, #842, #873, #928, #750) - #1004

Closed
Nicholas023 wants to merge 4 commits into
mainfrom
fix-session-lifecycle-local
Closed

Nicholas023 wants to merge 4 commits into
mainfrom
fix-session-lifecycle-local

Conversation

@Nicholas023

Copy link
Copy Markdown
Collaborator

Closes #579, #842, #873, #928
Refs #750

What was wrong

The change

  • src/session-shells.ts: deduplicate overlapping row ownership; queued publications carry their identity and settle per generation; one failure per generation is reported once; turn/start re-asserts the current authority; disposal clears pending publications.
  • src/presets/ops-ptc/register.ts: the unload lease captures the live settings service and restores the host's configured default only when the live default still names ops-ptc; any other preset is never rewritten, and a missing/rejecting settings service reports the leftover instead of guessing.
  • New tests: session-idempotent-reconcile 4/4, preset-default-leftover 4/4, client-settings-plugin-manager 1/1; preset-registration 23/23 and shells-session 6/6 stay green; check:size green.

Validation

$ npm run build
build: compiled src/ to lib/ and copied 60 assets

$ node scripts/verify-gate.mjs --skip-install --keep-going
268 suites passed; skipped: linux-attributes, linux-shell, tui-host, tui-native (allowed: file-metadata, linux-attributes, linux-shell, tui-host, tui-native)
manifest: 92/59 checks
win32-x64: gate green

The gate lines above were produced on the local integration head b21274dd (all slices merged) with the pinned local fixtures:
DSH_OPS_TEST_BASH = a verified pinned MSYS bash (sha256 6cc575e9…), DSH_OPS_NIUBASH_ARCHIVE = the shipped frozen archive. Each PR branch was also built and its own suites were run before push; the counts below are from those runs.

CI required run: the pull_request event for this PR triggers ci.yml; paste the aggregate CI required run URL here once it finishes.

Environment

  • OS: Windows x64 25H2; Node.js v24.21.0; DSH 0.2.2-rc.1
  • Based on upstream main commit 58f6e281 (origin/main at submission)
  • Install channel: local source build (npm ci --ignore-scripts --offline, npm run build, npm run stage:niubash -- --offline --archive <frozen archive>)

@Thatgfsj

Copy link
Copy Markdown
Collaborator

Superseded by #1033:按仓库约定把 #1023 与 #1002–#1008 合并为一个统一 PR(冲突已在 #1033 内解决,CI 在 #1033 上跑)。

@Thatgfsj Thatgfsj closed this Nov 20, 2026
@Thatgfsj
Thatgfsj deleted the fix-session-lifecycle-local branch November 20, 2026 15:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment