peachsim 0.1.2248 → 0.1.2250
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/cli/bridge-flow-runner.ts +30 -3
- package/cli/commands/flow.ts +4 -1
- package/cli/commands/inspect/settling.ts +35 -4
- package/cli/drivers/playwright.ts +2 -0
- package/dist-lib/agent-daemon-client.cjs +1 -1
- package/dist-lib/agent-events.cjs +1 -1
- package/dist-lib/attached-projects.cjs +1 -1
- package/dist-lib/auth/shared-session.cjs +1 -1
- package/dist-lib/backend-origin.cjs +1 -1
- package/dist-lib/beta.cjs +1 -1
- package/dist-lib/beta.mjs +1 -1
- package/dist-lib/bridge-constants.cjs +1 -1
- package/dist-lib/bridge-contract-input.cjs +1 -1
- package/dist-lib/bridge-contract-input.mjs +1 -1
- package/dist-lib/bridge-contract.cjs +1 -1
- package/dist-lib/bridge-contract.mjs +1 -1
- package/dist-lib/bundle-channel.cjs +203 -53
- package/dist-lib/capture-contract.cjs +1 -1
- package/dist-lib/capture-contract.mjs +1 -1
- package/dist-lib/cloud-contract.cjs +1 -1
- package/dist-lib/cloud-contract.mjs +1 -1
- package/dist-lib/cloud-test-args.cjs +1 -1
- package/dist-lib/cloud-test-args.mjs +1 -1
- package/dist-lib/cloud.cjs +1 -1
- package/dist-lib/cloud.mjs +1 -1
- package/dist-lib/config.cjs +1 -1
- package/dist-lib/config.mjs +1 -1
- package/dist-lib/detox/index.cjs +33 -9
- package/dist-lib/dev-bundle-resolution.cjs +1 -1
- package/dist-lib/expo-swift-bundle.cjs +177 -49
- package/dist-lib/expo-swift-metadata.cjs +1 -1
- package/dist-lib/expo-swift-metadata.mjs +1 -1
- package/dist-lib/home-paths.cjs +1 -1
- package/dist-lib/host/bridge-host.cjs +210 -54
- package/dist-lib/host/fetch-proxy-handler.cjs +4 -4
- package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
- package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
- package/dist-lib/host/replacement-module-handler.cjs +1 -1
- package/dist-lib/host/websocket-proxy.cjs +1 -1
- package/dist-lib/index.cjs +45 -14
- package/dist-lib/jump-to-source-babel.cjs +1 -1
- package/dist-lib/jump-to-source-native.cjs +1 -1
- package/dist-lib/kotlin-host.cjs +1 -1
- package/dist-lib/menu.cjs +1 -1
- package/dist-lib/menu.mjs +1 -1
- package/dist-lib/metro-fingerprint-registry.cjs +1 -1
- package/dist-lib/metro-fingerprint-registry.mjs +1 -1
- package/dist-lib/metro-production-bundle.cjs +1 -1
- package/dist-lib/metro-production-bundle.mjs +1 -1
- package/dist-lib/metro.cjs +15 -8
- package/dist-lib/native-app-identity-project.cjs +2 -2
- package/dist-lib/native-app-identity-project.mjs +2 -2
- package/dist-lib/native-app-identity.cjs +1 -1
- package/dist-lib/native-app-identity.mjs +1 -1
- package/dist-lib/native-firebase-metadata.cjs +1 -1
- package/dist-lib/native-firebase-metadata.mjs +1 -1
- package/dist-lib/pdfium-raster.cjs +1 -1
- package/dist-lib/pdfium-raster.mjs +1 -1
- package/dist-lib/plist.cjs +1 -1
- package/dist-lib/plist.mjs +1 -1
- package/dist-lib/profiles.cjs +1 -1
- package/dist-lib/public-brand.cjs +1 -1
- package/dist-lib/public-origins-lib-esm.json +24 -24
- package/dist-lib/public-origins-lib.json +53 -53
- package/dist-lib/react-native-host-modules.cjs +1 -1
- package/dist-lib/react-native-host-modules.mjs +1 -1
- package/dist-lib/reap-browser.cjs +2 -2
- package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
- package/dist-lib/sdk.cjs +31 -7
- package/dist-lib/sdk.mjs +31 -7
- package/dist-lib/skills.cjs +289 -64
- package/dist-lib/swift-compile.cjs +165 -38
- package/dist-lib/swift-compile.mjs +165 -38
- package/dist-lib/swift-package.cjs +1 -1
- package/dist-lib/swift-package.mjs +1 -1
- package/dist-lib/swift-submit.cjs +1 -1
- package/dist-lib/swift-submit.mjs +1 -1
- package/dist-lib/swift-toolchain.cjs +1 -1
- package/dist-lib/swift.cjs +1 -1
- package/dist-lib/vite-swift.cjs +174 -46
- package/dist-lib/vite.cjs +15 -8
- package/dist-lib/worklet-executable.cjs +1 -1
- package/dist-lib/worklet-executable.mjs +1 -1
- package/dist-types/packages/peach-engine/src/render-worker/compositor-protocol.d.ts +4 -0
- package/dist-types/packages/peach-engine/src/render-worker/image-pixel-contract.d.ts +0 -4
- package/dist-types/packages/peach-engine/src/render-worker/native-ui-protocol.d.ts +1 -0
- package/dist-types/packages/peach-engine/src/render-worker/shell-tree-wire.d.ts +8 -0
- package/dist-types/packages/peach-engine/src/render-worker/webview-capture-protocol.d.ts +1 -0
- package/dist-types/packages/peach-globals/src/globalsContract.d.ts +5 -0
- package/kotlin/sdk.tar.gz +0 -0
- package/package.json +1 -1
- package/runtime-companion.json +1 -1
- package/sdk/ios/wasm/include/math.h +1 -1
- package/sdk/ios/wasm/include/pthread.h +1 -1
- package/src/assetCatalogContract.ts +6 -0
- package/src/nitro-compile.ts +23 -1
- package/src/process-group.ts +5 -2
- package/src/runtime-packs.ts +8 -0
- package/src/sfSymbolMetricsContract.ts +73 -37
- package/src/swift-compile.ts +119 -13
- package/src/swift-guest-image-ledger.ts +10 -5
- package/src/swift-guest-link.ts +20 -14
- package/src/swift-guest-source-inputs.ts +5 -1
- package/src/swift-installed-targets.ts +4 -1
- package/src/swift-standins.ts +11 -8
- package/src/swift-wasm-prune.ts +33 -1
package/src/swift-wasm-prune.ts
CHANGED
|
@@ -193,6 +193,8 @@ interface ParsedObject {
|
|
|
193
193
|
typePrefixesInObj: Set<string>
|
|
194
194
|
rootFuncs: number[]
|
|
195
195
|
rootSegs: number[]
|
|
196
|
+
/** absolute file offsets of each data segment's payload. */
|
|
197
|
+
segPayloadRanges: [number, number][]
|
|
196
198
|
}
|
|
197
199
|
|
|
198
200
|
const parsedObjectCache = new Map<string, ParsedObject>()
|
|
@@ -787,6 +789,10 @@ function parseWasmObjectBytes(
|
|
|
787
789
|
typePrefixesInObj,
|
|
788
790
|
rootFuncs,
|
|
789
791
|
rootSegs,
|
|
792
|
+
segPayloadRanges: sEnds.map((end, i) => [
|
|
793
|
+
dataStart + sPayloadStarts[i]!,
|
|
794
|
+
dataStart + end,
|
|
795
|
+
]),
|
|
790
796
|
}
|
|
791
797
|
}
|
|
792
798
|
|
|
@@ -1224,6 +1230,7 @@ export function pruneSwiftWasmLink(
|
|
|
1224
1230
|
const eagerFiles: string[] = []
|
|
1225
1231
|
const lazyBuildObjects = new Map<string, ParsedObject>()
|
|
1226
1232
|
const extraArchiveObjs: ParsedObject[] = []
|
|
1233
|
+
const objectBytes = new Map<ParsedObject, Buffer>()
|
|
1227
1234
|
let inStartLib = false
|
|
1228
1235
|
let swiftrtOrigPath = ''
|
|
1229
1236
|
|
|
@@ -1289,7 +1296,9 @@ export function pruneSwiftWasmLink(
|
|
|
1289
1296
|
) {
|
|
1290
1297
|
const members = readArMembers(new Uint8Array(fs.readFileSync(t)))
|
|
1291
1298
|
for (const m of members) {
|
|
1292
|
-
|
|
1299
|
+
const object = parseWasmObjectBytes(`${t}(${m.name})`, m.bytes, false)
|
|
1300
|
+
extraArchiveObjs.push(object)
|
|
1301
|
+
objectBytes.set(object, Buffer.from(m.bytes))
|
|
1293
1302
|
}
|
|
1294
1303
|
}
|
|
1295
1304
|
}
|
|
@@ -1744,9 +1753,32 @@ export function pruneSwiftWasmLink(
|
|
|
1744
1753
|
'$s10Foundation16NSSortDescriptorC7keyPath9ascendingACs03KeyE0Cyxq_G_SbtcSLR_r0_lufc',
|
|
1745
1754
|
])
|
|
1746
1755
|
|
|
1756
|
+
// the runtime resolves a clang-imported class named in a mangled type name,
|
|
1757
|
+
// such as the argument of Outcome<AVTimedMetadataGroup>, by objc_getClass
|
|
1758
|
+
// alone: no relocation reaches the class, so a live name keeps its provider.
|
|
1759
|
+
const keepObjCClassesNamedInSegment = (obj: ParsedObject, segIdx: number) => {
|
|
1760
|
+
const range = obj.segPayloadRanges[segIdx]
|
|
1761
|
+
if (!range) return
|
|
1762
|
+
let bytes = objectBytes.get(obj)
|
|
1763
|
+
if (!bytes) objectBytes.set(obj, (bytes = fs.readFileSync(obj.file)))
|
|
1764
|
+
const text = bytes.toString('latin1', range[0], range[1])
|
|
1765
|
+
for (const match of text.matchAll(/So(\d+)/g)) {
|
|
1766
|
+
const start = match.index + 2 + match[1]!.length
|
|
1767
|
+
const length = Number(match[1])
|
|
1768
|
+
if (text[start + length] !== 'C') continue
|
|
1769
|
+
const symbol = `._OBJC_CLASS_${text.slice(start, start + length)}`
|
|
1770
|
+
for (const provider of lazyProviders.get(symbol) ?? []) {
|
|
1771
|
+
eagerDynamicObjects.add(provider)
|
|
1772
|
+
extractObject(provider)
|
|
1773
|
+
activateSymbolInObj(provider, provider.symNames.indexOf(symbol))
|
|
1774
|
+
}
|
|
1775
|
+
}
|
|
1776
|
+
}
|
|
1777
|
+
|
|
1747
1778
|
while (workQueue.length > 0) {
|
|
1748
1779
|
const item = workQueue.pop()!
|
|
1749
1780
|
const obj = item.obj
|
|
1781
|
+
if (item.kind === 'seg') keepObjCClassesNamedInSegment(obj, item.idx)
|
|
1750
1782
|
let relocs: number[]
|
|
1751
1783
|
if (item.kind === 'func') {
|
|
1752
1784
|
relocs = obj.funcRelocs[item.idx]!
|