@noob-stupid/dsh-plugin-console 0.5.46 → 0.5.47

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -8,6 +8,7 @@ import { compUiUrl, findComponents } from '../domain/components.js'
8
8
  import { currentFrameworkVersion, detectFrameworkUpgrade } from '../domain/framework.js'
9
9
  import { peerVetoFor } from '../domain/peer-veto.js'
10
10
  import { readExtraBundleRows } from '../domain/install-job.js'
11
+ import { failedJobEvidence } from '../domain/install-verify.js'
11
12
  import { installJobView, readGithubAuth } from '../domain/install.js'
12
13
  import { readPluginDetails } from '../domain/market.js'
13
14
  import { healPatchSafety, readPatchState } from '../domain/patch.js'
@@ -103,7 +104,12 @@ async function routeStateGet(req, res, rc) {
103
104
  const compat = await detectCompat(ctx.baseUrl ?? 'file:///')
104
105
  const auth = readGithubAuth()
105
106
  const jobs = [...installJobs.values()].filter((job) => job.status === 'installing').map(installJobView)
106
- const recentFailures = [...installJobs.values()].filter((job) => job.status === 'failed').slice(-3).map(installJobView)
107
+ // 「最近安装失败」这张卡(0.5.47 改错,用户被误导过):**下发之前**先查三处(依赖清单 /
108
+ // dsh.profile.bundles / node_modules)—— 那个插件其实已经装上时,面板必须先说
109
+ // 「已安装 vX(无需重装)」,把历史失败降级成次要信息,而不是让用户以为没装上、再点一次重试。
110
+ // 核实是**只读**的(读 profile 清单 + 盘上包),每次都按**当前磁盘**现查(历史失败也要能翻案)。
111
+ const recentFailures = [...installJobs.values()].filter((job) => job.status === 'failed').slice(-3)
112
+ .map((job) => ({ ...installJobView(job), installedEvidence: failedJobEvidence(profileDir, job) ?? job.installedEvidence ?? null }))
107
113
  // 已安装但尚未生效的任务(2026-09-20 真装真卸演练实测):bundle 型插件要重启才被加载,
108
114
  // 装完 /install 返回 entryId: null、/state 里新增 loader 条目 = 0 —— 面板过去完全看不出
109
115
  // 「装了但还没生效」,也无法撤销。前端据此渲染「已安装·重启后生效」徽标 + 按 jobId 删除。
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@noob-stupid/dsh-plugin-console",
3
- "version": "0.5.46",
3
+ "version": "0.5.47",
4
4
  "description": "DSH 框架升级安全与插件升级门控:一键升级、失败自动回滚、升级后回滚上版、旧插件不适配自动禁用;内置多源插件市场为发现层,插件源全部可自定义,可指向公司内网私有源 / 私有索引 / 本地 Git 仓库,纯内网离线可用 | Framework upgrade safety & plugin version gating for DSH, with a customizable multi-source plugin market: point every source at internal mirrors or a local file:// repo for intranet-only, offline installs.",
5
5
  "repository": {
6
6
  "type": "git",