Skip to content

fix: 升级 Runtime 并隐藏无效后端日期 - #568

Closed
ClozyA wants to merge 3 commits into
devfrom
codex/runtime-013-hide-backend-date
Closed

fix: 升级 Runtime 并隐藏无效后端日期#568
ClozyA wants to merge 3 commits into
devfrom
codex/runtime-013-hide-backend-date

Conversation

@ClozyA

@ClozyA ClozyA commented Sep 5, 2026

Copy link
Copy Markdown
Member

变更

  • 将随应用分发的 AUTO-MAS Runtime 升级到 v0.1.3
  • 设置页暂时隐藏始终显示 unknown 的后端日期,并保留后端哈希信息
  • res/version.json 记录本次用户可见变更

验证

  • yarn lint --max-warnings 1
  • yarn typecheck
  • yarn test(376 passed)
  • yarn build
  • uv run --with pytest pytest tests --collect-only -q(459 collected)
  • git diff --check

Sourcery 总结

升级随应用分发的 Runtime,并移除设置页中无效的后端日期信息。

Bug 修复:

  • 隐藏设置页中始终显示为 unknown 的后端日期,同时继续保留后端哈希信息。

功能增强:

  • 将随应用分发的 AUTO-MAS Runtime 升级至 v0.1.3。

文档:

  • res/version.json 中记录本次用户可见变更。
Original summary in English

Summary by Sourcery

升级随应用分发的 Runtime,并移除设置页中无效的后端日期信息。

Bug Fixes:

  • 隐藏设置页中始终显示为 unknown 的后端日期,同时继续保留后端哈希信息。

Enhancements:

  • 将随应用分发的 AUTO-MAS Runtime 升级至 v0.1.3。

Documentation:

  • res/version.json 中记录本次用户可见变更。

@sourcery-ai

sourcery-ai Bot commented Sep 5, 2026

Copy link
Copy Markdown
审查者指南(小型 PR 中折叠显示)

审查者指南

本 PR 将随应用构建分发的 AUTO-MAS Runtime 升级至 v0.1.3,移除设置页中始终为 unknown 的后端日期展示及复制内容,并保留后端哈希信息,同时更新用户可见变更记录。

文件级变更

变更 详情 文件
升级应用分发的 AUTO-MAS Runtime 版本。
  • 将构建工作流中的 Runtime 固定版本从 v0.1.0 更新至 v0.1.3。
.github/workflows/build-app.yml
隐藏设置页中无效的后端日期信息,同时保留后端哈希。
  • 移除后端日期的展示及“复制全部信息”内容。
  • 保留后端哈希展示和复制能力。
frontend/src/views/setting/TabOthers.vue
记录用户可见的版本变更。
  • 更新版本变更记录以反映本次 Runtime 升级和设置页调整。
res/version.json

提示和命令

与 Sourcery 交互

  • 触发新的审查: 在拉取请求中评论 @sourcery-ai review
  • 继续讨论: 直接回复 Sourcery 的审查评论。
  • 根据审查评论创建 GitHub issue: 回复审查评论,请 Sourcery 根据该评论创建 issue。你也可以使用 @sourcery-ai issue 回复审查评论,以根据该评论创建 issue。
  • 生成拉取请求标题: 在拉取请求标题的任意位置写入 @sourcery-ai,即可随时生成标题。你也可以在拉取请求中评论 @sourcery-ai title,以随时(重新)生成标题。
  • 生成拉取请求摘要: 在拉取请求正文中需要生成摘要的位置写入 @sourcery-ai summary,即可在指定位置随时生成 PR 摘要。你也可以在拉取请求中评论 @sourcery-ai summary,以随时(重新)生成摘要。
  • 生成审查者指南: 在拉取请求中评论 @sourcery-ai guide,即可随时(重新)生成审查者指南。
  • 解决所有 Sourcery 评论: 在拉取请求中评论 @sourcery-ai resolve,即可解决所有 Sourcery 评论。如果你已经处理了所有评论并不想再看到它们,此功能会很有用。
  • 忽略所有 Sourcery 审查: 在拉取请求中评论 @sourcery-ai dismiss,即可忽略所有现有的 Sourcery 审查。如果你希望使用新的审查重新开始,此功能尤其有用——别忘了评论 @sourcery-ai review 来触发新的审查!

自定义使用体验

访问你的控制面板以:

  • 启用或禁用审查功能,例如 Sourcery 生成的拉取请求摘要、审查者指南等。
  • 更改审查语言。
  • 添加、移除或编辑自定义审查说明。
  • 调整其他审查设置。

获取帮助

Original review guide in English
Reviewer's guide (collapsed on small PRs)

Reviewer's Guide

本 PR 将随应用构建分发的 AUTO-MAS Runtime 升级至 v0.1.3,移除设置页中始终为 unknown 的后端日期展示及复制内容,并保留后端哈希信息,同时更新用户可见变更记录。

File-Level Changes

Change Details Files
升级应用分发的 AUTO-MAS Runtime 版本。
  • 将构建工作流中的 Runtime 固定版本从 v0.1.0 更新至 v0.1.3。
.github/workflows/build-app.yml
隐藏设置页中无效的后端日期信息,同时保留后端哈希。
  • 移除后端日期的展示及“复制全部信息”内容。
  • 保留后端哈希展示和复制能力。
frontend/src/views/setting/TabOthers.vue
记录用户可见的版本变更。
  • 更新版本变更记录以反映本次 Runtime 升级和设置页调整。
res/version.json

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

您好——我已查看您所做的更改,整体看起来很棒!

Sourcery 评估

需要人工审核。 工作流的更改会导致新构建的软件包捆绑 Runtime v0.1.3,因此运行时缺陷可能会影响已安装的客户端,而不仅仅是简单地还原源代码。影响范围是有限的,并且可以通过发布或安装修正后的软件包来修复;隐藏无效日期只是一项可逆的显示更改。


Sourcery 对开源项目免费——如果您喜欢我们的评审,请考虑分享它们 ✨
Original comment in English

Hey - I've reviewed your changes and they look great!

Sourcery assessment

Needs a human reviewer. The workflow change causes newly built packages to bundle Runtime v0.1.3, so a runtime defect could affect installed clients beyond a simple source revert. The impact is bounded and can be repaired by publishing or installing a corrected package; hiding the invalid date is only a reversible display change.


Sourcery is free for open source - if you like our reviews please consider sharing them ✨

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: fdb8be0bbd

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

{{ backendUpdateInfo?.current_time || t('common.unknown') }}
</a-tag>
</div>
<div class="info-item">

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve dates in modes that still provide them

When a user selects the supported legacy (off) or development runtime mode, Config.get_git_version() skips only the managed AUTO_MAS_EXPECTED_COMMIT shortcut and returns the repository's real commit timestamp (app/core/config.py:720-757). Removing this field and its copied value unconditionally therefore hides valid diagnostic information in those modes; suppress it only when current_time is actually unknown.

Useful? React with 👍 / 👎.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 5b6bd250d5

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread res/version.json
Comment on lines +16 to +17
"后端更新自动在后台下载,准备好后提示下次启动生效,无需中断当前任务",
"Runtime 更新至 v0.1.3,并暂时隐藏设置页中无效的后端日期信息",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Collapse the two changelog entries into one

This commit adds two separate records for one PR, but the repository requires each PR to contribute exactly one concise changelog sentence. Merge the Runtime upgrade/date change and background-update behavior into a single user-facing entry.

AGENTS.md reference: AGENTS.md:L31-L33

Useful? React with 👍 / 👎.

Comment on lines +213 to +215
if (progress.progress !== undefined) {
state.progress = Math.min(100, Math.max(0, Math.round(progress.progress)))
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve progress across zero-valued substage events

In the supported legacy off flow, installers deliberately emit progress: 0 when moving between substages after reporting nonzero progress—for example, Python emits 50% after its check and then 0% when download begins, while repository setup emits 100% and then 0% before pulling. Unconditionally assigning that zero here makes the new progress display jump backward (and can briefly change a completed step back to processing); retain the prior nonzero value for such transition events unless this is the start of the step.

Useful? React with 👍 / 👎.

Comment thread scripts/README.md
Comment on lines +3 to +5
使用 PowerShell 7。后台更新需要桌面和 Runtime 同时使用新代码;当前工作流固定的旧 Runtime
版本尚未包含该能力,发布前须先发布新 Runtime,再更新 `.github/workflows/build-app.yml`
的 `RUNTIME_VERSION`。CI 会拒绝缺少后台更新协议的二进制,防止生成无法正常启动的安装包。

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Update the packaging guide to match the upgraded Runtime

The newly added guide says the workflow is still pinned to an old Runtime without background-update support and instructs maintainers to release and bump it, but this same commit already sets RUNTIME_VERSION to v0.1.3 and adds a protocol probe that rejects unsupported binaries. Leaving this paragraph unchanged gives packagers obsolete release instructions; describe v0.1.3 as the current validated version instead.

Useful? React with 👍 / 👎.

Comment on lines +305 to +308
content: t(
runtimeBackendUpdateAvailable.value
? 'comp.backendUpdateReadyConfirm'
: 'comp.backendAboutUpdateWhich'

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Warn that applying the staged update interrupts running tasks

When a staged update is ready while a scheduler task is running, this branch invokes appRestart(), whose coordinated shutdown stops the supervised backend and therefore interrupts the task. The new confirmation text only says the update will be applied and omits the explicit interruption warning used by backendAboutUpdateWhich; it also bypasses the hasRunningTasks() warning used by normal close. Preserve that warning or guard this restart so users do not terminate active automation without being told.

Useful? React with 👍 / 👎.

version,
'--if-needed',
])
if (!prepared.success) return this.buildRuntimeStartFailure(prepared, [], [])

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve Runtime logs from startup preparation failures

When the new managed-mode bootstrap --if-needed fails—for example during dependency synchronization—its diagnostic output is carried in RuntimeRunResult.recentLogs/log events, not necessarily in the Runtime process's raw stderr. Passing empty log arrays to buildRuntimeStartFailure discards those events, so the initialization failure panel often has no log content; the existing initialization Runtime path explicitly captures onLog for this reason. Collect the preparation command's log events or format the logs already present on the result.

Useful? React with 👍 / 👎.

Comment on lines +380 to +386
const prepared = await this.runRuntimePreparation(client, [
'bootstrap',
'--version',
version,
'--if-needed',
])
if (!prepared.success) return this.buildRuntimeStartFailure(prepared, [], [])

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Expose Runtime recovery actions for startup preparation failures

When the newly added startup bootstrap --if-needed returns a structured failure such as DEPENDENCY_SYNC_FAILED with rebuild-environment or open-log remediation, buildRuntimeStartFailure preserves those fields, but RuntimeBackendStartPanel consumes only success, error, and logs and offers the same generic retry/docs actions. In this scenario retrying repeats the same dependency sync and users cannot invoke the Runtime-provided rebuild or log action from the failure screen; route preparation failures through the existing Runtime failure-action handling or add equivalent actions to the backend panel.

Useful? React with 👍 / 👎.

Comment on lines +1082 to +1084
if (this.runtimeStopping || this.startFlight) return Promise.resolve({ updateAvailable: false })
if (this.runtimeUpdateReady) return Promise.resolve(this.runtimeUpdateReady)
if (this.runtimeUpdateFlight) return this.runtimeUpdateFlight

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Keep the staged-update hint until preparation is consumed

If a staged update is cached and a backend start is in progress, this early return runs before the runtimeUpdateReady check and reports a clean updateAvailable: false. The renderer treats any non-error response without staged: true as authoritative and clears its ready hint; if that startup then fails before consuming the staged update, users lose the restart prompt until the next 10-minute poll even though the prepared update still exists. Return the cached ready result first, or make the busy response non-authoritative.

Useful? React with 👍 / 👎.

@ClozyA

ClozyA commented Sep 5, 2026

Copy link
Copy Markdown
Member Author

按要求改为从 origin/dev 线性重建 PR,完整包含本地 dev 的热更新提交;请改看新 PR。

@ClozyA ClozyA closed this Sep 5, 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.

1 participant