peachsim 0.1.2219 → 0.1.2220

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.
Files changed (85) hide show
  1. package/cli/commands/flow.ts +4 -0
  2. package/cli/maestro-compare.ts +37 -26
  3. package/dist-lib/agent-daemon-client.cjs +1 -1
  4. package/dist-lib/agent-events.cjs +1 -1
  5. package/dist-lib/attached-projects.cjs +1 -1
  6. package/dist-lib/auth/shared-session.cjs +1 -1
  7. package/dist-lib/backend-origin.cjs +1 -1
  8. package/dist-lib/beta.cjs +1 -1
  9. package/dist-lib/beta.mjs +1 -1
  10. package/dist-lib/bridge-constants.cjs +1 -1
  11. package/dist-lib/bridge-contract-input.cjs +1 -1
  12. package/dist-lib/bridge-contract-input.mjs +1 -1
  13. package/dist-lib/bridge-contract.cjs +1 -1
  14. package/dist-lib/bridge-contract.mjs +1 -1
  15. package/dist-lib/bundle-channel.cjs +79 -16
  16. package/dist-lib/capture-contract.cjs +1 -1
  17. package/dist-lib/capture-contract.mjs +1 -1
  18. package/dist-lib/cloud-contract.cjs +1 -1
  19. package/dist-lib/cloud-contract.mjs +1 -1
  20. package/dist-lib/cloud-test-args.cjs +1 -1
  21. package/dist-lib/cloud-test-args.mjs +1 -1
  22. package/dist-lib/cloud.cjs +1 -1
  23. package/dist-lib/cloud.mjs +1 -1
  24. package/dist-lib/config.cjs +1 -1
  25. package/dist-lib/config.mjs +1 -1
  26. package/dist-lib/detox/index.cjs +1 -1
  27. package/dist-lib/dev-bundle-resolution.cjs +1 -1
  28. package/dist-lib/expo-swift-bundle.cjs +76 -13
  29. package/dist-lib/expo-swift-metadata.cjs +1 -1
  30. package/dist-lib/expo-swift-metadata.mjs +1 -1
  31. package/dist-lib/home-paths.cjs +1 -1
  32. package/dist-lib/host/bridge-host.cjs +77 -14
  33. package/dist-lib/host/fetch-proxy-handler.cjs +2 -2
  34. package/dist-lib/host/fetch-proxy-overrides.cjs +1 -1
  35. package/dist-lib/host/fetch-proxy-overrides.mjs +1 -1
  36. package/dist-lib/host/replacement-module-handler.cjs +1 -1
  37. package/dist-lib/host/websocket-proxy.cjs +1 -1
  38. package/dist-lib/index.cjs +2 -2
  39. package/dist-lib/jump-to-source-babel.cjs +1 -1
  40. package/dist-lib/jump-to-source-native.cjs +1 -1
  41. package/dist-lib/kotlin-host.cjs +1 -1
  42. package/dist-lib/menu.cjs +1 -1
  43. package/dist-lib/menu.mjs +1 -1
  44. package/dist-lib/metro-fingerprint-registry.cjs +1 -1
  45. package/dist-lib/metro-fingerprint-registry.mjs +1 -1
  46. package/dist-lib/metro-production-bundle.cjs +1 -1
  47. package/dist-lib/metro-production-bundle.mjs +1 -1
  48. package/dist-lib/metro.cjs +2 -2
  49. package/dist-lib/native-app-identity-project.cjs +1 -1
  50. package/dist-lib/native-app-identity-project.mjs +1 -1
  51. package/dist-lib/native-app-identity.cjs +1 -1
  52. package/dist-lib/native-app-identity.mjs +1 -1
  53. package/dist-lib/native-firebase-metadata.cjs +1 -1
  54. package/dist-lib/native-firebase-metadata.mjs +1 -1
  55. package/dist-lib/pdfium-raster.cjs +1 -1
  56. package/dist-lib/pdfium-raster.mjs +1 -1
  57. package/dist-lib/plist.cjs +1 -1
  58. package/dist-lib/plist.mjs +1 -1
  59. package/dist-lib/profiles.cjs +1 -1
  60. package/dist-lib/public-brand.cjs +1 -1
  61. package/dist-lib/public-origins-lib-esm.json +24 -24
  62. package/dist-lib/public-origins-lib.json +53 -53
  63. package/dist-lib/react-native-host-modules.cjs +1 -1
  64. package/dist-lib/react-native-host-modules.mjs +1 -1
  65. package/dist-lib/reap-browser.cjs +1 -1
  66. package/dist-lib/scripts/dev-server-scanner.cjs +1 -1
  67. package/dist-lib/sdk.cjs +1 -1
  68. package/dist-lib/sdk.mjs +1 -1
  69. package/dist-lib/skills.cjs +77 -14
  70. package/dist-lib/swift-compile.cjs +1 -1
  71. package/dist-lib/swift-compile.mjs +1 -1
  72. package/dist-lib/swift-package.cjs +1 -1
  73. package/dist-lib/swift-package.mjs +1 -1
  74. package/dist-lib/swift-submit.cjs +1 -1
  75. package/dist-lib/swift-submit.mjs +1 -1
  76. package/dist-lib/swift-toolchain.cjs +1 -1
  77. package/dist-lib/swift.cjs +1 -1
  78. package/dist-lib/vite-swift.cjs +74 -11
  79. package/dist-lib/vite.cjs +2 -2
  80. package/dist-lib/worklet-executable.cjs +1 -1
  81. package/dist-lib/worklet-executable.mjs +1 -1
  82. package/package.json +1 -1
  83. package/src/swift-host.ts +84 -2
  84. package/src/swift-packages.ts +19 -10
  85. package/src/swift-standins.ts +1 -1
@@ -165,18 +165,23 @@ const UNSUPPORTED_NATIVE = /\.(s|S)$/
165
165
  // return address, cannot lower to wasm, unless upstream declares
166
166
  // wasi-conditioned c settings for it: that is the package's own supported
167
167
  // portable path (boringssl's guarded assembly with OPENSSL_NO_ASM), which
168
- // compiles with those flags exactly as swiftpm builds it. without that signal
169
- // the target keeps the refusal below. when a refused target also ships public
170
- // headers, those headers stand in for it and every declaration they spell
171
- // traps by name. this is the assembly rule above, widened only where the
172
- // target has a header surface to stand in from.
168
+ // compiles with those flags exactly as swiftpm builds it. assembly that
169
+ // preprocesses to nothing for wasm32 (guarded to the architectures it was
170
+ // written for) is the same portable path without the signal: swiftpm compiles
171
+ // it as plain c. otherwise the target keeps the refusal below. when a refused
172
+ // target also ships public headers, those headers stand in for it and every
173
+ // declaration they spell traps by name. this is the assembly rule above,
174
+ // widened only where the target has a header surface to stand in from.
173
175
  function unlowerableSources(
174
176
  files: readonly string[],
175
177
  target: SwiftManifestTarget,
178
+ portable: ReadonlySet<string>,
176
179
  ): string[] {
177
180
  if (target.declaresWasiNativeSettings) return []
178
181
  return [
179
- ...files.filter((file) => UNSUPPORTED_NATIVE.test(file)),
182
+ ...(portable.has(target.name)
183
+ ? []
184
+ : files.filter((file) => UNSUPPORTED_NATIVE.test(file))),
180
185
  ...files
181
186
  .filter(isSwiftNativeTranslationUnit)
182
187
  .filter((file) => swiftCTakesReturnAddress(fs.readFileSync(file, 'utf8'))),
@@ -186,10 +191,11 @@ function unlowerableSources(
186
191
  function unloweredSources(
187
192
  files: readonly string[],
188
193
  target: SwiftManifestTarget,
194
+ portable: ReadonlySet<string>,
189
195
  ): string[] | null {
190
196
  if (target.type !== 'regular') return null
191
197
  if (!files.some(isSwiftNativeTranslationUnit)) return null
192
- const unlowered = unlowerableSources(files, target)
198
+ const unlowered = unlowerableSources(files, target, portable)
193
199
  if (unlowered.length === 0) return null
194
200
  const headers = path.resolve(target.dir, target.publicHeadersPath)
195
201
  if (
@@ -533,6 +539,8 @@ export function resolveSwiftPackages(options: {
533
539
  standinTargets?: ReadonlySet<string>
534
540
  /** why a binary target has no stand-in, added to its reason. */
535
541
  binaryGaps?: ReadonlyMap<string, string>
542
+ /** assembly targets whose sources preprocess to nothing for wasm32. */
543
+ portableAssembly?: ReadonlySet<string>
536
544
  /**
537
545
  * each compiling module and the package products it links. a clang target
538
546
  * in that product's closure records the module as a client.
@@ -542,6 +550,7 @@ export function resolveSwiftPackages(options: {
542
550
  }): SwiftPackages {
543
551
  const { rootDir, resolved, products, localDirs } = options
544
552
  const providedTargets = new Set(options.provided ?? [])
553
+ const portableAssembly = options.portableAssembly ?? new Set<string>()
545
554
  const providedProducts = new Set(options.provided ?? [])
546
555
  const result: SwiftPackages = {
547
556
  sourceLinks: { targets: [], owners: [] },
@@ -674,7 +683,7 @@ export function resolveSwiftPackages(options: {
674
683
  ? swiftTargetFiles(pkg.manifest, target)
675
684
  : []
676
685
  const gap = options.binaryGaps?.get(name)
677
- const unlowerable = unlowerableSources(files, target)
686
+ const unlowerable = unlowerableSources(files, target, portableAssembly)
678
687
  const placeholder = placeholderPackage(pkg)
679
688
  const ownReason =
680
689
  target.type === 'binary'
@@ -794,7 +803,7 @@ export function resolveSwiftPackages(options: {
794
803
  )
795
804
  return false
796
805
  // a target whose headers stand in for its unlowered sources stays with the stand-in
797
- if (unloweredSources(files, target)) return false
806
+ if (unloweredSources(files, target, portableAssembly)) return false
798
807
  claimed.add(key)
799
808
  providedTargets.delete(name)
800
809
  for (const dependency of target.dependencies) {
@@ -865,7 +874,7 @@ export function resolveSwiftPackages(options: {
865
874
  : []
866
875
  const objc =
867
876
  target.type === 'regular' && files.some((file) => /\.(m|mm)$/.test(file))
868
- const unlowered = unloweredSources(files, target)
877
+ const unlowered = unloweredSources(files, target, portableAssembly)
869
878
  const gap = placeholderPackage(pkg)
870
879
  const sources = files.filter((file) => file.endsWith('.swift'))
871
880
  // swiftpm's release settings, as xcode builds a package for any
@@ -1747,7 +1747,7 @@ function graphStandin(
1747
1747
  before
1748
1748
  )
1749
1749
  throw new Error(
1750
- `its generated source does not typecheck: ${elsewhere.slice(0, 3).join('; ') || check.stderr.trim().slice(0, 400)}`,
1750
+ `its generated source does not typecheck: ${(elsewhere.length > 0 ? elsewhere : [...check.stderr.matchAll(/^\S+?:\d+:\d+: error: .*$/gm)].map((line) => line[0].replace(/^[^:]*\//, ''))).slice(0, 3).join('; ') || check.stderr.trim().slice(0, 400)}`,
1751
1751
  )
1752
1752
  }
1753
1753
  }