@poe-platform/safe-js 0.1.398 → 0.1.400
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/safe-js/chunks/{chunk-EWFR3DZJ.js → chunk-ETP3MEHS.js} +2 -2
- package/dist/safe-js/chunks/{chunk-G2HUKBY7.js → chunk-L5I53V56.js} +10 -8
- package/dist/safe-js/chunks/{chunk-G2HUKBY7.js.map → chunk-L5I53V56.js.map} +2 -2
- package/dist/safe-js/cli.js +2 -2
- package/dist/safe-js/core.js +1 -1
- package/dist/safe-js/index.js +2 -2
- package/package.json +2 -2
- /package/dist/safe-js/chunks/{chunk-EWFR3DZJ.js.map → chunk-ETP3MEHS.js.map} +0 -0
|
@@ -27,7 +27,7 @@ import {
|
|
|
27
27
|
validateMigrationSemantics,
|
|
28
28
|
validateSnapshotData,
|
|
29
29
|
validateSnapshotMigration
|
|
30
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-L5I53V56.js";
|
|
31
31
|
|
|
32
32
|
// packages/safe-js/src/migrate.ts
|
|
33
33
|
import { createHash } from "node:crypto";
|
|
@@ -8249,4 +8249,4 @@ export {
|
|
|
8249
8249
|
parseMcpConfig,
|
|
8250
8250
|
makeMcpModule
|
|
8251
8251
|
};
|
|
8252
|
-
//# sourceMappingURL=chunk-
|
|
8252
|
+
//# sourceMappingURL=chunk-ETP3MEHS.js.map
|
|
@@ -23165,7 +23165,7 @@ function indexHeapContainers(snapshot) {
|
|
|
23165
23165
|
if (key === "version" || key === "sourceHash" || key === "heap") {
|
|
23166
23166
|
continue;
|
|
23167
23167
|
}
|
|
23168
|
-
collectContainerStats(value, stats, ancestors, guestValues);
|
|
23168
|
+
collectContainerStats(value, stats, ancestors, guestValues, inMemoryRunSnapshots.has(snapshot));
|
|
23169
23169
|
}
|
|
23170
23170
|
const heapIds = /* @__PURE__ */ new Map();
|
|
23171
23171
|
let nextId = 1;
|
|
@@ -23177,7 +23177,7 @@ function indexHeapContainers(snapshot) {
|
|
|
23177
23177
|
}
|
|
23178
23178
|
return { heapIds, guestValues };
|
|
23179
23179
|
}
|
|
23180
|
-
function collectContainerStats(value, stats, ancestors, guestValues, depth = 0) {
|
|
23180
|
+
function collectContainerStats(value, stats, ancestors, guestValues, trustedRunReplay, depth = 0) {
|
|
23181
23181
|
if (value === null || typeof value !== "object") {
|
|
23182
23182
|
return;
|
|
23183
23183
|
}
|
|
@@ -23202,6 +23202,8 @@ function collectContainerStats(value, stats, ancestors, guestValues, depth = 0)
|
|
|
23202
23202
|
stat2.expanded = true;
|
|
23203
23203
|
ancestors.add(value);
|
|
23204
23204
|
const guestEntries = [];
|
|
23205
|
+
const replayPromise = isSandboxPromise(value) ? value : isPromiseResolvingFunction(value) ? promiseResolvingFunctions.get(value)?.promise : void 0;
|
|
23206
|
+
const replayMetadata = trustedRunReplay && replayPromise !== void 0 && promiseStates.get(replayPromise)?.status === "pending" && unrepresentedPromiseContinuations.has(replayPromise);
|
|
23205
23207
|
if (isSandboxDataView(value)) guestEntries.push(dataViewBuffer(value));
|
|
23206
23208
|
if (isNumericTypedArray(value)) guestEntries.push(typedArrayStorage(value).buffer);
|
|
23207
23209
|
const guest = isSandboxDataView(value) ? { kind: "dataview", state: captureDataViewState(value, (entry) => {
|
|
@@ -23213,20 +23215,20 @@ function collectContainerStats(value, stats, ancestors, guestValues, depth = 0)
|
|
|
23213
23215
|
}) } : isSandboxArrayBuffer(value) ? { kind: "arraybuffer", state: captureArrayBufferState(value, (entry) => {
|
|
23214
23216
|
guestEntries.push(entry);
|
|
23215
23217
|
return null;
|
|
23216
|
-
}) } : captureGuestHeapNode(value, (entry) => {
|
|
23218
|
+
}) } : replayMetadata ? void 0 : captureGuestHeapNode(value, (entry) => {
|
|
23217
23219
|
guestEntries.push(entry);
|
|
23218
23220
|
return null;
|
|
23219
23221
|
});
|
|
23220
23222
|
if (guest !== void 0) {
|
|
23221
23223
|
if (!isSandboxArrayBuffer(value) && !isSandboxDataView(value) && !isNumericTypedArray(value)) guestValues.add(value);
|
|
23222
23224
|
for (const entry of guestEntries) {
|
|
23223
|
-
collectContainerStats(entry, stats, ancestors, guestValues, depth + 1);
|
|
23225
|
+
collectContainerStats(entry, stats, ancestors, guestValues, trustedRunReplay, depth + 1);
|
|
23224
23226
|
if (entry !== null && typeof entry === "object") stats.get(entry).forceHeap = true;
|
|
23225
23227
|
}
|
|
23226
23228
|
ancestors.delete(value);
|
|
23227
23229
|
return;
|
|
23228
23230
|
}
|
|
23229
|
-
for (const entry of guestEntries) collectContainerStats(entry, stats, ancestors, guestValues, depth + 1);
|
|
23231
|
+
for (const entry of guestEntries) collectContainerStats(entry, stats, ancestors, guestValues, trustedRunReplay, depth + 1);
|
|
23230
23232
|
if (!Array.isArray(value) && !isPlainObject(value) && !isNumericTypedArray(value) && !isSandboxDate(value)) {
|
|
23231
23233
|
ancestors.delete(value);
|
|
23232
23234
|
return;
|
|
@@ -23236,12 +23238,12 @@ function collectContainerStats(value, stats, ancestors, guestValues, depth = 0)
|
|
|
23236
23238
|
return "value" in descriptor ? [descriptor.value] : [];
|
|
23237
23239
|
}) : isSandboxDate(value) ? dateDataProperties(value).flatMap(([key, descriptor]) => typeof key === "string" ? [descriptor.value] : []) : isSandboxBox(value) ? boxedDataProperties(value).map(([, descriptor]) => descriptor.value) : isSandboxArguments(value) ? getSandboxArgumentEntries(value).map(([, entry]) => entry) : getEnumerableDataValues(value);
|
|
23238
23240
|
for (const entry of entries) {
|
|
23239
|
-
collectContainerStats(entry, stats, ancestors, guestValues, depth + 1);
|
|
23241
|
+
collectContainerStats(entry, stats, ancestors, guestValues, trustedRunReplay, depth + 1);
|
|
23240
23242
|
}
|
|
23241
23243
|
for (const key of ownSerializableSymbolKeys(value)) {
|
|
23242
23244
|
const descriptor = Object.getOwnPropertyDescriptor(value, key);
|
|
23243
23245
|
if ("value" in descriptor)
|
|
23244
|
-
collectContainerStats(descriptor.value, stats, ancestors, guestValues, depth + 1);
|
|
23246
|
+
collectContainerStats(descriptor.value, stats, ancestors, guestValues, trustedRunReplay, depth + 1);
|
|
23245
23247
|
}
|
|
23246
23248
|
ancestors.delete(value);
|
|
23247
23249
|
}
|
|
@@ -45215,4 +45217,4 @@ export {
|
|
|
45215
45217
|
FileSnapshotBackend,
|
|
45216
45218
|
run
|
|
45217
45219
|
};
|
|
45218
|
-
//# sourceMappingURL=chunk-
|
|
45220
|
+
//# sourceMappingURL=chunk-L5I53V56.js.map
|