惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
月光博客
月光博客
MyScale Blog
MyScale Blog
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
爱范儿
爱范儿
P
Proofpoint News Feed
人人都是产品经理
人人都是产品经理
Last Week in AI
Last Week in AI
罗磊的独立博客
G
Google Developers Blog
Y
Y Combinator Blog
博客园 - 【当耐特】
WordPress大学
WordPress大学
大猫的无限游戏
大猫的无限游戏
博客园 - 叶小钗
J
Java Code Geeks
酷 壳 – CoolShell
酷 壳 – CoolShell
V
Visual Studio Blog
美团技术团队
宝玉的分享
宝玉的分享
Jina AI
Jina AI
小众软件
小众软件
T
Tailwind CSS Blog
A
About on SuperTechFans

Recent Commits to openclaw:main

test: merge chat side-result checks · openclaw/openclaw@ddd2c2a test: merge cron history checks · openclaw/openclaw@f7eb746 test: merge responsive navigation shell checks · openclaw/openclaw@c2e4b47 docs(changelog): add codex oauth fixes · openclaw/openclaw@628e6cd test: merge navigation routing cases · openclaw/openclaw@5d8cecb Tests: mock channel registry bundled fallback · openclaw/openclaw@2b08233 Secrets: avoid broad web search discovery for single plugin config · openclaw/openclaw@a464f59 test: merge config view browser checks · openclaw/openclaw@20cf511 fix(status): align oauth health with runtime · openclaw/openclaw@eed7116 feat: add macOS screen snapshots for monitor preview (#67954) thanks … · openclaw/openclaw@f377db1 fix: report shared auth scopes in hello-ok (#67810) thanks @BunsDev · openclaw/openclaw@0b6c39b Auto-reply: avoid eager bundled route fallback · openclaw/openclaw@3ea1bf4 Tests: narrow session binding contract setup · openclaw/openclaw@54e4e16 fix(macOS): enable undo/redo in webchat composer text input (#34962) · openclaw/openclaw@00951dc Tests: speed up channel setup promotion · openclaw/openclaw@82b529a Docs: refresh agent instructions · openclaw/openclaw@5775fe2 fix(auth): serialize OAuth refresh across agents to fix #26322 (#67876) · openclaw/openclaw@8e79080 test: allow ollama public surface boundary test · openclaw/openclaw@7d4f1a6 Docs: add test performance guardrails · openclaw/openclaw@89706d3 Tests: restore context-engine usage proof · openclaw/openclaw@e4c4f95 Tests: slim context engine runtime coverage · openclaw/openclaw@74c198f ci: retry failed custom checkouts · openclaw/openclaw@0ee5baf test: trim duplicate provider auth onboarding cases · openclaw/openclaw@1ffc02e matrix: fix sessions_spawn --thread subagent session spawning (#67643) · openclaw/openclaw@1ce2596 test: reduce auth choice fixture churn · openclaw/openclaw@857b9cd test: mock health status config boundaries · openclaw/openclaw@9d5ab4a test: mock onboard config io boundary · openclaw/openclaw@299694d test: mock legacy state plugin boundaries · openclaw/openclaw@2713089 test: mock channel install boundaries · openclaw/openclaw@b945248 test: mock doctor preview channel boundaries · openclaw/openclaw@b1a3ad4
build(discord): skip native opus builds by default (#8007...
steipete · 2026-05-10 · via Recent Commits to openclaw:main
Original file line numberDiff line numberDiff line change

@@ -7,6 +7,7 @@ Docs: https://docs.openclaw.ai

77

### Changes

88
99

- Talk: add `talk.realtime.instructions` so operators can append realtime voice style instructions while preserving OpenClaw's built-in agent-consult guidance. (#79081) Thanks @VACInc.

10+

- Discord/voice: default test and source installs to the pure-JS `opusscript` decoder by ignoring optional native `@discordjs/opus` builds, avoiding slow native addon compiles outside dedicated voice-performance lanes.

1011

- Gateway/skills: add an opt-in private skill archive upload install path gated by `skills.install.allowUploadedArchives`, so trusted Gateway clients can stage and install zip-backed skills only when operators explicitly enable the code-install surface. (#74430) Thanks @samzong.

1112

- Dependencies: refresh workspace pins and patch targets, including ACPX `@agentclientprotocol/claude-agent-acp` `0.33.1`, Codex ACP `0.14.0`, Baileys `7.0.0-rc10`, Google GenAI `2.0.1`, OpenAI `6.37.0`, AWS SDK `3.1045.0`, Kysely `0.29.0`, Tlon skill `0.3.6`, Aimock `1.19.5`, and tsdown `0.22.0`.

1213

- Agents/compaction: preserve scoped background exec/process session references across embedded compaction and after-turn runtime contexts without exposing sessions from unrelated scopes. Fixes #79284. (#79307) Thanks @TurboTheTurtle.

Original file line numberDiff line numberDiff line change

@@ -1213,6 +1213,7 @@ Notes:

12131213

- If `voice.autoJoin` has multiple entries for the same guild, OpenClaw joins the last configured channel for that guild.

12141214

- `voice.daveEncryption` and `voice.decryptionFailureTolerance` pass through to `@discordjs/voice` join options.

12151215

- `@discordjs/voice` defaults are `daveEncryption=true` and `decryptionFailureTolerance=24` if unset.

1216+

- OpenClaw defaults to the pure-JS `opusscript` decoder for Discord voice receive. The optional native `@discordjs/opus` package is ignored by the repo pnpm install policy so normal installs and tests do not compile a native addon; only opt into a native opus build in a dedicated voice-performance or live-lane environment.

12161217

- `voice.connectTimeoutMs` controls the initial `@discordjs/voice` Ready wait for `/vc join` and auto-join attempts. Default: `30000`.

12171218

- `voice.reconnectGraceMs` controls how long OpenClaw waits for a disconnected voice session to begin reconnecting before destroying it. Default: `15000`.

12181219

- In `stt-tts` mode, voice playback does not stop just because another user starts speaking. To avoid feedback loops, OpenClaw ignores new voice capture while TTS is playing; speak after playback finishes for the next turn. Realtime modes forward speaker starts as barge-in signals to the realtime provider.

Original file line numberDiff line numberDiff line change

@@ -443,6 +443,11 @@ Think of the suites as "increasing realism" (and increasing flakiness/cost):

443443

real bundled plugin source APIs. Real plugin API loads belong in

444444

plugin-owned contract/integration suites.

445445
446+

Native dependency policy:

447+
448+

- Default test installs skip optional native Discord opus builds. Discord voice receive uses the pure-JS `opusscript` decoder, and `@discordjs/opus` stays in `ignoredBuiltDependencies` so local tests and Testbox lanes do not compile the native addon.

449+

- Use a dedicated Discord voice performance or live lane if you intentionally need to compare a native opus build. Do not add `@discordjs/opus` back to the default `onlyBuiltDependencies`; that makes unrelated install/test loops compile native code.

450+
446451

<AccordionGroup>

447452

<Accordion title="Projects, shards, and scoped lanes">

448453
Original file line numberDiff line numberDiff line change

@@ -0,0 +1,19 @@

1+

import { Readable } from "node:stream";

2+

import { describe, expect, it } from "vitest";

3+

import { decodeOpusStream } from "./audio.js";

4+
5+

describe("discord voice opus decoder selection", () => {

6+

it("prefers the pure-JS opusscript decoder over optional native opus", async () => {

7+

const verbose: string[] = [];

8+

const warnings: string[] = [];

9+
10+

const decoded = await decodeOpusStream(Readable.from([]), {

11+

onVerbose: (message) => verbose.push(message),

12+

onWarn: (message) => warnings.push(message),

13+

});

14+
15+

expect(decoded.length).toBe(0);

16+

expect(verbose).toContain("opus decoder: opusscript");

17+

expect(warnings).toEqual([]);

18+

});

19+

});

Original file line numberDiff line numberDiff line change

@@ -48,6 +48,16 @@ function resolveOpusDecoderFactory(params: {

4848

onWarn: (message: string) => void;

4949

}): OpusDecoderFactory | null {

5050

const factories: OpusDecoderFactory[] = [

51+

{

52+

name: "opusscript",

53+

load: () => {

54+

const OpusScript = require("opusscript") as {

55+

new (sampleRate: number, channels: number, application: number): OpusDecoder;

56+

Application: { AUDIO: number };

57+

};

58+

return new OpusScript(SAMPLE_RATE, CHANNELS, OpusScript.Application.AUDIO);

59+

},

60+

},

5161

{

5262

name: "@discordjs/opus",

5363

load: () => {

@@ -62,16 +72,6 @@ function resolveOpusDecoderFactory(params: {

6272

return new DiscordOpus.OpusEncoder(SAMPLE_RATE, CHANNELS);

6373

},

6474

},

65-

{

66-

name: "opusscript",

67-

load: () => {

68-

const OpusScript = require("opusscript") as {

69-

new (sampleRate: number, channels: number, application: number): OpusDecoder;

70-

Application: { AUDIO: number };

71-

};

72-

return new OpusScript(SAMPLE_RATE, CHANNELS, OpusScript.Application.AUDIO);

73-

},

74-

},

7575

];

7676
7777

const failures: string[] = [];

Original file line numberDiff line numberDiff line change

@@ -1820,7 +1820,6 @@

18201820

},

18211821

"onlyBuiltDependencies": [

18221822

"@openclaw/fs-safe",

1823-

"@discordjs/opus",

18241823

"@google/genai",

18251824

"@lydell/node-pty",

18261825

"@matrix-org/matrix-sdk-crypto-nodejs",

@@ -1835,6 +1834,7 @@

18351834

"sharp"

18361835

],

18371836

"ignoredBuiltDependencies": [

1837+

"@discordjs/opus",

18381838

"koffi",

18391839

"tree-sitter-bash"

18401840

],

Original file line numberDiff line numberDiff line change

@@ -34,7 +34,6 @@ minimumReleaseAgeExclude:

3434
3535

onlyBuiltDependencies:

3636

- "@openclaw/fs-safe"

37-

- "@discordjs/opus"

3837

- "@google/genai"

3938

- "@lydell/node-pty"

4039

- "@matrix-org/matrix-sdk-crypto-nodejs"

@@ -49,5 +48,6 @@ onlyBuiltDependencies:

4948

- sharp

5049
5150

ignoredBuiltDependencies:

51+

- "@discordjs/opus"

5252

- koffi

5353

- tree-sitter-bash

Original file line numberDiff line numberDiff line change

@@ -0,0 +1,30 @@

1+

import fs from "node:fs";

2+

import { describe, expect, it } from "vitest";

3+

import { parse } from "yaml";

4+
5+

type PnpmBuildConfig = {

6+

ignoredBuiltDependencies?: string[];

7+

onlyBuiltDependencies?: string[];

8+

};

9+
10+

type RootPackageJson = {

11+

pnpm?: PnpmBuildConfig;

12+

};

13+
14+

type WorkspaceConfig = PnpmBuildConfig;

15+
16+

function readJson<T>(filePath: string): T {

17+

return JSON.parse(fs.readFileSync(filePath, "utf8")) as T;

18+

}

19+
20+

describe("package manager build policy", () => {

21+

it("keeps optional native Discord opus builds disabled by default", () => {

22+

const packageJson = readJson<RootPackageJson>("package.json");

23+

const workspace = parse(fs.readFileSync("pnpm-workspace.yaml", "utf8")) as WorkspaceConfig;

24+
25+

for (const config of [packageJson.pnpm, workspace]) {

26+

expect(config?.ignoredBuiltDependencies ?? []).toContain("@discordjs/opus");

27+

expect(config?.onlyBuiltDependencies ?? []).not.toContain("@discordjs/opus");

28+

}

29+

});

30+

});