refactor(core): migrate to Bun and converge acquisition policies and Agent boundaries

This commit is contained in:
root committed 2026-10-13 14:37:03 +08:00
1 parent 3f1c6d02f6
commit 27c0f27434
268 files changed
+7468 -7852

No files matched your search

@@ -2,7 +2,7 @@
* 重新录制身份匹配差分(ID-2):我们侧的 TMDB 请求走本地缓存代理(scratchpad tmdb_proxy.py,上行计数封顶),
* 录下的响应裁剪后写入 tmdb-fixtures.json,逐条结果写入 ours.json 并打印汇总。
*
* TMDB_PROXY=http://127.0.0.1:18731 deno run -A apps/server/test/sources-identity/identity-differential.run.ts
* TMDB_PROXY=http://127.0.0.1:18731 bun apps/server/test/sources-identity/identity-differential.run.ts
*/
import { writeFileSync } from "node:fs";
import { join } from "node:path";
@@ -16,9 +16,9 @@ import {
trimTmdb,
} from "./identity-differential.lib.ts";
const proxy = Deno.env.get("TMDB_PROXY") ?? "http://127.0.0.1:18731";
const proxy = process.env.TMDB_PROXY ?? "http://127.0.0.1:18731";
const fixtures: Record<string, unknown> = {};
const recording: typeof fetch = async (input, init) => {
const recording: (input: RequestInfo | URL, init?: RequestInit) => Promise<Response> = async (input, init) => {
const url = typeof input === "string" ? input : input instanceof URL ? input.href : input.url;
const res = await fetch(url, init);
const body = await res.clone().json();