@akanjs/cli 3.0.0-beta.9 → 3.0.1
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.
- package/.build-stamp +1 -1
- package/CodeAgent-zfab7pkn.js +9 -0
- package/CodeAgentRpcHost-p7h6n2hp.js +7 -0
- package/CodeAgentRpcListener-7p7z5dd7.js +97 -0
- package/CodeTui-0zhnr0pw.js +1457 -0
- package/README.ko.md +83 -28
- package/README.md +70 -27
- package/TunnelShare-cwh9ezsm.js +9 -0
- package/{agent.command-0q17pnrs.js → agent.command-aja6z9mn.js} +8 -9
- package/akanCode.js +102 -0
- package/application.command-049ehgx3.js +246 -0
- package/{applicationBuildRunner-kxwbssgn.js → applicationBuildRunner-75n5rpwp.js} +121 -77
- package/buildBatch.proc.js +120 -32
- package/cloud.command-gw4kqxt8.js +95 -0
- package/cloud.script-c723cpcb.js +20 -0
- package/code.command-x9t6z5nw.js +154 -0
- package/commandManifest.json +1 -1
- package/consoleToStderr-h5bryj94.js +7 -0
- package/context.command-yfbe1rtd.js +48 -0
- package/context.runner-erfe68j5.js +21 -0
- package/{dependencyScanner-shs82ynp.js → dependencyScanner-06z2dmrr.js} +2 -2
- package/{devTui-m1atgkc9.js → devTui-q7k7bakd.js} +122 -40
- package/fileSys-wzzrntkw.js +9 -0
- package/guideline.command-kq9gp690.js +42 -0
- package/guidelines/agentRule/agentRule.instruction.md +154 -26
- package/guidelines/conventions/conventions.instruction.md +138 -48
- package/guidelines/mcpRule/mcpRule.instruction.md +7 -5
- package/guidelines/queryRule/queryRule.instruction.md +21 -7
- package/guidelines/runtimeRule/runtimeRule.instruction.md +291 -6
- package/guidelines/ssrRule/ssrRule.instruction.md +4 -2
- package/guidelines/transportRule/transportRule.instruction.md +10 -8
- package/guidelines/workspaceOnboarding/workspaceOnboarding.instruction.md +20 -0
- package/guidelines/workspaceRecipes/workspaceRecipes.instruction.md +66 -3
- package/incrementalBuilder.proc.js +564 -109
- package/{index-2tv3fdx4.js → index-150s07n8.js} +1230 -1459
- package/{index-vyvre9en.js → index-25fvrxmy.js} +6 -2
- package/{index-kcxmv48c.js → index-2ahj896a.js} +45 -79
- package/index-2wc41k5w.js +49 -0
- package/index-3hx1z96c.js +87 -0
- package/{index-q0y2jq9j.js → index-52w0fvh8.js} +21 -4
- package/{index-04bk599g.js → index-5g4rkrvt.js} +10 -17
- package/index-5pvxf7z0.js +53 -0
- package/index-5q14pwzd.js +69 -0
- package/{index-vxtad5bd.js → index-66yspb67.js} +5 -8
- package/index-7md2g9vw.js +6 -0
- package/index-7p4c0yer.js +1058 -0
- package/{index-d43r08tf.js → index-8b639zes.js} +77 -150
- package/{index-ktb5njgy.js → index-8kvy8qb4.js} +49 -99
- package/index-94s080qm.js +266 -0
- package/index-9dp031by.js +12 -0
- package/{index-0g7r8xz3.js → index-a37by9hn.js} +114 -232
- package/{index-k2j1hc4r.js → index-b95yhqjr.js} +12 -12
- package/{index-3d9y066c.js → index-bjwxs904.js} +9 -8
- package/{index-2xp0kfkt.js → index-br8pkrk1.js} +37 -25
- package/index-c14nsvnv.js +700 -0
- package/index-c6eggbee.js +123 -0
- package/index-d2242ksy.js +99 -0
- package/{index-92zztqy1.js → index-dy0jx9ay.js} +2 -17
- package/{index-a64esmtb.js → index-fkvb79qe.js} +523 -1022
- package/index-h54yj9wr.js +1119 -0
- package/{index-by5gpp8x.js → index-hj6w4ka1.js} +2 -1
- package/{index-y6n8nmny.js → index-kn5d4jmg.js} +75 -203
- package/index-m3xsb1ms.js +4300 -0
- package/{index-gyd220p2.js → index-mb59b8x0.js} +554 -577
- package/{index-j9yhg404.js → index-mzjb6zp4.js} +4 -7
- package/index-p6pbz9n5.js +25 -0
- package/{index-sj5vxr8f.js → index-qe71g4ze.js} +983 -898
- package/index-rfcz04w9.js +187 -0
- package/{index-hwkygn9s.js → index-senscydg.js} +331 -36
- package/{index-ffvk10zz.js → index-vs8mefhy.js} +107 -241
- package/index-wa5jbxj1.js +760 -0
- package/index-y5ga5w9t.js +2729 -0
- package/{index-9077wzd2.js → index-y7hx1ygz.js} +43 -26
- package/{index-h7yw2z9n.js → index-zzvvc845.js} +8 -14
- package/index.js +23 -22
- package/{library.command-qzzbj6d8.js → library.command-keqjevpp.js} +4 -5
- package/{localRegistry.command-vyrgg4xw.js → localRegistry.command-pydeq5zf.js} +23 -43
- package/{module.command-rq5hq3ax.js → module.command-dkrnqx3v.js} +8 -12
- package/{package.command-d9hd6v9n.js → package.command-wmc0ys5y.js} +6 -7
- package/package.json +15 -7
- package/{page.command-126d56te.js → page.command-tf3erhrv.js} +4 -5
- package/{primitive.command-taxd1538.js → primitive.command-7hqpegj4.js} +9 -23
- package/prompter-76k56b37.js +8 -0
- package/{quality.command-6gsna0a3.js → quality.command-8122axq3.js} +205 -377
- package/{recipeScanner-fpagtgc1.js → recipeScanner-4b69ybe0.js} +1 -1
- package/{repair.command-tq2dgy72.js → repair.command-mcy12h0n.js} +11 -35
- package/{routeSourceValidator-apyqw7wk.js → routeSourceValidator-7ycnfz0e.js} +0 -6
- package/{scalar.command-3bcmrrkv.js → scalar.command-vvvbzttc.js} +7 -11
- package/skills/akan-code/SKILL.md +130 -0
- package/skills/akan-debug/SKILL.md +42 -0
- package/skills/akan-deps/SKILL.md +50 -0
- package/skills/akan-err/SKILL.md +39 -0
- package/skills/akan-module/SKILL.md +45 -0
- package/skills/akan-scaffold/SKILL.md +76 -0
- package/skills/akan-scalar/SKILL.md +52 -0
- package/skills/akan-service/SKILL.md +34 -0
- package/skills/akan-store/SKILL.md +67 -0
- package/skills/akan-ui/SKILL.md +63 -0
- package/skills/akan-validate/SKILL.md +44 -0
- package/{subspace.command-eddzqpx3.js → subspace.command-pzvqfy5h.js} +53 -62
- package/templates/__scalar/__model__/__model__.abstract.md.template +8 -0
- package/templates/app/page/_index.tsx +257 -258
- package/templates/app/page/_layout.tsx +5 -1
- package/templates/app/page/_overrides.tsx +12 -0
- package/templates/app/page/styles.css.template +316 -14
- package/templates/app/public/apple-touch-icon.png +0 -0
- package/templates/app/public/favicon.ico +0 -0
- package/templates/app/public/jelly/cloud.webp +0 -0
- package/templates/app/public/jelly/comet.webp +0 -0
- package/templates/app/public/jelly/moon.webp +0 -0
- package/templates/app/public/jelly/planet.webp +0 -0
- package/templates/app/public/jelly/rocket.webp +0 -0
- package/templates/app/public/jelly/star.webp +0 -0
- package/templates/app/public/jelly/sugar.webp +0 -0
- package/templates/app/public/logo.png +0 -0
- package/templates/app/ui/Recipe/index.ts +9 -0
- package/templates/app/ui/Recipe/jellyButton.ts +63 -0
- package/templates/appSample/lib/__scalar/workHistory/workHistory.abstract.ts +8 -39
- package/templates/appSample/lib/_noti/noti.abstract.ts +6 -29
- package/templates/appSample/lib/task/Task.Unit.tsx +1 -1
- package/templates/appSample/lib/task/Task.Util.tsx +10 -13
- package/templates/appSample/lib/task/Task.View.tsx +2 -2
- package/templates/appSample/lib/task/Task.Zone.tsx +5 -2
- package/templates/appSample/lib/task/task.abstract.ts +12 -32
- package/templates/appSample/lib/task/task.signal.spec.ts +1 -15
- package/templates/appSample/lib/task/task.signal.test.ts +15 -1
- package/templates/appSample/lib/task/task.signal.ts +10 -8
- package/templates/appSample/page/task/[taskId]/_index.tsx +6 -6
- package/templates/appSample/page/task/[taskId]/edit.tsx +5 -4
- package/templates/appSample/page/task/_index.tsx +4 -3
- package/templates/appSample/page/task/_layout.tsx +1 -1
- package/templates/appSample/page/task/new.tsx +5 -4
- package/templates/appSample/srvkit/{AuthGuard.ts → guards.ts} +7 -4
- package/templates/appSample/srvkit/{SessionInternalArg.ts → internalArgs.ts} +6 -4
- package/templates/appSample/ui/GlobalLoading.tsx +2 -1
- package/templates/appSample/ui/QuantityControl.tsx +3 -3
- package/templates/client.ts +7 -30
- package/templates/crudPages/[__model__Id]/edit/page.tsx +2 -1
- package/templates/crudPages/[__model__Id]/page.tsx +2 -1
- package/templates/crudPages/new/page.tsx +2 -1
- package/templates/crudPages/page.tsx +2 -1
- package/templates/crudSinglePage/page.tsx +2 -1
- package/templates/lib/__lib/lib.dictionary.ts +0 -2
- package/templates/lib/__lib/lib.document.ts +0 -2
- package/templates/lib/sig.ts +8 -30
- package/templates/localDev/docker-compose.yaml.template +3 -14
- package/templates/module/__model__.signal.ts +12 -4
- package/templates/pkgRoot/tsconfig.json.template +2 -7
- package/templates/server.ts +1 -3
- package/templates/service/__model__.abstract.md.template +8 -0
- package/templates/workspaceRoot/.gitignore.template +0 -1
- package/templates/workspaceRoot/AGENTS.md.template +6 -0
- package/templates/workspaceRoot/package.json.template +1 -3
- package/tunnel.command-82zz5xnq.js +129 -0
- package/{typeChecker-3xgrzc2v.js → typeChecker-px49mezc.js} +1 -1
- package/typecheck.proc.js +1 -1
- package/workflow.command-y8x3kgjv.js +79 -0
- package/{workspace.command-06wvstgr.js → workspace.command-jvsb7brc.js} +79 -109
- package/abstractCompactor-gmkc0z8j.js +0 -102
- package/application.command-18y0s485.js +0 -204
- package/applicationReleasePackager-4yasxwv9.js +0 -244
- package/capacitorApp-36rbr858.js +0 -12
- package/cloud.command-av97ndh6.js +0 -94
- package/cloud.script-cm11xjdz.js +0 -20
- package/context.command-5v37ef3n.js +0 -81
- package/devTuiView-0hc2emhe.js +0 -9
- package/getDirname-dr3jz1xg.js +0 -7
- package/guideline.command-4pz9g1rt.js +0 -360
- package/guidelines/agentRule/agentRule.generate.json +0 -31
- package/guidelines/componentRule/componentRule.generate.json +0 -31
- package/guidelines/conventions/conventions.generate.json +0 -25
- package/guidelines/cssRule/cssRule.generate.json +0 -31
- package/guidelines/docPageRule/docPageRule.generate.json +0 -31
- package/guidelines/docPageRule/docPageRule.instruction.md +0 -25
- package/guidelines/docSyncRule/docSyncRule.generate.json +0 -31
- package/guidelines/docSyncRule/docSyncRule.instruction.md +0 -25
- package/guidelines/enumConstant/enumConstant.generate.json +0 -31
- package/guidelines/enumConstant/enumConstant.instruction.md +0 -28
- package/guidelines/fieldRule/fieldRule.generate.json +0 -31
- package/guidelines/framework/framework.generate.json +0 -32
- package/guidelines/mcpRule/mcpRule.generate.json +0 -35
- package/guidelines/modelConstant/modelConstant.generate.json +0 -32
- package/guidelines/modelDictionary/modelDictionary.generate.json +0 -32
- package/guidelines/modelDocument/modelDocument.generate.json +0 -31
- package/guidelines/modelService/modelService.generate.json +0 -31
- package/guidelines/modelSignal/modelSignal.generate.json +0 -31
- package/guidelines/modelStore/modelStore.generate.json +0 -31
- package/guidelines/modelTemplate/modelTemplate.generate.json +0 -31
- package/guidelines/modelUnit/modelUnit.generate.json +0 -31
- package/guidelines/modelUtil/modelUtil.generate.json +0 -31
- package/guidelines/modelView/modelView.generate.json +0 -31
- package/guidelines/modelZone/modelZone.generate.json +0 -31
- package/guidelines/moduleCodegen/moduleCodegen.generate.json +0 -31
- package/guidelines/moduleCodegen/moduleCodegen.instruction.md +0 -28
- package/guidelines/moduleOverview/moduleOverview.generate.json +0 -31
- package/guidelines/queryRule/queryRule.generate.json +0 -31
- package/guidelines/recipeRule/recipeRule.generate.json +0 -31
- package/guidelines/runtimeRule/runtimeRule.generate.json +0 -25
- package/guidelines/scalarConstant/scalarConstant.generate.json +0 -32
- package/guidelines/scalarDictionary/scalarDictionary.generate.json +0 -32
- package/guidelines/scalarModule/scalarModule.generate.json +0 -31
- package/guidelines/sharedUiUsage/sharedUiUsage.generate.json +0 -31
- package/guidelines/sharedUiUsage/sharedUiUsage.instruction.md +0 -25
- package/guidelines/ssrRule/ssrRule.generate.json +0 -31
- package/guidelines/transportRule/transportRule.generate.json +0 -31
- package/guidelines/utilUiUsage/utilUiUsage.generate.json +0 -31
- package/guidelines/utilUiUsage/utilUiUsage.instruction.md +0 -25
- package/guidelines/workspaceOnboarding/workspaceOnboarding.generate.json +0 -24
- package/guidelines/workspaceRecipes/workspaceRecipes.generate.json +0 -33
- package/index-47pj3aee.js +0 -76
- package/index-5ystnsd5.js +0 -841
- package/index-6wwzs1bc.js +0 -7
- package/index-a17x49vg.js +0 -229
- package/index-m0xccmmm.js +0 -228
- package/index-meh558jy.js +0 -65
- package/index-rtxxan88.js +0 -471
- package/index-te54x9zm.js +0 -338
- package/index-w8kmx1b6.js +0 -2176
- package/index-wt7qrtd4.js +0 -1516
- package/templates/__scalar/__model__/__model__.abstract.md +0 -28
- package/templates/module/__model__.abstract.md +0 -28
- package/templates/service/__model__.abstract.md +0 -28
- package/templates/workspaceRoot/patches/react-dom@19.2.7.patch.template +0 -62
- package/workflow.command-gtdnzvbz.js +0 -108
|
@@ -1,11 +1,294 @@
|
|
|
1
1
|
// @bun
|
|
2
|
+
// pkgs/@akanjs/devkit/applicationBuildReporter.ts
|
|
3
|
+
import { realpathSync } from "fs";
|
|
4
|
+
import path from "path";
|
|
5
|
+
import { Logger } from "akanjs/common";
|
|
6
|
+
|
|
7
|
+
class ApplicationBuildReporter {
|
|
8
|
+
static create() {
|
|
9
|
+
return {
|
|
10
|
+
phaseDone: (phase) => Logger.rawLog(ApplicationBuildReporter.formatPhaseLine(phase))
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
static printSummary(result) {
|
|
14
|
+
Logger.rawLog("");
|
|
15
|
+
Logger.rawLog(`Route artifacts: ${result.artifactDir}`);
|
|
16
|
+
Logger.rawLog(`Server output: ${result.outputDir}`);
|
|
17
|
+
Logger.rawLog(`Done in ${ApplicationBuildReporter.formatDuration(result.durationMs)}`);
|
|
18
|
+
}
|
|
19
|
+
static formatError(error, workspaceRoot = process.cwd()) {
|
|
20
|
+
if (error instanceof AggregateError) {
|
|
21
|
+
const nestedMessages = error.errors.map((nestedError, index) => ApplicationBuildReporter.formatError(nestedError, workspaceRoot).trim() || `Unknown error ${index + 1}`).map((message) => message.replace(/^/gm, " ")).join(`
|
|
22
|
+
`);
|
|
23
|
+
return nestedMessages ? `${error.message}
|
|
24
|
+
${nestedMessages}` : error.message;
|
|
25
|
+
}
|
|
26
|
+
if (error instanceof Error) {
|
|
27
|
+
const causeMessage = error.cause ? `
|
|
28
|
+
Caused by: ${ApplicationBuildReporter.formatError(error.cause, workspaceRoot)}` : "";
|
|
29
|
+
return `${ApplicationBuildReporter.#withLocation(error.message, error, workspaceRoot)}${causeMessage}`;
|
|
30
|
+
}
|
|
31
|
+
if (typeof error === "object" && error !== null && "message" in error)
|
|
32
|
+
return ApplicationBuildReporter.#withLocation(String(error.message), error, workspaceRoot);
|
|
33
|
+
return String(error);
|
|
34
|
+
}
|
|
35
|
+
static #withLocation(message, error, workspaceRoot) {
|
|
36
|
+
const { position } = error;
|
|
37
|
+
if (!position?.file)
|
|
38
|
+
return message;
|
|
39
|
+
const file = ApplicationBuildReporter.#relativeToWorkspace(position.file, workspaceRoot);
|
|
40
|
+
const location = position.line > 0 ? `${file}:${position.line}:${position.column}` : file;
|
|
41
|
+
return message.includes(location) ? message : message.replace(/^.*/, (headline) => `${headline} (${location})`);
|
|
42
|
+
}
|
|
43
|
+
static #relativeToWorkspace(file, workspaceRoot) {
|
|
44
|
+
if (!path.isAbsolute(file))
|
|
45
|
+
return file;
|
|
46
|
+
for (const root of [workspaceRoot, ApplicationBuildReporter.#realpathOf(workspaceRoot)]) {
|
|
47
|
+
const relative = path.relative(root, file);
|
|
48
|
+
if (!relative.startsWith(`..${path.sep}`) && !path.isAbsolute(relative))
|
|
49
|
+
return relative.replaceAll(path.sep, "/");
|
|
50
|
+
}
|
|
51
|
+
return file;
|
|
52
|
+
}
|
|
53
|
+
static #realpathOf(dir) {
|
|
54
|
+
try {
|
|
55
|
+
return realpathSync(dir);
|
|
56
|
+
} catch {
|
|
57
|
+
return dir;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
static formatDuration(ms) {
|
|
61
|
+
if (ms < 1000)
|
|
62
|
+
return `${ms}ms`;
|
|
63
|
+
if (ms < 60000)
|
|
64
|
+
return `${Math.round(ms / 100) / 10}s`;
|
|
65
|
+
const seconds = Math.floor(ms / 1000);
|
|
66
|
+
return `${Math.floor(seconds / 60)}m ${seconds % 60}s`;
|
|
67
|
+
}
|
|
68
|
+
static formatPhaseLine(phase) {
|
|
69
|
+
const summary = phase.summary ? `: ${phase.summary}` : "";
|
|
70
|
+
return `\u2713 ${phase.label}${summary} (${ApplicationBuildReporter.formatDuration(phase.durationMs)})`;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
|
|
2
74
|
// pkgs/@akanjs/devkit/frontendBuild/hmrWatcher.ts
|
|
3
75
|
import fs from "fs";
|
|
4
|
-
import
|
|
76
|
+
import path5 from "path";
|
|
5
77
|
|
|
6
78
|
// pkgs/@akanjs/devkit/frontendBuild/hmrChangeClassifier.ts
|
|
7
|
-
import
|
|
79
|
+
import path3 from "path";
|
|
80
|
+
|
|
81
|
+
// pkgs/@akanjs/devkit/akanApp/devHostPolicy.ts
|
|
82
|
+
import path2 from "path";
|
|
83
|
+
var BACKEND_RECOVERY_MAX_ATTEMPTS = 5;
|
|
84
|
+
var HELD_BUILDER_REQUEST_LIMIT = 64;
|
|
85
|
+
var BUILDER_MIN_RSS_RECYCLE_INTERVAL_MS = 30000;
|
|
86
|
+
var BUILDER_TIGHT_RSS_REPORT_LIMIT = 2;
|
|
87
|
+
var BUILDER_RSS_HARD_MULTIPLE = 1.5;
|
|
88
|
+
var DEV_IDLE_SUSPEND_MS = 300000;
|
|
89
|
+
var DEV_IDLE_MIN_UPTIME_MS = 30000;
|
|
8
90
|
var SOURCE_EXTS = new Set([".ts", ".tsx", ".js", ".jsx", ".mjs", ".cjs"]);
|
|
91
|
+
var SERVER_SUFFIXES = [".service.ts", ".document.ts"];
|
|
92
|
+
var SHARED_SUFFIXES = [".constant.ts", ".dictionary.ts", ".signal.ts"];
|
|
93
|
+
var RUNTIME_METADATA_BASENAMES = new Set(["dict.ts", "sig.ts", "useClient.ts", "useServer.ts"]);
|
|
94
|
+
var shouldRestartBackendByDevPlan = (message) => {
|
|
95
|
+
if (!message.devPlan)
|
|
96
|
+
return null;
|
|
97
|
+
if (message.devPlan.actions.includes("report-error"))
|
|
98
|
+
return false;
|
|
99
|
+
if (message.devPlan.actions.includes("restart-builder"))
|
|
100
|
+
return false;
|
|
101
|
+
return message.devPlan.actions.includes("restart-backend");
|
|
102
|
+
};
|
|
103
|
+
var shouldRestartBuilderByDevPlan = (message) => message.devPlan?.actions.includes("restart-builder") ?? false;
|
|
104
|
+
var shouldAbandonBackendRecovery = (attempts, maxAttempts = BACKEND_RECOVERY_MAX_ATTEMPTS) => attempts >= maxAttempts;
|
|
105
|
+
var normalizeBackendReportedGeneration = (generation) => generation >= 0 ? generation : undefined;
|
|
106
|
+
var shouldRestartDevHostByDevPlan = (message) => message.devPlan?.actions.includes("restart-dev-host") ?? message.kinds.includes("config");
|
|
107
|
+
var devHostStateByBackendState = {
|
|
108
|
+
starting: "starting",
|
|
109
|
+
ready: "ready",
|
|
110
|
+
"restart-pending": "restarting",
|
|
111
|
+
recovering: "recovering",
|
|
112
|
+
stopping: "stopped",
|
|
113
|
+
stopped: "stopped"
|
|
114
|
+
};
|
|
115
|
+
var devHostStateOf = (state, gaveUp) => state === "stopped" && gaveUp ? "failed" : devHostStateByBackendState[state];
|
|
116
|
+
var RESTART_ROLE_ORDER = ["server", "shared", "barrel", "config"];
|
|
117
|
+
var generationValue = (generation) => generation ?? -1;
|
|
118
|
+
var isLegacyBackendFallbackFile = (file, workspaceRoot) => {
|
|
119
|
+
const abs = path2.resolve(file);
|
|
120
|
+
const ext = path2.extname(abs).toLowerCase();
|
|
121
|
+
if (!SOURCE_EXTS.has(ext))
|
|
122
|
+
return false;
|
|
123
|
+
const rel = path2.relative(path2.resolve(workspaceRoot), abs);
|
|
124
|
+
if (!rel || rel.startsWith("..") || path2.isAbsolute(rel))
|
|
125
|
+
return false;
|
|
126
|
+
const parts = rel.split(path2.sep).filter(Boolean);
|
|
127
|
+
const [scope] = parts;
|
|
128
|
+
if (scope !== "apps" && scope !== "libs" && scope !== "pkgs")
|
|
129
|
+
return false;
|
|
130
|
+
const base = path2.basename(abs);
|
|
131
|
+
return parts.includes("srvkit") || parts.includes("common") || SERVER_SUFFIXES.some((suffix) => base.endsWith(suffix)) || SHARED_SUFFIXES.some((suffix) => base.endsWith(suffix)) || RUNTIME_METADATA_BASENAMES.has(base) || base === "main.ts" || base === "server.ts";
|
|
132
|
+
};
|
|
133
|
+
var shouldMarkBuildPhaseRecovered = (previousByPhase, status) => {
|
|
134
|
+
const previous = previousByPhase.get(status.phase);
|
|
135
|
+
if (!previous || previous.ok || !status.ok)
|
|
136
|
+
return false;
|
|
137
|
+
const generation = generationValue(status.generation);
|
|
138
|
+
if (status.phase === "route" && status.scope !== undefined && previous.scope !== undefined)
|
|
139
|
+
return status.scope === previous.scope && generation >= previous.generation;
|
|
140
|
+
if (generation !== previous.generation)
|
|
141
|
+
return generation > previous.generation;
|
|
142
|
+
return status.phase === "backend";
|
|
143
|
+
};
|
|
144
|
+
var shouldKeepBuildFailure = (previousByPhase, status) => status.ok && previousByPhase.get(status.phase)?.ok === false && !shouldMarkBuildPhaseRecovered(previousByPhase, status);
|
|
145
|
+
var createBackendBuildStatus = ({
|
|
146
|
+
generation,
|
|
147
|
+
ok,
|
|
148
|
+
files = [],
|
|
149
|
+
message
|
|
150
|
+
}) => ({
|
|
151
|
+
generation,
|
|
152
|
+
phase: "backend",
|
|
153
|
+
ok,
|
|
154
|
+
files,
|
|
155
|
+
message
|
|
156
|
+
});
|
|
157
|
+
var backendRestartReasonFromMessage = (message) => {
|
|
158
|
+
const roleSet = new Set;
|
|
159
|
+
for (const role of message.devPlan?.roles ?? []) {
|
|
160
|
+
if (role === "server" || role === "shared" || role === "barrel" || role === "config")
|
|
161
|
+
roleSet.add(role);
|
|
162
|
+
}
|
|
163
|
+
return {
|
|
164
|
+
generation: message.devPlan?.generation ?? message.generation,
|
|
165
|
+
files: [...new Set(message.files)].sort(),
|
|
166
|
+
roles: RESTART_ROLE_ORDER.filter((role) => roleSet.has(role))
|
|
167
|
+
};
|
|
168
|
+
};
|
|
169
|
+
var mergeBackendRestartReasons = (current, next) => ({
|
|
170
|
+
generation: generationValue(next.generation) >= generationValue(current?.generation) ? next.generation : current?.generation,
|
|
171
|
+
files: [...new Set([...current?.files ?? [], ...next.files])].sort(),
|
|
172
|
+
roles: RESTART_ROLE_ORDER.filter((role) => current?.roles.includes(role) || next.roles.includes(role))
|
|
173
|
+
});
|
|
174
|
+
var shouldReplaceLastGoodMessage = (current, next) => !current || generationValue(next.data.generation) >= generationValue(current.data.generation);
|
|
175
|
+
var shouldQueueBuildStatusReplay = (backendReady, pendingReplayCount) => !backendReady || pendingReplayCount > 0;
|
|
176
|
+
var hasBuildFailureForGeneration = (statusByPhase, generation) => {
|
|
177
|
+
if (typeof generation !== "number")
|
|
178
|
+
return false;
|
|
179
|
+
for (const status of statusByPhase.values()) {
|
|
180
|
+
if (!status.ok && status.phase !== "route" && status.generation === generation)
|
|
181
|
+
return true;
|
|
182
|
+
}
|
|
183
|
+
return false;
|
|
184
|
+
};
|
|
185
|
+
var decideBuilderRssRecycle = ({
|
|
186
|
+
rssBytes,
|
|
187
|
+
ceilingBytes,
|
|
188
|
+
buildFailed,
|
|
189
|
+
msSinceLastRecycle,
|
|
190
|
+
minIntervalMs = BUILDER_MIN_RSS_RECYCLE_INTERVAL_MS
|
|
191
|
+
}) => {
|
|
192
|
+
if (!ceilingBytes)
|
|
193
|
+
return "unbounded";
|
|
194
|
+
if (rssBytes < ceilingBytes)
|
|
195
|
+
return "below-ceiling";
|
|
196
|
+
if (buildFailed)
|
|
197
|
+
return "build-failed";
|
|
198
|
+
if (msSinceLastRecycle !== null && msSinceLastRecycle < minIntervalMs)
|
|
199
|
+
return "too-soon";
|
|
200
|
+
return "recycle";
|
|
201
|
+
};
|
|
202
|
+
var decideBuilderRssSettle = ({
|
|
203
|
+
rssBytes,
|
|
204
|
+
ceilingBytes,
|
|
205
|
+
hardMultiple = BUILDER_RSS_HARD_MULTIPLE
|
|
206
|
+
}) => rssBytes >= ceilingBytes * hardMultiple ? "recycle-now" : "wait-and-recheck";
|
|
207
|
+
var decideIdleSuspend = ({
|
|
208
|
+
enabled,
|
|
209
|
+
suspended,
|
|
210
|
+
builderReady,
|
|
211
|
+
backendReady,
|
|
212
|
+
buildFailed,
|
|
213
|
+
restartPending,
|
|
214
|
+
msSinceWake,
|
|
215
|
+
minUptimeMs = DEV_IDLE_MIN_UPTIME_MS
|
|
216
|
+
}) => {
|
|
217
|
+
if (!enabled)
|
|
218
|
+
return "disabled";
|
|
219
|
+
if (suspended)
|
|
220
|
+
return "already-suspended";
|
|
221
|
+
if (!builderReady)
|
|
222
|
+
return "builder-not-ready";
|
|
223
|
+
if (!backendReady)
|
|
224
|
+
return "backend-not-ready";
|
|
225
|
+
if (buildFailed)
|
|
226
|
+
return "build-failed";
|
|
227
|
+
if (restartPending)
|
|
228
|
+
return "restart-pending";
|
|
229
|
+
if (msSinceWake !== null && msSinceWake < minUptimeMs)
|
|
230
|
+
return "too-soon";
|
|
231
|
+
return "suspend";
|
|
232
|
+
};
|
|
233
|
+
var resolveIdleSuspendMs = (raw) => {
|
|
234
|
+
if (raw === undefined || raw === "")
|
|
235
|
+
return DEV_IDLE_SUSPEND_MS;
|
|
236
|
+
const parsed = Number(raw);
|
|
237
|
+
if (!Number.isFinite(parsed) || parsed <= 0)
|
|
238
|
+
return null;
|
|
239
|
+
return Math.round(parsed);
|
|
240
|
+
};
|
|
241
|
+
var hasAnyBuildFailure = (statusByPhase) => [...statusByPhase.values()].some((status) => !status.ok && status.phase !== "route");
|
|
242
|
+
var shouldRefreshConfigOnIdleWake = (batch) => !!batch && batch.kinds.has("config");
|
|
243
|
+
var RETURNING_BUILDER_STATUSES = new Set(["starting", "recycling", "restarting"]);
|
|
244
|
+
var shouldHoldForReturningBuilder = ({
|
|
245
|
+
status,
|
|
246
|
+
heldCount,
|
|
247
|
+
limit = HELD_BUILDER_REQUEST_LIMIT
|
|
248
|
+
}) => RETURNING_BUILDER_STATUSES.has(status) && heldCount < limit;
|
|
249
|
+
var shouldWarnBuilderRssCeilingTight = (reportsSinceRecycle, limit = BUILDER_TIGHT_RSS_REPORT_LIMIT) => reportsSinceRecycle >= limit;
|
|
250
|
+
var isRssCeilingUnreachable = (freshRssBytes, ceilingBytes) => freshRssBytes !== null && ceilingBytes !== null && freshRssBytes >= ceilingBytes;
|
|
251
|
+
var shouldRelayRecycledFrontendState = (current, next) => {
|
|
252
|
+
if (!current || current.type !== next.type)
|
|
253
|
+
return true;
|
|
254
|
+
if (current.type === "pages-updated" && next.type === "pages-updated")
|
|
255
|
+
return current.data.bundlePath !== next.data.bundlePath;
|
|
256
|
+
if (current.type === "css-updated" && next.type === "css-updated")
|
|
257
|
+
return JSON.stringify(current.data.cssAssets) !== JSON.stringify(next.data.cssAssets);
|
|
258
|
+
return true;
|
|
259
|
+
};
|
|
260
|
+
var mergeDevPlans = (current, next) => {
|
|
261
|
+
if (!current)
|
|
262
|
+
return next;
|
|
263
|
+
if (!next)
|
|
264
|
+
return current;
|
|
265
|
+
const reasonByFile = { ...current.reasonByFile };
|
|
266
|
+
for (const [file, reasons] of Object.entries(next.reasonByFile)) {
|
|
267
|
+
reasonByFile[file] = [...new Set([...reasonByFile[file] ?? [], ...reasons])].sort();
|
|
268
|
+
}
|
|
269
|
+
return {
|
|
270
|
+
generation: Math.max(current.generation, next.generation),
|
|
271
|
+
files: [...new Set([...current.files, ...next.files])].sort(),
|
|
272
|
+
generatedFiles: [...new Set([...current.generatedFiles, ...next.generatedFiles])].sort(),
|
|
273
|
+
roles: [...new Set([...current.roles, ...next.roles])].sort(),
|
|
274
|
+
actions: [...new Set([...current.actions, ...next.actions])].sort(),
|
|
275
|
+
reasonByFile
|
|
276
|
+
};
|
|
277
|
+
};
|
|
278
|
+
var mergeInvalidateMessages = (current, next) => {
|
|
279
|
+
const generation = Math.max(generationValue(current.generation), generationValue(next.generation));
|
|
280
|
+
return {
|
|
281
|
+
type: "invalidate",
|
|
282
|
+
kinds: [...new Set([...current.kinds, ...next.kinds])].sort(),
|
|
283
|
+
files: [...new Set([...current.files, ...next.files])].sort(),
|
|
284
|
+
generation: generation >= 0 ? generation : undefined,
|
|
285
|
+
devPlan: mergeDevPlans(current.devPlan, next.devPlan)
|
|
286
|
+
};
|
|
287
|
+
};
|
|
288
|
+
var buildStatusReplaySequence = (pendingReplay, latestByPhase) => [...pendingReplay, ...latestByPhase.values()];
|
|
289
|
+
var filesChangedSince = (before, after) => [...before].filter(([file, stamp]) => after.get(file) !== stamp).map(([file]) => file);
|
|
290
|
+
|
|
291
|
+
// pkgs/@akanjs/devkit/frontendBuild/hmrChangeClassifier.ts
|
|
9
292
|
var CSS_EXTS = new Set([".css"]);
|
|
10
293
|
var CONFIG_BASENAMES = new Set(["akan.config.ts", "bunfig.toml", "tsconfig.json", "package.json"]);
|
|
11
294
|
|
|
@@ -13,10 +296,10 @@ class HmrChangeClassifier {
|
|
|
13
296
|
classify(abs) {
|
|
14
297
|
if (this.#isUninteresting(abs))
|
|
15
298
|
return "ignore";
|
|
16
|
-
const base =
|
|
299
|
+
const base = path3.basename(abs);
|
|
17
300
|
if (CONFIG_BASENAMES.has(base))
|
|
18
301
|
return "config";
|
|
19
|
-
const ext =
|
|
302
|
+
const ext = path3.extname(abs).toLowerCase();
|
|
20
303
|
if (CSS_EXTS.has(ext))
|
|
21
304
|
return "css";
|
|
22
305
|
if (SOURCE_EXTS.has(ext))
|
|
@@ -24,16 +307,16 @@ class HmrChangeClassifier {
|
|
|
24
307
|
return "ignore";
|
|
25
308
|
}
|
|
26
309
|
#isUninteresting(abs) {
|
|
27
|
-
const base =
|
|
310
|
+
const base = path3.basename(abs);
|
|
28
311
|
if (!base)
|
|
29
312
|
return true;
|
|
30
313
|
if (base.startsWith("."))
|
|
31
314
|
return true;
|
|
32
315
|
if (base.endsWith("~") || base.endsWith(".swp") || base.endsWith(".swx") || base.endsWith(".tmp"))
|
|
33
316
|
return true;
|
|
34
|
-
if (abs.includes(`${
|
|
317
|
+
if (abs.includes(`${path3.sep}node_modules${path3.sep}`))
|
|
35
318
|
return true;
|
|
36
|
-
if (abs.includes(`${
|
|
319
|
+
if (abs.includes(`${path3.sep}.akan${path3.sep}`))
|
|
37
320
|
return true;
|
|
38
321
|
return false;
|
|
39
322
|
}
|
|
@@ -41,7 +324,7 @@ class HmrChangeClassifier {
|
|
|
41
324
|
|
|
42
325
|
// pkgs/@akanjs/devkit/frontendBuild/sourceMtimeIndex.ts
|
|
43
326
|
import { readdir, stat } from "fs/promises";
|
|
44
|
-
import
|
|
327
|
+
import path4 from "path";
|
|
45
328
|
var UNREADABLE = Number.NaN;
|
|
46
329
|
|
|
47
330
|
class SourceMtimeIndex {
|
|
@@ -104,7 +387,7 @@ class SourceMtimeIndex {
|
|
|
104
387
|
if (!this.#primed)
|
|
105
388
|
return;
|
|
106
389
|
await Promise.all(paths.map(async (file) => {
|
|
107
|
-
const abs =
|
|
390
|
+
const abs = path4.resolve(file);
|
|
108
391
|
const stats = await stat(abs).catch(() => null);
|
|
109
392
|
if (!stats?.isFile()) {
|
|
110
393
|
this.#files.delete(abs);
|
|
@@ -190,7 +473,7 @@ class SourceMtimeIndex {
|
|
|
190
473
|
for (const entry of entries) {
|
|
191
474
|
if (SourceMtimeIndex.#skipDirent(entry.name))
|
|
192
475
|
continue;
|
|
193
|
-
const abs =
|
|
476
|
+
const abs = path4.join(dir, entry.name);
|
|
194
477
|
if (entry.isDirectory()) {
|
|
195
478
|
descend.push(abs);
|
|
196
479
|
continue;
|
|
@@ -217,7 +500,7 @@ class SourceMtimeIndex {
|
|
|
217
500
|
}
|
|
218
501
|
if (known) {
|
|
219
502
|
for (const abs of [...this.#files.keys()]) {
|
|
220
|
-
if (present.has(abs) ||
|
|
503
|
+
if (present.has(abs) || path4.dirname(abs) !== dir)
|
|
221
504
|
continue;
|
|
222
505
|
this.#files.delete(abs);
|
|
223
506
|
changed?.add(abs);
|
|
@@ -235,7 +518,7 @@ class SourceMtimeIndex {
|
|
|
235
518
|
this.#unsettled.delete(dir);
|
|
236
519
|
}
|
|
237
520
|
#forget(dir) {
|
|
238
|
-
const prefix = `${dir}${
|
|
521
|
+
const prefix = `${dir}${path4.sep}`;
|
|
239
522
|
this.#dirs.delete(dir);
|
|
240
523
|
this.#unreadable.delete(dir);
|
|
241
524
|
this.#unsettled.delete(dir);
|
|
@@ -273,8 +556,8 @@ class SourceMtimeIndex {
|
|
|
273
556
|
return !name || name.startsWith(".") || name === "node_modules";
|
|
274
557
|
}
|
|
275
558
|
static #pruneNestedRoots(roots) {
|
|
276
|
-
const resolved = [...new Set(roots.map((root) =>
|
|
277
|
-
return resolved.filter((root) => !resolved.some((other) => other !== root && root.startsWith(`${other}${
|
|
559
|
+
const resolved = [...new Set(roots.map((root) => path4.resolve(root)))].sort();
|
|
560
|
+
return resolved.filter((root) => !resolved.some((other) => other !== root && root.startsWith(`${other}${path4.sep}`)));
|
|
278
561
|
}
|
|
279
562
|
}
|
|
280
563
|
|
|
@@ -292,14 +575,15 @@ class HmrWatcher {
|
|
|
292
575
|
#index;
|
|
293
576
|
#timer = null;
|
|
294
577
|
#verifyTimer = null;
|
|
578
|
+
#windowStartedAt = null;
|
|
295
579
|
#stopped = false;
|
|
296
580
|
#flushing = false;
|
|
297
581
|
#unreportedChanges = 0;
|
|
298
582
|
#reportedCompensating = false;
|
|
299
583
|
#reportedGaps = "";
|
|
300
584
|
constructor(opts) {
|
|
301
|
-
this.#roots = [...new Set(opts.roots.map((r) =>
|
|
302
|
-
this.#debounceMs = opts.debounceMs ??
|
|
585
|
+
this.#roots = [...new Set(opts.roots.map((r) => path5.resolve(r)))];
|
|
586
|
+
this.#debounceMs = opts.debounceMs ?? HmrWatcher.#envDebounceMs() ?? 30;
|
|
303
587
|
this.#verifyDelayMs = opts.verifyDelayMs ?? 250;
|
|
304
588
|
this.#onBatch = opts.onBatch;
|
|
305
589
|
this.#logger = opts.logger;
|
|
@@ -314,9 +598,15 @@ class HmrWatcher {
|
|
|
314
598
|
const w = fs.watch(root, { recursive: true, persistent: false }, (_event, filename) => {
|
|
315
599
|
if (!filename)
|
|
316
600
|
return;
|
|
317
|
-
const abs =
|
|
601
|
+
const abs = path5.resolve(root, filename.toString());
|
|
318
602
|
this.#queue(abs);
|
|
319
603
|
});
|
|
604
|
+
w.on("error", (err) => {
|
|
605
|
+
if (err.code === "EACCES" || err.code === "EPERM")
|
|
606
|
+
this.#logger.verbose(`[hmr] ${err.message}`);
|
|
607
|
+
else
|
|
608
|
+
this.#logger.warn(`[hmr] watcher error under ${root}: ${err.message}`);
|
|
609
|
+
});
|
|
320
610
|
this.#watchers.push(w);
|
|
321
611
|
this.#logger.verbose(`[hmr] watching ${root}`);
|
|
322
612
|
} catch (err) {
|
|
@@ -365,6 +655,7 @@ class HmrWatcher {
|
|
|
365
655
|
this.#scheduleFlush();
|
|
366
656
|
}
|
|
367
657
|
#scheduleFlush() {
|
|
658
|
+
this.#windowStartedAt ??= Date.now();
|
|
368
659
|
if (this.#flushing)
|
|
369
660
|
return;
|
|
370
661
|
if (this.#timer)
|
|
@@ -382,14 +673,19 @@ class HmrWatcher {
|
|
|
382
673
|
try {
|
|
383
674
|
while (!this.#stopped) {
|
|
384
675
|
await this.#mergeDetectedChanges();
|
|
385
|
-
if (this.#pending.size === 0)
|
|
676
|
+
if (this.#pending.size === 0) {
|
|
677
|
+
this.#windowStartedAt = null;
|
|
386
678
|
break;
|
|
679
|
+
}
|
|
387
680
|
const files = Array.from(this.#pending.keys());
|
|
388
681
|
const kinds = new Set(this.#pending.values());
|
|
682
|
+
const flushAt = Date.now();
|
|
683
|
+
const trace = { eventAt: this.#windowStartedAt ?? flushAt, flushAt };
|
|
684
|
+
this.#windowStartedAt = null;
|
|
389
685
|
this.#pending.clear();
|
|
390
686
|
this.#hinted.clear();
|
|
391
687
|
try {
|
|
392
|
-
await this.#onBatch({ files, kinds });
|
|
688
|
+
await this.#onBatch({ files, kinds, trace });
|
|
393
689
|
} catch (e) {
|
|
394
690
|
this.#logger.error(`[hmr] onBatch error: ${e.message}`);
|
|
395
691
|
}
|
|
@@ -440,6 +736,11 @@ class HmrWatcher {
|
|
|
440
736
|
const rest = gaps.length > 3 ? ` and ${gaps.length - 3} more` : "";
|
|
441
737
|
this.#logger.warn(`[hmr] cannot read ${gaps.length} path(s), so edits underneath them will not rebuild: ${shown}${rest}`);
|
|
442
738
|
}
|
|
739
|
+
static #envDebounceMs() {
|
|
740
|
+
const raw = process.env.AKAN_DEV_WATCH_DEBOUNCE_MS;
|
|
741
|
+
const ms = raw ? Number(raw) : Number.NaN;
|
|
742
|
+
return Number.isInteger(ms) && ms >= 0 ? ms : null;
|
|
743
|
+
}
|
|
443
744
|
#scheduleVerify() {
|
|
444
745
|
if (this.#stopped || this.#verifyDelayMs <= 0)
|
|
445
746
|
return;
|
|
@@ -464,7 +765,7 @@ class HmrWatcher {
|
|
|
464
765
|
// pkgs/@akanjs/devkit/frontendBuild/watchRootResolver.ts
|
|
465
766
|
import fs2 from "fs";
|
|
466
767
|
import { readFile } from "fs/promises";
|
|
467
|
-
import
|
|
768
|
+
import path6 from "path";
|
|
468
769
|
|
|
469
770
|
class WatchRootResolver {
|
|
470
771
|
#app;
|
|
@@ -473,20 +774,20 @@ class WatchRootResolver {
|
|
|
473
774
|
}
|
|
474
775
|
async resolve() {
|
|
475
776
|
const tsconfig = await this.#app.getTsConfig();
|
|
476
|
-
const appDir =
|
|
477
|
-
const appsContainer =
|
|
478
|
-
const libsContainer =
|
|
479
|
-
const libRoots = await this.#
|
|
777
|
+
const appDir = path6.resolve(this.#app.cwdPath);
|
|
778
|
+
const appsContainer = path6.dirname(appDir);
|
|
779
|
+
const libsContainer = path6.resolve(this.#app.workspace.workspaceRoot, "libs");
|
|
780
|
+
const libRoots = (await this.#resolveLibDeps(libsContainer))?.map((name) => path6.join(libsContainer, name)).filter((dir) => fs2.existsSync(dir));
|
|
480
781
|
const set = new Set;
|
|
481
|
-
set.add(
|
|
782
|
+
set.add(path6.resolve(`${this.#app.cwdPath}/page`));
|
|
482
783
|
for (const targets of Object.values(tsconfig.compilerOptions.paths ?? {})) {
|
|
483
784
|
for (const target of targets) {
|
|
484
785
|
if (!target)
|
|
485
786
|
continue;
|
|
486
|
-
if (
|
|
787
|
+
if (path6.isAbsolute(target))
|
|
487
788
|
continue;
|
|
488
789
|
const cleaned = target.replace(/\/?\*+.*$/, "").replace(/\/[^/]+\.[^/]+$/, "");
|
|
489
|
-
const resolved =
|
|
790
|
+
const resolved = path6.resolve(this.#app.workspace.workspaceRoot, cleaned);
|
|
490
791
|
if (resolved === libsContainer && libRoots) {
|
|
491
792
|
for (const root of libRoots)
|
|
492
793
|
set.add(root);
|
|
@@ -499,17 +800,11 @@ class WatchRootResolver {
|
|
|
499
800
|
}
|
|
500
801
|
return [...set];
|
|
501
802
|
}
|
|
502
|
-
async#resolveLibRoots(libsContainer) {
|
|
503
|
-
const libDeps = await this.#resolveLibDeps(libsContainer);
|
|
504
|
-
if (!libDeps)
|
|
505
|
-
return null;
|
|
506
|
-
return libDeps.map((name) => path4.join(libsContainer, name)).filter((dir) => fs2.existsSync(dir));
|
|
507
|
-
}
|
|
508
803
|
async#resolveLibDeps(libsContainer) {
|
|
509
804
|
const scanInfo = this.#app.getScanInfo({ allowEmpty: true });
|
|
510
805
|
if (scanInfo?.type === "app")
|
|
511
806
|
return scanInfo.libDeps;
|
|
512
|
-
const direct = await WatchRootResolver.#readManifestLibDeps(
|
|
807
|
+
const direct = await WatchRootResolver.#readManifestLibDeps(path6.join(this.#app.cwdPath, "akan.app.json"));
|
|
513
808
|
if (!direct)
|
|
514
809
|
return null;
|
|
515
810
|
const closure = new Set;
|
|
@@ -519,7 +814,7 @@ class WatchRootResolver {
|
|
|
519
814
|
if (!name || closure.has(name))
|
|
520
815
|
continue;
|
|
521
816
|
closure.add(name);
|
|
522
|
-
const nested = await WatchRootResolver.#readManifestLibDeps(
|
|
817
|
+
const nested = await WatchRootResolver.#readManifestLibDeps(path6.join(libsContainer, name, "akan.lib.json"));
|
|
523
818
|
if (!nested)
|
|
524
819
|
return null;
|
|
525
820
|
queue.push(...nested);
|
|
@@ -538,4 +833,4 @@ class WatchRootResolver {
|
|
|
538
833
|
}
|
|
539
834
|
}
|
|
540
835
|
|
|
541
|
-
export { HmrWatcher, WatchRootResolver };
|
|
836
|
+
export { ApplicationBuildReporter, BUILDER_MIN_RSS_RECYCLE_INTERVAL_MS, SOURCE_EXTS, shouldRestartBackendByDevPlan, shouldRestartBuilderByDevPlan, shouldAbandonBackendRecovery, normalizeBackendReportedGeneration, shouldRestartDevHostByDevPlan, devHostStateOf, isLegacyBackendFallbackFile, shouldMarkBuildPhaseRecovered, shouldKeepBuildFailure, createBackendBuildStatus, backendRestartReasonFromMessage, mergeBackendRestartReasons, shouldReplaceLastGoodMessage, shouldQueueBuildStatusReplay, hasBuildFailureForGeneration, decideBuilderRssRecycle, decideBuilderRssSettle, decideIdleSuspend, resolveIdleSuspendMs, hasAnyBuildFailure, shouldRefreshConfigOnIdleWake, shouldHoldForReturningBuilder, shouldWarnBuilderRssCeilingTight, isRssCeilingUnreachable, shouldRelayRecycledFrontendState, mergeInvalidateMessages, buildStatusReplaySequence, filesChangedSince, HmrWatcher, WatchRootResolver };
|