diff --git a/docs/modification/2026-10-31-openclaw-tools-image.md b/docs/modification/2026-10-31-openclaw-tools-image.md index fa21430a5e9..6538c04f830 100644 --- a/docs/modification/2026-10-31-openclaw-tools-image.md +++ b/docs/modification/2026-10-31-openclaw-tools-image.md @@ -63,11 +63,11 @@ Debian 套件在 amd64 與 arm64 上的版本相同。 | 類別 | 套件與版本 | |------|------------| -| Office | `libreoffice-core`、`libreoffice-writer`、`libreoffice-calc`、`libreoffice-impress` `4:25.2.3-2+deb13u12` | +| Office | `libreoffice-core`、`libreoffice-writer`、`libreoffice-calc`、`libreoffice-impress` `4:26.8.3.1-0+deb13u1` | | PDF 與轉檔 | `pandoc 3.1.11.1+ds-2`、`poppler-utils 25.03.0-5+deb13u4`、`qpdf 12.2.0-1`、`ghostscript 10.05.1~dfsg-1+deb13u3` | | OCR | `tesseract-ocr 5.5.0-1+b1`;語言資料 `eng`、`chi-tra`、`chi-sim` `1:4.1.0-2` | | 圖片與影音 | `imagemagick 8:7.1.1.43+dfsg1-1+deb13u14`(提供 `magick`)、`ffmpeg 7:7.1.5-0+deb13u1`(含 `ffprobe`)、`libimage-exiftool-perl 13.25+dfsg-1` | -| 瀏覽器 | `chromium`、`chromium-common` `156.0.8078.108-1~deb13u1`,固定在 `apt-packages-browser.txt` | +| 瀏覽器 | `chromium`、`chromium-common` `156.0.8078.114-1~deb13u1`,固定在 `apt-packages-browser.txt` | | 字型 | `fontconfig 2.15.0-2.3`、`fonts-noto-cjk 1:20240730+repack1-1`、`fonts-liberation 1:2.1.5-3`、`fonts-dejavu-core 2.37-8` | | Workspace | `zip 3.0-15+deb13u1`、`unzip 6.0-29+deb13u1`、`ripgrep 14.1.1-1+b4`、`sqlite3 3.46.1-7+deb13u2` | | 執行期函式庫 | `libicu76 76.1-4`(officecli 需要) | diff --git a/test/tools-image-apt-pins.test.ts b/test/tools-image-apt-pins.test.ts new file mode 100644 index 00000000000..b84709cab21 --- /dev/null +++ b/test/tools-image-apt-pins.test.ts @@ -0,0 +1,43 @@ +// SPDX-FileCopyrightText: Copyright (c) 2026 NVIDIA CORPORATION & AFFILIATES. All rights reserved. +// SPDX-License-Identifier: Apache-2.0 +// +// Debian removes the previous version from trixie-security when it publishes a +// replacement, so related pins and the fixture version check must change +// together (#85, #92). These checks fail on a partial update. +import fs from "node:fs"; +import path from "node:path"; +import { describe, expect, it } from "vitest"; + +const TOOLS = path.resolve(import.meta.dirname, "../tools/openclaw-tools-image"); + +function pins(file: string): Map { + const result = new Map(); + for (const line of fs.readFileSync(path.join(TOOLS, file), "utf8").split("\n")) { + const entry = line.trim(); + if (!entry || entry.startsWith("#")) continue; + const [name, version] = entry.split("=", 2); + result.set(name, version); + } + return result; +} + +describe("tools image apt pins (#92)", () => { + it("pins chromium and chromium-common together and checks that release in the fixture", () => { + const browser = pins("apt-packages-browser.txt"); + const chromium = browser.get("chromium"); + expect(chromium).toMatch(/^\d+\.\d+\.\d+\.\d+-/); + expect(browser.get("chromium-common")).toBe(chromium); + const upstream = chromium!.split("-")[0]; + const fixture = fs.readFileSync(path.join(TOOLS, "fixtures/run-phase3.sh"), "utf8"); + expect(fixture).toContain(`chromium --version | grep -F ${upstream}`); + }); + + it("pins every LibreOffice package at one version", () => { + const apt = pins("apt-packages.txt"); + const versions = new Set( + [...apt].filter(([name]) => name.startsWith("libreoffice-")).map(([, version]) => version), + ); + expect(apt.has("libreoffice-core")).toBe(true); + expect(versions.size).toBe(1); + }); +}); diff --git a/tools/openclaw-tools-image/apt-packages-browser.txt b/tools/openclaw-tools-image/apt-packages-browser.txt index a486c1eb26d..1250d9dd671 100644 --- a/tools/openclaw-tools-image/apt-packages-browser.txt +++ b/tools/openclaw-tools-image/apt-packages-browser.txt @@ -5,5 +5,7 @@ # 156.0.8078.108-1~deb13u1 on amd64 and arm64 (#85). Pin chromium-common # with chromium: apt 3.0 does not pick an older chromium-common on its own # while the base image's controlled packages are held. -chromium=156.0.8078.108-1~deb13u1 -chromium-common=156.0.8078.108-1~deb13u1 +# By 2026-12-03, trixie-security had replaced 156.0.8078.108-1~deb13u1 with +# 156.0.8078.114-1~deb13u1 on amd64 and arm64 (#92). +chromium=156.0.8078.114-1~deb13u1 +chromium-common=156.0.8078.114-1~deb13u1 diff --git a/tools/openclaw-tools-image/apt-packages.txt b/tools/openclaw-tools-image/apt-packages.txt index 5eade774a08..52d6d230da4 100644 --- a/tools/openclaw-tools-image/apt-packages.txt +++ b/tools/openclaw-tools-image/apt-packages.txt @@ -8,6 +8,12 @@ # trixie-security on amd64 and arm64. # 2026-11-19: Debian removed LibreOffice 4:25.2.3-2+deb13u9 from # trixie-security; the LibreOffice packages now use deb13u12. +# By 2026-12-03, trixie-security had replaced 4:25.2.3-2+deb13u12 with +# 4:26.8.3.1-0+deb13u1 on amd64 and arm64; trixie still has only +# 4:25.2.3-2+deb13u9 (#92). libreoffice-core 4:26.8.3.1-0+deb13u1 depends on +# libexpat1 (>= 2.9.0). Dockerfile.base installs libexpat1 2.9.0-1~deb13u1; +# agents/hermes-01x/Dockerfile.base installs 2.8.3-1, so the Hermes tools +# image cannot install this release until its base changes. # Install with --no-install-recommends. jq and libsqlite3-0 come from the base. ffmpeg=7:7.1.5-0+deb13u1 fontconfig=2.15.0-2.3 @@ -18,10 +24,10 @@ ghostscript=10.05.1~dfsg-1+deb13u3 imagemagick=8:7.1.1.43+dfsg1-1+deb13u14 libicu76=76.1-4 libimage-exiftool-perl=13.25+dfsg-1 -libreoffice-calc=4:25.2.3-2+deb13u12 -libreoffice-core=4:25.2.3-2+deb13u12 -libreoffice-impress=4:25.2.3-2+deb13u12 -libreoffice-writer=4:25.2.3-2+deb13u12 +libreoffice-calc=4:26.8.3.1-0+deb13u1 +libreoffice-core=4:26.8.3.1-0+deb13u1 +libreoffice-impress=4:26.8.3.1-0+deb13u1 +libreoffice-writer=4:26.8.3.1-0+deb13u1 pandoc=3.1.11.1+ds-2 poppler-utils=25.03.0-5+deb13u4 qpdf=12.2.0-1 diff --git a/tools/openclaw-tools-image/fixtures/run-phase3.sh b/tools/openclaw-tools-image/fixtures/run-phase3.sh index ae954cebe88..737d87fea15 100755 --- a/tools/openclaw-tools-image/fixtures/run-phase3.sh +++ b/tools/openclaw-tools-image/fixtures/run-phase3.sh @@ -57,7 +57,7 @@ PY chromium_cli() { write_page - chromium --version | grep -F 156.0.8078.108 + chromium --version | grep -F 156.0.8078.114 chromium --headless --no-sandbox --disable-gpu --disable-dev-shm-usage \ --user-data-dir="$WORK/chromium-profile" --window-size=800,600 \ --screenshot="$WORK/chromium-cli.png" "file://$WORK/page.html"