@hyperframes/producer 0.9.103 → 0.9.106
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/dist/compileWorker.js +15 -24
- package/dist/distributed.js +35 -44
- package/dist/hyperframe.manifest.json +1 -1
- package/dist/hyperframe.runtime.iife.js +69 -69
- package/dist/index.js +45 -54
- package/dist/public-server.js +34 -43
- package/dist/utils/paths.d.ts +2 -6
- package/package.json +8 -8
package/dist/index.js
CHANGED
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
mkdirSync as mkdirSync15,
|
|
14
14
|
readdirSync as readdirSync6,
|
|
15
15
|
rmSync as rmSync13,
|
|
16
|
-
statSync as
|
|
16
|
+
statSync as statSync9,
|
|
17
17
|
writeFileSync as writeFileSync8,
|
|
18
18
|
copyFileSync as copyFileSync5,
|
|
19
19
|
appendFileSync
|
|
@@ -379,7 +379,7 @@ import {
|
|
|
379
379
|
import {
|
|
380
380
|
existsSync as existsSync2,
|
|
381
381
|
realpathSync,
|
|
382
|
-
statSync
|
|
382
|
+
statSync,
|
|
383
383
|
createReadStream,
|
|
384
384
|
openSync,
|
|
385
385
|
fstatSync,
|
|
@@ -537,15 +537,12 @@ import {
|
|
|
537
537
|
relative as nodeRelative,
|
|
538
538
|
isAbsolute as nodeIsAbsolute
|
|
539
539
|
} from "node:path";
|
|
540
|
-
import { statSync } from "node:fs";
|
|
541
540
|
import { fileURLToPath as fileURLToPath2 } from "node:url";
|
|
542
541
|
import { isPrivateFileUnder, isSafePath, isStudioPrivatePath } from "@hyperframes/core/safe-path";
|
|
543
542
|
import {
|
|
544
|
-
isCopiedOutsideFileType,
|
|
545
|
-
isPrivateOutsideFile,
|
|
546
|
-
isUploadedOutsideFileType,
|
|
547
543
|
leftOutWarning,
|
|
548
|
-
linksOutside
|
|
544
|
+
linksOutside,
|
|
545
|
+
outsideLinkRefusal
|
|
549
546
|
} from "@hyperframes/studio-server/outside-file";
|
|
550
547
|
import { realFilePath } from "@hyperframes/studio-server/safe-path";
|
|
551
548
|
var DEFAULT_RENDERS_DIR = process.env.PRODUCER_RENDERS_DIR ?? // fileURLToPath (not URL.pathname): on Windows .pathname is "/D:/..." which
|
|
@@ -566,15 +563,9 @@ function escapesAssetRoot(path, assetRoot) {
|
|
|
566
563
|
return assetRoot !== void 0 && !isSafePath(assetRoot, path);
|
|
567
564
|
}
|
|
568
565
|
function outsideAssetRefusal(projectDir, path, policy = {}) {
|
|
569
|
-
if (
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
}
|
|
573
|
-
if (isPrivateOutsideFile(projectDir, path)) return "blocklisted";
|
|
574
|
-
const folder = statSync(path, { throwIfNoEntry: false })?.isDirectory();
|
|
575
|
-
if (folder || isUploadedOutsideFileType(path)) return null;
|
|
576
|
-
if (!isCopiedOutsideFileType(path)) return "file_type";
|
|
577
|
-
return policy.includeScripts ? null : "script";
|
|
566
|
+
if (linksOutside(projectDir, path)) return outsideLinkRefusal(projectDir, path, policy);
|
|
567
|
+
const privateByAnotherSpelling = !isPathInside(path, projectDir) && isPrivateFileUnder(projectDir, path, isStudioPrivatePath);
|
|
568
|
+
return privateByAnotherSpelling ? "blocklisted" : null;
|
|
578
569
|
}
|
|
579
570
|
var leftOutOfRender = (file, reference, reason) => leftOutWarning(file, reference, reason, "render");
|
|
580
571
|
function refusesOutsideLink(projectDir, path, warn, policy = {}) {
|
|
@@ -1143,7 +1134,7 @@ function openRegularFile(filePath) {
|
|
|
1143
1134
|
} catch (error) {
|
|
1144
1135
|
if (error instanceof Error && "code" in error && NO_FILE_AT_NAME.has(String(error.code)))
|
|
1145
1136
|
return null;
|
|
1146
|
-
if (!
|
|
1137
|
+
if (!statSync(filePath, { throwIfNoEntry: false })?.isFile()) return null;
|
|
1147
1138
|
throw error;
|
|
1148
1139
|
}
|
|
1149
1140
|
let accepted = false;
|
|
@@ -2663,7 +2654,7 @@ function replanAfterFailure(plan2, failure) {
|
|
|
2663
2654
|
}
|
|
2664
2655
|
|
|
2665
2656
|
// src/services/render/stages/captureSegmentedStage.ts
|
|
2666
|
-
import { existsSync as existsSync7, mkdirSync as mkdirSync5, rmSync as rmSync6, statSync as
|
|
2657
|
+
import { existsSync as existsSync7, mkdirSync as mkdirSync5, rmSync as rmSync6, statSync as statSync3 } from "node:fs";
|
|
2667
2658
|
import { join as join12 } from "node:path";
|
|
2668
2659
|
import {
|
|
2669
2660
|
captureFrameToBuffer as captureFrameToBuffer2,
|
|
@@ -3587,7 +3578,7 @@ async function compositeHdrFrame(ctx, canvas, time, fullStacking, elementFilter,
|
|
|
3587
3578
|
}
|
|
3588
3579
|
|
|
3589
3580
|
// src/services/render/stages/captureHdrResources.ts
|
|
3590
|
-
import { mkdirSync as mkdirSync3, readFileSync as readFileSync3, rmSync as rmSync5, statSync as
|
|
3581
|
+
import { mkdirSync as mkdirSync3, readFileSync as readFileSync3, rmSync as rmSync5, statSync as statSync2, statfsSync } from "node:fs";
|
|
3591
3582
|
import {
|
|
3592
3583
|
decodePngToRgb48le,
|
|
3593
3584
|
extractMediaMetadata as extractMediaMetadata2,
|
|
@@ -4012,7 +4003,7 @@ async function extractHdrVideoFrames(args) {
|
|
|
4012
4003
|
failureReason: result.failureReason
|
|
4013
4004
|
});
|
|
4014
4005
|
}
|
|
4015
|
-
return Math.min(Math.floor(
|
|
4006
|
+
return Math.min(Math.floor(statSync2(spec.path).size / frameSize), spec.frames);
|
|
4016
4007
|
}
|
|
4017
4008
|
});
|
|
4018
4009
|
const first = await windows.lease(0);
|
|
@@ -5561,7 +5552,7 @@ async function captureSegmentToEncoder(ctx, segment) {
|
|
|
5561
5552
|
path: segmentPath,
|
|
5562
5553
|
// Recorded so resume can prove the file on disk is the one that
|
|
5563
5554
|
// finished; absent only in unit tests, whose fake encoder writes none.
|
|
5564
|
-
bytes: existsSync7(segmentPath) ?
|
|
5555
|
+
bytes: existsSync7(segmentPath) ? statSync3(segmentPath).size : 0,
|
|
5565
5556
|
sha256: existsSync7(segmentPath) ? await hashSegmentFile(segmentPath) : ""
|
|
5566
5557
|
});
|
|
5567
5558
|
return encodeResult;
|
|
@@ -6623,7 +6614,7 @@ function createSegmentVideoFrames(input) {
|
|
|
6623
6614
|
}
|
|
6624
6615
|
|
|
6625
6616
|
// src/services/render/videoFrameWindow.ts
|
|
6626
|
-
import { readdirSync as readdirSync3, statSync as
|
|
6617
|
+
import { readdirSync as readdirSync3, statSync as statSync4 } from "node:fs";
|
|
6627
6618
|
import { join as join16 } from "node:path";
|
|
6628
6619
|
function shouldWindowVideoFrames(args) {
|
|
6629
6620
|
return args.segmented && args.env.HF_VIDEO_FRAME_WINDOW?.trim().toLowerCase() === "true";
|
|
@@ -6639,7 +6630,7 @@ function directoryBytes(path) {
|
|
|
6639
6630
|
for (const entry of entries) {
|
|
6640
6631
|
const child3 = join16(path, entry.name);
|
|
6641
6632
|
try {
|
|
6642
|
-
bytes += entry.isDirectory() ? directoryBytes(child3) :
|
|
6633
|
+
bytes += entry.isDirectory() ? directoryBytes(child3) : statSync4(child3).size;
|
|
6643
6634
|
} catch {
|
|
6644
6635
|
}
|
|
6645
6636
|
}
|
|
@@ -7365,9 +7356,10 @@ import {
|
|
|
7365
7356
|
stylesheetLinkMatches
|
|
7366
7357
|
} from "@hyperframes/parsers/css-url-scans";
|
|
7367
7358
|
import { createHash as createHash6 } from "node:crypto";
|
|
7368
|
-
import { createReadStream as createReadStream3, existsSync as existsSync11, mkdirSync as mkdirSync11, readFileSync as readFileSync9, statSync as
|
|
7359
|
+
import { createReadStream as createReadStream3, existsSync as existsSync11, mkdirSync as mkdirSync11, readFileSync as readFileSync9, statSync as statSync7 } from "fs";
|
|
7369
7360
|
import { join as join21, dirname as dirname10, resolve as resolve8, basename as basename6, relative as relative3, sep as sep4 } from "path";
|
|
7370
7361
|
import { parseHTML as parseHTML5 } from "@hyperframes/parsers/linkedom";
|
|
7362
|
+
import { compositionRootSize } from "@hyperframes/parsers";
|
|
7371
7363
|
|
|
7372
7364
|
// src/services/bundledScripts.ts
|
|
7373
7365
|
import { existsSync as existsSync8, readFileSync as readFileSync6 } from "node:fs";
|
|
@@ -7653,7 +7645,7 @@ import {
|
|
|
7653
7645
|
|
|
7654
7646
|
// src/services/animatedGifPrep.ts
|
|
7655
7647
|
import { createHash as createHash4, randomUUID } from "node:crypto";
|
|
7656
|
-
import { copyFileSync as copyFileSync2, existsSync as existsSync9, mkdirSync as mkdirSync9, readFileSync as readFileSync7, rmSync as rmSync9, statSync as
|
|
7648
|
+
import { copyFileSync as copyFileSync2, existsSync as existsSync9, mkdirSync as mkdirSync9, readFileSync as readFileSync7, rmSync as rmSync9, statSync as statSync5 } from "node:fs";
|
|
7657
7649
|
import { dirname as dirname7, isAbsolute as isAbsolute3, join as join18, resolve as resolve6 } from "node:path";
|
|
7658
7650
|
import { parseHTML as parseHTML3 } from "@hyperframes/parsers/linkedom";
|
|
7659
7651
|
import { parseAnimatedGifMetadata } from "@hyperframes/core";
|
|
@@ -7716,7 +7708,7 @@ function resolveLocalImageSourcePath(src, options) {
|
|
|
7716
7708
|
}
|
|
7717
7709
|
function isUsableFile(path) {
|
|
7718
7710
|
try {
|
|
7719
|
-
const stat =
|
|
7711
|
+
const stat = statSync5(path);
|
|
7720
7712
|
return stat.isFile() && stat.size > 0;
|
|
7721
7713
|
} catch {
|
|
7722
7714
|
return false;
|
|
@@ -7866,7 +7858,7 @@ async function ensurePreparedWebm(input) {
|
|
|
7866
7858
|
if (!isUsableFile(tmpPath)) {
|
|
7867
7859
|
throw new Error("Animated GIF transcode produced an empty output");
|
|
7868
7860
|
}
|
|
7869
|
-
if (
|
|
7861
|
+
if (statSync5(tmpPath).size >= FFMPEG_SELF_OUTPUT_BYTES_CAP) {
|
|
7870
7862
|
throw new Error("Animated GIF transcode reached its output size limit");
|
|
7871
7863
|
}
|
|
7872
7864
|
if (!isUsableFile(input.cachePath)) {
|
|
@@ -8002,7 +7994,7 @@ import {
|
|
|
8002
7994
|
readFileSync as readFileSync8,
|
|
8003
7995
|
readSync as readSync3,
|
|
8004
7996
|
rmSync as rmSync10,
|
|
8005
|
-
statSync as
|
|
7997
|
+
statSync as statSync6,
|
|
8006
7998
|
writeFileSync as writeFileSync4
|
|
8007
7999
|
} from "node:fs";
|
|
8008
8000
|
import { dirname as dirname8, join as join19, resolve as resolve7 } from "node:path";
|
|
@@ -8258,7 +8250,7 @@ function resolveImageSource(src, options) {
|
|
|
8258
8250
|
}
|
|
8259
8251
|
function isUsableFile2(path) {
|
|
8260
8252
|
try {
|
|
8261
|
-
return
|
|
8253
|
+
return statSync6(path).size > 0;
|
|
8262
8254
|
} catch {
|
|
8263
8255
|
return false;
|
|
8264
8256
|
}
|
|
@@ -8279,7 +8271,7 @@ async function ensurePreparedJpeg(source, cachePath, outputPath, options) {
|
|
|
8279
8271
|
signal: options.signal
|
|
8280
8272
|
});
|
|
8281
8273
|
if (!isUsableFile2(tmpPath)) throw new Error("conversion produced an empty file");
|
|
8282
|
-
if (
|
|
8274
|
+
if (statSync6(tmpPath).size >= FFMPEG_SELF_OUTPUT_BYTES_CAP2) {
|
|
8283
8275
|
throw new Error("conversion reached its output size limit");
|
|
8284
8276
|
}
|
|
8285
8277
|
renameWithRetry3(tmpPath, cachePath);
|
|
@@ -9957,7 +9949,7 @@ async function localFontDataUri(localPath, projectDir, assetRoot, dataUriByAbsol
|
|
|
9957
9949
|
if (dataUriByAbsolutePath.has(absPath)) return dataUriByAbsolutePath.get(absPath);
|
|
9958
9950
|
const ext = absPath.match(/\.(woff2?|ttf|otf|ttc)$/i)?.[1]?.toLowerCase() ?? "ttf";
|
|
9959
9951
|
try {
|
|
9960
|
-
if (!reserve(Math.ceil(
|
|
9952
|
+
if (!reserve(Math.ceil(statSync7(absPath).size / 3) * 4 + 64)) {
|
|
9961
9953
|
dataUriByAbsolutePath.set(absPath, void 0);
|
|
9962
9954
|
return void 0;
|
|
9963
9955
|
}
|
|
@@ -10342,8 +10334,7 @@ async function compileWithAssets(projectDir, htmlPath, downloadDir, options, ass
|
|
|
10342
10334
|
}
|
|
10343
10335
|
const { document: document2 } = parseHTML5(html);
|
|
10344
10336
|
const rootEl = document2.querySelector("[data-composition-id]");
|
|
10345
|
-
const width
|
|
10346
|
-
const height = rootEl ? parseInt(rootEl.getAttribute("data-height") || "1920", 10) : 1920;
|
|
10337
|
+
const { width, height } = compositionRootSize(rootEl);
|
|
10347
10338
|
const staticDuration = rootEl ? parseStrictFiniteTimingNumber(rootEl.getAttribute("data-duration")) ?? parseStrictFiniteTimingNumber(rootEl.getAttribute("data-composition-duration")) ?? 0 : 0;
|
|
10348
10339
|
return {
|
|
10349
10340
|
html,
|
|
@@ -15012,7 +15003,7 @@ import {
|
|
|
15012
15003
|
readdirSync as readdirSync5,
|
|
15013
15004
|
readFileSync as readFileSync10,
|
|
15014
15005
|
rmSync as rmSync12,
|
|
15015
|
-
statSync as
|
|
15006
|
+
statSync as statSync8,
|
|
15016
15007
|
writeFileSync as writeFileSync7
|
|
15017
15008
|
} from "node:fs";
|
|
15018
15009
|
import { readFile as readFile2 } from "node:fs/promises";
|
|
@@ -15141,7 +15132,7 @@ async function encodeGifFromDir(framesDir, framePattern, outputPath, input) {
|
|
|
15141
15132
|
const failure = await reencodeWithClearedWholeFrames(argsInput, run, startTime);
|
|
15142
15133
|
if (failure) return failure;
|
|
15143
15134
|
}
|
|
15144
|
-
const fileSize = existsSync21(outputPath) ?
|
|
15135
|
+
const fileSize = existsSync21(outputPath) ? statSync8(outputPath).size : 0;
|
|
15145
15136
|
return {
|
|
15146
15137
|
success: true,
|
|
15147
15138
|
outputPath,
|
|
@@ -15555,7 +15546,7 @@ function sampleDirectoryBytes(dir) {
|
|
|
15555
15546
|
for (const name of entries) {
|
|
15556
15547
|
const full = join36(current, name);
|
|
15557
15548
|
try {
|
|
15558
|
-
const st =
|
|
15549
|
+
const st = statSync9(full);
|
|
15559
15550
|
if (st.isDirectory()) {
|
|
15560
15551
|
stack.push(full);
|
|
15561
15552
|
} else if (st.isFile()) {
|
|
@@ -15719,7 +15710,7 @@ function findMissingFrameRanges(totalFrames, framesDir, frameExt) {
|
|
|
15719
15710
|
let rangeStart = null;
|
|
15720
15711
|
for (let frameIndex = 0; frameIndex < totalFrames; frameIndex++) {
|
|
15721
15712
|
const framePath = join36(framesDir, formatCaptureFrameName(frameIndex, frameExt));
|
|
15722
|
-
const missing = !existsSync22(framePath) ||
|
|
15713
|
+
const missing = !existsSync22(framePath) || statSync9(framePath).size <= 8;
|
|
15723
15714
|
if (missing && rangeStart === null) {
|
|
15724
15715
|
rangeStart = frameIndex;
|
|
15725
15716
|
} else if (!missing && rangeStart !== null) {
|
|
@@ -21563,7 +21554,7 @@ import {
|
|
|
21563
21554
|
readFileSync as readFileSync14,
|
|
21564
21555
|
readdirSync as readdirSync10,
|
|
21565
21556
|
rmSync as rmSync17,
|
|
21566
|
-
statSync as
|
|
21557
|
+
statSync as statSync11,
|
|
21567
21558
|
writeFileSync as writeFileSync13
|
|
21568
21559
|
} from "node:fs";
|
|
21569
21560
|
import { tmpdir as tmpdir4 } from "node:os";
|
|
@@ -21582,7 +21573,7 @@ import {
|
|
|
21582
21573
|
linkSync as linkSync2,
|
|
21583
21574
|
mkdirSync as mkdirSync20,
|
|
21584
21575
|
rmSync as rmSync16,
|
|
21585
|
-
statSync as
|
|
21576
|
+
statSync as statSync10,
|
|
21586
21577
|
writeFileSync as writeFileSync12
|
|
21587
21578
|
} from "node:fs";
|
|
21588
21579
|
import { renameWithRetry as renameWithRetry8 } from "@hyperframes/engine";
|
|
@@ -21652,7 +21643,7 @@ var LocalPlanV2ArtifactPublisher = class {
|
|
|
21652
21643
|
}
|
|
21653
21644
|
async putBlob(blob) {
|
|
21654
21645
|
const digest = assertPlanV2Sha256(blob.sha256, "published blob sha256");
|
|
21655
|
-
const sourceSize =
|
|
21646
|
+
const sourceSize = statSync10(blob.sourcePath).size;
|
|
21656
21647
|
if (sourceSize !== blob.sizeBytes) {
|
|
21657
21648
|
throw new PlanV2IntegrityError(
|
|
21658
21649
|
`published blob size changed for ${digest}: expected ${blob.sizeBytes}, got ${sourceSize}`
|
|
@@ -21966,7 +21957,7 @@ function publishBlobFor(absolutePath, digests) {
|
|
|
21966
21957
|
return {
|
|
21967
21958
|
sourcePath: absolutePath,
|
|
21968
21959
|
sha256: planFileSha256(absolutePath, digests),
|
|
21969
|
-
sizeBytes:
|
|
21960
|
+
sizeBytes: statSync11(absolutePath).size
|
|
21970
21961
|
};
|
|
21971
21962
|
}
|
|
21972
21963
|
async function putBlobs(publisher, blobs) {
|
|
@@ -22337,7 +22328,7 @@ function verifyBlob(planV2Dir, artifact) {
|
|
|
22337
22328
|
if (!existsSync29(sourcePath)) {
|
|
22338
22329
|
throw new PlanV2IntegrityError(`missing content-addressed artifact ${artifact.sha256}`);
|
|
22339
22330
|
}
|
|
22340
|
-
const stats =
|
|
22331
|
+
const stats = statSync11(sourcePath);
|
|
22341
22332
|
if (!stats.isFile() || stats.size !== artifact.sizeBytes) {
|
|
22342
22333
|
throw new PlanV2IntegrityError(`artifact size mismatch for ${artifact.path}`);
|
|
22343
22334
|
}
|
|
@@ -22430,7 +22421,7 @@ function readValidatedPlanV2Materialization(planDir, expectedTarget) {
|
|
|
22430
22421
|
for (const artifact of required) {
|
|
22431
22422
|
if (Object.hasOwn(remoteSources, artifact.path)) continue;
|
|
22432
22423
|
const path = join48(planDir, ...artifact.path.split("/"));
|
|
22433
|
-
if (!existsSync29(path) ||
|
|
22424
|
+
if (!existsSync29(path) || statSync11(path).size !== artifact.sizeBytes) {
|
|
22434
22425
|
throw new PlanV2IntegrityError(
|
|
22435
22426
|
`materialized artifact missing or truncated: ${artifact.path}`
|
|
22436
22427
|
);
|
|
@@ -23884,7 +23875,7 @@ import {
|
|
|
23884
23875
|
lstatSync as lstatSync6,
|
|
23885
23876
|
mkdirSync as mkdirSync24,
|
|
23886
23877
|
openSync as openSync9,
|
|
23887
|
-
statSync as
|
|
23878
|
+
statSync as statSync13,
|
|
23888
23879
|
mkdtempSync as mkdtempSync2,
|
|
23889
23880
|
writeFileSync as writeFileSync15,
|
|
23890
23881
|
rmSync as rmSync20,
|
|
@@ -23911,7 +23902,7 @@ import { foreignWritablePath } from "@hyperframes/core/cache-dir";
|
|
|
23911
23902
|
import {
|
|
23912
23903
|
existsSync as existsSync31,
|
|
23913
23904
|
readFileSync as readFileSync17,
|
|
23914
|
-
statSync as
|
|
23905
|
+
statSync as statSync12,
|
|
23915
23906
|
openSync as openSync8,
|
|
23916
23907
|
fstatSync as fstatSync4,
|
|
23917
23908
|
closeSync as closeSync8,
|
|
@@ -23952,7 +23943,7 @@ function readEntryHtml(filePath) {
|
|
|
23952
23943
|
} catch (error) {
|
|
23953
23944
|
if (error instanceof Error && "code" in error && (error.code === "ENOENT" || error.code === "ENOTDIR"))
|
|
23954
23945
|
return null;
|
|
23955
|
-
if (!
|
|
23946
|
+
if (!statSync12(filePath, { throwIfNoEntry: false })?.isFile()) return null;
|
|
23956
23947
|
throw error;
|
|
23957
23948
|
}
|
|
23958
23949
|
try {
|
|
@@ -23968,7 +23959,7 @@ function leavesProject(absProjectDir, absoluteEntryPath, isAllowedEntry) {
|
|
|
23968
23959
|
}
|
|
23969
23960
|
function readProjectEntryFile(projectDir, preferredEntryFile, isAllowedEntry) {
|
|
23970
23961
|
const absProjectDir = resolve13(projectDir);
|
|
23971
|
-
if (!existsSync31(absProjectDir) || !
|
|
23962
|
+
if (!existsSync31(absProjectDir) || !statSync12(absProjectDir).isDirectory()) {
|
|
23972
23963
|
return { error: `Project directory not found: ${absProjectDir}` };
|
|
23973
23964
|
}
|
|
23974
23965
|
const entryCandidates = [preferredEntryFile, "index.html", "src/index.html"].filter(
|
|
@@ -24470,7 +24461,7 @@ function prepareProjectDirectory(projectDir, options, policy) {
|
|
|
24470
24461
|
if (!candidate) return null;
|
|
24471
24462
|
const absProjectDir = policy ? resolve14(policy.projectsDir, candidate) : resolve14(candidate);
|
|
24472
24463
|
const shown = policy ? candidate : absProjectDir;
|
|
24473
|
-
if (policy && !isAllowedProjectPath(policy.projectsDir, absProjectDir) || !existsSync33(absProjectDir) || !
|
|
24464
|
+
if (policy && !isAllowedProjectPath(policy.projectsDir, absProjectDir) || !existsSync33(absProjectDir) || !statSync13(absProjectDir).isDirectory()) {
|
|
24474
24465
|
return { error: `Project directory not found: ${shown}` };
|
|
24475
24466
|
}
|
|
24476
24467
|
const entry = options.entryFile || "index.html";
|
|
@@ -24612,7 +24603,7 @@ function publicPerfSummary(job) {
|
|
|
24612
24603
|
return job.perfSummary ? { ...job.perfSummary, renderId: void 0 } : null;
|
|
24613
24604
|
}
|
|
24614
24605
|
function outputFileSize(path) {
|
|
24615
|
-
return existsSync33(path) ?
|
|
24606
|
+
return existsSync33(path) ? statSync13(path).size : 0;
|
|
24616
24607
|
}
|
|
24617
24608
|
function createBlockingProgressReporter(log, requestId) {
|
|
24618
24609
|
let lastLoggedPct = -10;
|
|
@@ -25186,7 +25177,7 @@ import {
|
|
|
25186
25177
|
readFileSync as readFileSync18,
|
|
25187
25178
|
readdirSync as readdirSync12,
|
|
25188
25179
|
rmSync as rmSync21,
|
|
25189
|
-
statSync as
|
|
25180
|
+
statSync as statSync14
|
|
25190
25181
|
} from "node:fs";
|
|
25191
25182
|
import { localContainerInputArgs as localContainerInputArgs2 } from "@hyperframes/parsers/ff-binaries";
|
|
25192
25183
|
import { basename as basename10, dirname as dirname24, join as join54 } from "node:path";
|
|
@@ -25233,7 +25224,7 @@ async function assemble(planDir, chunkOutputs, audioPath, outputPath, options) {
|
|
|
25233
25224
|
outputPath,
|
|
25234
25225
|
durationMs: Date.now() - start,
|
|
25235
25226
|
framesEncoded: plan2.totalFrames,
|
|
25236
|
-
fileSize:
|
|
25227
|
+
fileSize: statSync14(outputPath).size
|
|
25237
25228
|
};
|
|
25238
25229
|
}
|
|
25239
25230
|
const format = plan2.dimensions.format;
|
|
@@ -25280,7 +25271,7 @@ async function assemble(planDir, chunkOutputs, audioPath, outputPath, options) {
|
|
|
25280
25271
|
});
|
|
25281
25272
|
}
|
|
25282
25273
|
}
|
|
25283
|
-
const fileSize = existsSync34(outputPath) ?
|
|
25274
|
+
const fileSize = existsSync34(outputPath) ? statSync14(outputPath).size : 0;
|
|
25284
25275
|
return {
|
|
25285
25276
|
...referenceBackgroundResult8(plan2[REFERENCE_BACKGROUND_FIELD6]),
|
|
25286
25277
|
outputPath,
|
|
@@ -25479,7 +25470,7 @@ function mergePngFrameDirs(chunkPaths, outputPath, totalFrames, audioPath, start
|
|
|
25479
25470
|
mkdirSync25(outputPath, { recursive: true });
|
|
25480
25471
|
let globalIdx = 0;
|
|
25481
25472
|
for (const chunkDir of chunkPaths) {
|
|
25482
|
-
if (!
|
|
25473
|
+
if (!statSync14(chunkDir).isDirectory()) {
|
|
25483
25474
|
throw new Error(
|
|
25484
25475
|
`[assemble] png-sequence chunk must be a directory: ${chunkDir} (got a file)`
|
|
25485
25476
|
);
|
|
@@ -25506,7 +25497,7 @@ function mergePngFrameDirs(chunkPaths, outputPath, totalFrames, audioPath, start
|
|
|
25506
25497
|
let fileSize = 0;
|
|
25507
25498
|
for (const name of readdirSync12(outputPath)) {
|
|
25508
25499
|
try {
|
|
25509
|
-
fileSize +=
|
|
25500
|
+
fileSize += statSync14(join54(outputPath, name)).size;
|
|
25510
25501
|
} catch {
|
|
25511
25502
|
}
|
|
25512
25503
|
}
|
package/dist/public-server.js
CHANGED
|
@@ -25,7 +25,7 @@ import {
|
|
|
25
25
|
lstatSync as lstatSync4,
|
|
26
26
|
mkdirSync as mkdirSync16,
|
|
27
27
|
openSync as openSync7,
|
|
28
|
-
statSync as
|
|
28
|
+
statSync as statSync11,
|
|
29
29
|
mkdtempSync,
|
|
30
30
|
writeFileSync as writeFileSync9,
|
|
31
31
|
rmSync as rmSync14,
|
|
@@ -55,7 +55,7 @@ import {
|
|
|
55
55
|
mkdirSync as mkdirSync15,
|
|
56
56
|
readdirSync as readdirSync6,
|
|
57
57
|
rmSync as rmSync13,
|
|
58
|
-
statSync as
|
|
58
|
+
statSync as statSync9,
|
|
59
59
|
writeFileSync as writeFileSync8,
|
|
60
60
|
copyFileSync as copyFileSync5,
|
|
61
61
|
appendFileSync
|
|
@@ -421,7 +421,7 @@ import {
|
|
|
421
421
|
import {
|
|
422
422
|
existsSync as existsSync2,
|
|
423
423
|
realpathSync,
|
|
424
|
-
statSync
|
|
424
|
+
statSync,
|
|
425
425
|
createReadStream,
|
|
426
426
|
openSync,
|
|
427
427
|
fstatSync,
|
|
@@ -579,15 +579,12 @@ import {
|
|
|
579
579
|
relative as nodeRelative,
|
|
580
580
|
isAbsolute as nodeIsAbsolute
|
|
581
581
|
} from "node:path";
|
|
582
|
-
import { statSync } from "node:fs";
|
|
583
582
|
import { fileURLToPath as fileURLToPath2 } from "node:url";
|
|
584
583
|
import { isPrivateFileUnder, isSafePath, isStudioPrivatePath } from "@hyperframes/core/safe-path";
|
|
585
584
|
import {
|
|
586
|
-
isCopiedOutsideFileType,
|
|
587
|
-
isPrivateOutsideFile,
|
|
588
|
-
isUploadedOutsideFileType,
|
|
589
585
|
leftOutWarning,
|
|
590
|
-
linksOutside
|
|
586
|
+
linksOutside,
|
|
587
|
+
outsideLinkRefusal
|
|
591
588
|
} from "@hyperframes/studio-server/outside-file";
|
|
592
589
|
import { realFilePath } from "@hyperframes/studio-server/safe-path";
|
|
593
590
|
var DEFAULT_RENDERS_DIR = process.env.PRODUCER_RENDERS_DIR ?? // fileURLToPath (not URL.pathname): on Windows .pathname is "/D:/..." which
|
|
@@ -608,15 +605,9 @@ function escapesAssetRoot(path, assetRoot) {
|
|
|
608
605
|
return assetRoot !== void 0 && !isSafePath(assetRoot, path);
|
|
609
606
|
}
|
|
610
607
|
function outsideAssetRefusal(projectDir, path, policy = {}) {
|
|
611
|
-
if (
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
}
|
|
615
|
-
if (isPrivateOutsideFile(projectDir, path)) return "blocklisted";
|
|
616
|
-
const folder = statSync(path, { throwIfNoEntry: false })?.isDirectory();
|
|
617
|
-
if (folder || isUploadedOutsideFileType(path)) return null;
|
|
618
|
-
if (!isCopiedOutsideFileType(path)) return "file_type";
|
|
619
|
-
return policy.includeScripts ? null : "script";
|
|
608
|
+
if (linksOutside(projectDir, path)) return outsideLinkRefusal(projectDir, path, policy);
|
|
609
|
+
const privateByAnotherSpelling = !isPathInside(path, projectDir) && isPrivateFileUnder(projectDir, path, isStudioPrivatePath);
|
|
610
|
+
return privateByAnotherSpelling ? "blocklisted" : null;
|
|
620
611
|
}
|
|
621
612
|
var leftOutOfRender = (file, reference, reason) => leftOutWarning(file, reference, reason, "render");
|
|
622
613
|
function refusesOutsideLink(projectDir, path, warn, policy = {}) {
|
|
@@ -1185,7 +1176,7 @@ function openRegularFile(filePath) {
|
|
|
1185
1176
|
} catch (error) {
|
|
1186
1177
|
if (error instanceof Error && "code" in error && NO_FILE_AT_NAME.has(String(error.code)))
|
|
1187
1178
|
return null;
|
|
1188
|
-
if (!
|
|
1179
|
+
if (!statSync(filePath, { throwIfNoEntry: false })?.isFile()) return null;
|
|
1189
1180
|
throw error;
|
|
1190
1181
|
}
|
|
1191
1182
|
let accepted = false;
|
|
@@ -2701,7 +2692,7 @@ function replanAfterFailure(plan, failure) {
|
|
|
2701
2692
|
}
|
|
2702
2693
|
|
|
2703
2694
|
// src/services/render/stages/captureSegmentedStage.ts
|
|
2704
|
-
import { existsSync as existsSync7, mkdirSync as mkdirSync5, rmSync as rmSync6, statSync as
|
|
2695
|
+
import { existsSync as existsSync7, mkdirSync as mkdirSync5, rmSync as rmSync6, statSync as statSync3 } from "node:fs";
|
|
2705
2696
|
import { join as join12 } from "node:path";
|
|
2706
2697
|
import {
|
|
2707
2698
|
captureFrameToBuffer as captureFrameToBuffer2,
|
|
@@ -3625,7 +3616,7 @@ async function compositeHdrFrame(ctx, canvas, time, fullStacking, elementFilter,
|
|
|
3625
3616
|
}
|
|
3626
3617
|
|
|
3627
3618
|
// src/services/render/stages/captureHdrResources.ts
|
|
3628
|
-
import { mkdirSync as mkdirSync3, readFileSync as readFileSync3, rmSync as rmSync5, statSync as
|
|
3619
|
+
import { mkdirSync as mkdirSync3, readFileSync as readFileSync3, rmSync as rmSync5, statSync as statSync2, statfsSync } from "node:fs";
|
|
3629
3620
|
import {
|
|
3630
3621
|
decodePngToRgb48le,
|
|
3631
3622
|
extractMediaMetadata as extractMediaMetadata2,
|
|
@@ -4050,7 +4041,7 @@ async function extractHdrVideoFrames(args) {
|
|
|
4050
4041
|
failureReason: result.failureReason
|
|
4051
4042
|
});
|
|
4052
4043
|
}
|
|
4053
|
-
return Math.min(Math.floor(
|
|
4044
|
+
return Math.min(Math.floor(statSync2(spec.path).size / frameSize), spec.frames);
|
|
4054
4045
|
}
|
|
4055
4046
|
});
|
|
4056
4047
|
const first = await windows.lease(0);
|
|
@@ -5599,7 +5590,7 @@ async function captureSegmentToEncoder(ctx, segment) {
|
|
|
5599
5590
|
path: segmentPath,
|
|
5600
5591
|
// Recorded so resume can prove the file on disk is the one that
|
|
5601
5592
|
// finished; absent only in unit tests, whose fake encoder writes none.
|
|
5602
|
-
bytes: existsSync7(segmentPath) ?
|
|
5593
|
+
bytes: existsSync7(segmentPath) ? statSync3(segmentPath).size : 0,
|
|
5603
5594
|
sha256: existsSync7(segmentPath) ? await hashSegmentFile(segmentPath) : ""
|
|
5604
5595
|
});
|
|
5605
5596
|
return encodeResult;
|
|
@@ -6661,7 +6652,7 @@ function createSegmentVideoFrames(input) {
|
|
|
6661
6652
|
}
|
|
6662
6653
|
|
|
6663
6654
|
// src/services/render/videoFrameWindow.ts
|
|
6664
|
-
import { readdirSync as readdirSync3, statSync as
|
|
6655
|
+
import { readdirSync as readdirSync3, statSync as statSync4 } from "node:fs";
|
|
6665
6656
|
import { join as join16 } from "node:path";
|
|
6666
6657
|
function shouldWindowVideoFrames(args) {
|
|
6667
6658
|
return args.segmented && args.env.HF_VIDEO_FRAME_WINDOW?.trim().toLowerCase() === "true";
|
|
@@ -6677,7 +6668,7 @@ function directoryBytes(path) {
|
|
|
6677
6668
|
for (const entry of entries) {
|
|
6678
6669
|
const child2 = join16(path, entry.name);
|
|
6679
6670
|
try {
|
|
6680
|
-
bytes += entry.isDirectory() ? directoryBytes(child2) :
|
|
6671
|
+
bytes += entry.isDirectory() ? directoryBytes(child2) : statSync4(child2).size;
|
|
6681
6672
|
} catch {
|
|
6682
6673
|
}
|
|
6683
6674
|
}
|
|
@@ -7387,9 +7378,10 @@ import {
|
|
|
7387
7378
|
stylesheetLinkMatches
|
|
7388
7379
|
} from "@hyperframes/parsers/css-url-scans";
|
|
7389
7380
|
import { createHash as createHash6 } from "node:crypto";
|
|
7390
|
-
import { createReadStream as createReadStream3, existsSync as existsSync11, mkdirSync as mkdirSync11, readFileSync as readFileSync9, statSync as
|
|
7381
|
+
import { createReadStream as createReadStream3, existsSync as existsSync11, mkdirSync as mkdirSync11, readFileSync as readFileSync9, statSync as statSync7 } from "fs";
|
|
7391
7382
|
import { join as join21, dirname as dirname10, resolve as resolve8, basename as basename6, relative as relative3, sep as sep4 } from "path";
|
|
7392
7383
|
import { parseHTML as parseHTML5 } from "@hyperframes/parsers/linkedom";
|
|
7384
|
+
import { compositionRootSize } from "@hyperframes/parsers";
|
|
7393
7385
|
|
|
7394
7386
|
// src/services/bundledScripts.ts
|
|
7395
7387
|
import { existsSync as existsSync8, readFileSync as readFileSync6 } from "node:fs";
|
|
@@ -7675,7 +7667,7 @@ import {
|
|
|
7675
7667
|
|
|
7676
7668
|
// src/services/animatedGifPrep.ts
|
|
7677
7669
|
import { createHash as createHash4, randomUUID } from "node:crypto";
|
|
7678
|
-
import { copyFileSync as copyFileSync2, existsSync as existsSync9, mkdirSync as mkdirSync9, readFileSync as readFileSync7, rmSync as rmSync9, statSync as
|
|
7670
|
+
import { copyFileSync as copyFileSync2, existsSync as existsSync9, mkdirSync as mkdirSync9, readFileSync as readFileSync7, rmSync as rmSync9, statSync as statSync5 } from "node:fs";
|
|
7679
7671
|
import { dirname as dirname7, isAbsolute as isAbsolute3, join as join18, resolve as resolve6 } from "node:path";
|
|
7680
7672
|
import { parseHTML as parseHTML3 } from "@hyperframes/parsers/linkedom";
|
|
7681
7673
|
import { parseAnimatedGifMetadata } from "@hyperframes/core";
|
|
@@ -7738,7 +7730,7 @@ function resolveLocalImageSourcePath(src, options) {
|
|
|
7738
7730
|
}
|
|
7739
7731
|
function isUsableFile(path) {
|
|
7740
7732
|
try {
|
|
7741
|
-
const stat =
|
|
7733
|
+
const stat = statSync5(path);
|
|
7742
7734
|
return stat.isFile() && stat.size > 0;
|
|
7743
7735
|
} catch {
|
|
7744
7736
|
return false;
|
|
@@ -7888,7 +7880,7 @@ async function ensurePreparedWebm(input) {
|
|
|
7888
7880
|
if (!isUsableFile(tmpPath)) {
|
|
7889
7881
|
throw new Error("Animated GIF transcode produced an empty output");
|
|
7890
7882
|
}
|
|
7891
|
-
if (
|
|
7883
|
+
if (statSync5(tmpPath).size >= FFMPEG_SELF_OUTPUT_BYTES_CAP) {
|
|
7892
7884
|
throw new Error("Animated GIF transcode reached its output size limit");
|
|
7893
7885
|
}
|
|
7894
7886
|
if (!isUsableFile(input.cachePath)) {
|
|
@@ -8024,7 +8016,7 @@ import {
|
|
|
8024
8016
|
readFileSync as readFileSync8,
|
|
8025
8017
|
readSync as readSync3,
|
|
8026
8018
|
rmSync as rmSync10,
|
|
8027
|
-
statSync as
|
|
8019
|
+
statSync as statSync6,
|
|
8028
8020
|
writeFileSync as writeFileSync4
|
|
8029
8021
|
} from "node:fs";
|
|
8030
8022
|
import { dirname as dirname8, join as join19, resolve as resolve7 } from "node:path";
|
|
@@ -8280,7 +8272,7 @@ function resolveImageSource(src, options) {
|
|
|
8280
8272
|
}
|
|
8281
8273
|
function isUsableFile2(path) {
|
|
8282
8274
|
try {
|
|
8283
|
-
return
|
|
8275
|
+
return statSync6(path).size > 0;
|
|
8284
8276
|
} catch {
|
|
8285
8277
|
return false;
|
|
8286
8278
|
}
|
|
@@ -8301,7 +8293,7 @@ async function ensurePreparedJpeg(source, cachePath, outputPath, options) {
|
|
|
8301
8293
|
signal: options.signal
|
|
8302
8294
|
});
|
|
8303
8295
|
if (!isUsableFile2(tmpPath)) throw new Error("conversion produced an empty file");
|
|
8304
|
-
if (
|
|
8296
|
+
if (statSync6(tmpPath).size >= FFMPEG_SELF_OUTPUT_BYTES_CAP2) {
|
|
8305
8297
|
throw new Error("conversion reached its output size limit");
|
|
8306
8298
|
}
|
|
8307
8299
|
renameWithRetry3(tmpPath, cachePath);
|
|
@@ -9976,7 +9968,7 @@ async function localFontDataUri(localPath, projectDir, assetRoot, dataUriByAbsol
|
|
|
9976
9968
|
if (dataUriByAbsolutePath.has(absPath)) return dataUriByAbsolutePath.get(absPath);
|
|
9977
9969
|
const ext = absPath.match(/\.(woff2?|ttf|otf|ttc)$/i)?.[1]?.toLowerCase() ?? "ttf";
|
|
9978
9970
|
try {
|
|
9979
|
-
if (!reserve(Math.ceil(
|
|
9971
|
+
if (!reserve(Math.ceil(statSync7(absPath).size / 3) * 4 + 64)) {
|
|
9980
9972
|
dataUriByAbsolutePath.set(absPath, void 0);
|
|
9981
9973
|
return void 0;
|
|
9982
9974
|
}
|
|
@@ -10361,8 +10353,7 @@ async function compileWithAssets(projectDir, htmlPath, downloadDir, options, ass
|
|
|
10361
10353
|
}
|
|
10362
10354
|
const { document: document2 } = parseHTML5(html);
|
|
10363
10355
|
const rootEl = document2.querySelector("[data-composition-id]");
|
|
10364
|
-
const width
|
|
10365
|
-
const height = rootEl ? parseInt(rootEl.getAttribute("data-height") || "1920", 10) : 1920;
|
|
10356
|
+
const { width, height } = compositionRootSize(rootEl);
|
|
10366
10357
|
const staticDuration = rootEl ? parseStrictFiniteTimingNumber(rootEl.getAttribute("data-duration")) ?? parseStrictFiniteTimingNumber(rootEl.getAttribute("data-composition-duration")) ?? 0 : 0;
|
|
10367
10358
|
return {
|
|
10368
10359
|
html,
|
|
@@ -14994,7 +14985,7 @@ import {
|
|
|
14994
14985
|
readdirSync as readdirSync5,
|
|
14995
14986
|
readFileSync as readFileSync10,
|
|
14996
14987
|
rmSync as rmSync12,
|
|
14997
|
-
statSync as
|
|
14988
|
+
statSync as statSync8,
|
|
14998
14989
|
writeFileSync as writeFileSync7
|
|
14999
14990
|
} from "node:fs";
|
|
15000
14991
|
import { readFile as readFile2 } from "node:fs/promises";
|
|
@@ -15123,7 +15114,7 @@ async function encodeGifFromDir(framesDir, framePattern, outputPath, input) {
|
|
|
15123
15114
|
const failure = await reencodeWithClearedWholeFrames(argsInput, run, startTime);
|
|
15124
15115
|
if (failure) return failure;
|
|
15125
15116
|
}
|
|
15126
|
-
const fileSize = existsSync21(outputPath) ?
|
|
15117
|
+
const fileSize = existsSync21(outputPath) ? statSync8(outputPath).size : 0;
|
|
15127
15118
|
return {
|
|
15128
15119
|
success: true,
|
|
15129
15120
|
outputPath,
|
|
@@ -15537,7 +15528,7 @@ function sampleDirectoryBytes(dir) {
|
|
|
15537
15528
|
for (const name of entries) {
|
|
15538
15529
|
const full = join36(current, name);
|
|
15539
15530
|
try {
|
|
15540
|
-
const st =
|
|
15531
|
+
const st = statSync9(full);
|
|
15541
15532
|
if (st.isDirectory()) {
|
|
15542
15533
|
stack.push(full);
|
|
15543
15534
|
} else if (st.isFile()) {
|
|
@@ -15701,7 +15692,7 @@ function findMissingFrameRanges(totalFrames, framesDir, frameExt) {
|
|
|
15701
15692
|
let rangeStart = null;
|
|
15702
15693
|
for (let frameIndex = 0; frameIndex < totalFrames; frameIndex++) {
|
|
15703
15694
|
const framePath = join36(framesDir, formatCaptureFrameName(frameIndex, frameExt));
|
|
15704
|
-
const missing = !existsSync22(framePath) ||
|
|
15695
|
+
const missing = !existsSync22(framePath) || statSync9(framePath).size <= 8;
|
|
15705
15696
|
if (missing && rangeStart === null) {
|
|
15706
15697
|
rangeStart = frameIndex;
|
|
15707
15698
|
} else if (!missing && rangeStart !== null) {
|
|
@@ -18825,7 +18816,7 @@ async function executeRenderPipeline(input) {
|
|
|
18825
18816
|
import {
|
|
18826
18817
|
existsSync as existsSync23,
|
|
18827
18818
|
readFileSync as readFileSync11,
|
|
18828
|
-
statSync as
|
|
18819
|
+
statSync as statSync10,
|
|
18829
18820
|
openSync as openSync6,
|
|
18830
18821
|
fstatSync as fstatSync4,
|
|
18831
18822
|
closeSync as closeSync6,
|
|
@@ -18866,7 +18857,7 @@ function readEntryHtml(filePath) {
|
|
|
18866
18857
|
} catch (error) {
|
|
18867
18858
|
if (error instanceof Error && "code" in error && (error.code === "ENOENT" || error.code === "ENOTDIR"))
|
|
18868
18859
|
return null;
|
|
18869
|
-
if (!
|
|
18860
|
+
if (!statSync10(filePath, { throwIfNoEntry: false })?.isFile()) return null;
|
|
18870
18861
|
throw error;
|
|
18871
18862
|
}
|
|
18872
18863
|
try {
|
|
@@ -18882,7 +18873,7 @@ function leavesProject(absProjectDir, absoluteEntryPath, isAllowedEntry) {
|
|
|
18882
18873
|
}
|
|
18883
18874
|
function readProjectEntryFile(projectDir, preferredEntryFile, isAllowedEntry) {
|
|
18884
18875
|
const absProjectDir = resolve11(projectDir);
|
|
18885
|
-
if (!existsSync23(absProjectDir) || !
|
|
18876
|
+
if (!existsSync23(absProjectDir) || !statSync10(absProjectDir).isDirectory()) {
|
|
18886
18877
|
return { error: `Project directory not found: ${absProjectDir}` };
|
|
18887
18878
|
}
|
|
18888
18879
|
const entryCandidates = [preferredEntryFile, "index.html", "src/index.html"].filter(
|
|
@@ -19847,7 +19838,7 @@ function prepareProjectDirectory(projectDir, options, policy) {
|
|
|
19847
19838
|
if (!candidate) return null;
|
|
19848
19839
|
const absProjectDir = policy ? resolve12(policy.projectsDir, candidate) : resolve12(candidate);
|
|
19849
19840
|
const shown = policy ? candidate : absProjectDir;
|
|
19850
|
-
if (policy && !isAllowedProjectPath(policy.projectsDir, absProjectDir) || !existsSync26(absProjectDir) || !
|
|
19841
|
+
if (policy && !isAllowedProjectPath(policy.projectsDir, absProjectDir) || !existsSync26(absProjectDir) || !statSync11(absProjectDir).isDirectory()) {
|
|
19851
19842
|
return { error: `Project directory not found: ${shown}` };
|
|
19852
19843
|
}
|
|
19853
19844
|
const entry = options.entryFile || "index.html";
|
|
@@ -19989,7 +19980,7 @@ function publicPerfSummary(job) {
|
|
|
19989
19980
|
return job.perfSummary ? { ...job.perfSummary, renderId: void 0 } : null;
|
|
19990
19981
|
}
|
|
19991
19982
|
function outputFileSize(path) {
|
|
19992
|
-
return existsSync26(path) ?
|
|
19983
|
+
return existsSync26(path) ? statSync11(path).size : 0;
|
|
19993
19984
|
}
|
|
19994
19985
|
function createBlockingProgressReporter(log, requestId) {
|
|
19995
19986
|
let lastLoggedPct = -10;
|