ttsc 0.31.0 → 0.31.2

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 (155) hide show
  1. package/cmd/platform/main.go +2 -2
  2. package/internal/sourceprocess/contain_windows.go +10 -13
  3. package/internal/sourceprocess/started_windows.go +41 -0
  4. package/internal/sourceprocess/windows_started_publication_distinguishes_pending_from_refusal_test.go +76 -0
  5. package/internal/watchhelper/run.go +30 -20
  6. package/internal/watchhelper/run_other.go +4 -4
  7. package/internal/watchhelper/run_windows.go +471 -0
  8. package/internal/watchhelper/watchhelper.go +8 -2
  9. package/internal/watchhelper/windows_notifications_preserve_mutations_without_access_noise_test.go +506 -0
  10. package/lib/compiler/internal/build/BuildExecution.d.ts +4 -2
  11. package/lib/compiler/internal/build/BuildExecution.js +40 -12
  12. package/lib/compiler/internal/build/BuildExecution.js.map +1 -1
  13. package/lib/compiler/internal/startResidentTransform.js +5 -4
  14. package/lib/compiler/internal/startResidentTransform.js.map +1 -1
  15. package/lib/compiler/internal/transformProjectInMemory.js +9 -7
  16. package/lib/compiler/internal/transformProjectInMemory.js.map +1 -1
  17. package/lib/internal/javascriptRuntimeCapabilities.d.ts +13 -4
  18. package/lib/internal/javascriptRuntimeCapabilities.js +56 -6
  19. package/lib/internal/javascriptRuntimeCapabilities.js.map +1 -1
  20. package/lib/internal/nativeBinary.d.ts +3 -3
  21. package/lib/internal/nativeBinary.js +3 -3
  22. package/lib/internal/pluginSource.d.ts +1 -0
  23. package/lib/internal/pluginSource.js +1 -0
  24. package/lib/internal/pluginSource.js.map +1 -1
  25. package/lib/internal/resolveNodeBinary.d.ts +6 -1
  26. package/lib/internal/resolveNodeBinary.js +6 -2
  27. package/lib/internal/resolveNodeBinary.js.map +1 -1
  28. package/lib/internal/runtimeExecutableIdentity.d.ts +22 -13
  29. package/lib/internal/runtimeExecutableIdentity.js +192 -102
  30. package/lib/internal/runtimeExecutableIdentity.js.map +1 -1
  31. package/lib/launcher/internal/runtime/installRuntimeHooks.js +58 -4
  32. package/lib/launcher/internal/runtime/installRuntimeHooks.js.map +1 -1
  33. package/lib/launcher/internal/ttscserver/captureLSPPluginSelectionInputs.d.ts +5 -1
  34. package/lib/launcher/internal/ttscserver/captureLSPPluginSelectionInputs.js +7 -2
  35. package/lib/launcher/internal/ttscserver/captureLSPPluginSelectionInputs.js.map +1 -1
  36. package/lib/launcher/internal/ttscserver/runTtscserver.js +8 -1
  37. package/lib/launcher/internal/ttscserver/runTtscserver.js.map +1 -1
  38. package/lib/plugin/internal/CapabilityResolutionFormat.d.ts +21 -62
  39. package/lib/plugin/internal/CapabilityResolutionFormat.js +15 -106
  40. package/lib/plugin/internal/CapabilityResolutionFormat.js.map +1 -1
  41. package/lib/plugin/internal/load/PluginDescriptorEvaluationCache.d.ts +6 -0
  42. package/lib/plugin/internal/load/PluginDescriptorEvaluationCache.js +4 -4
  43. package/lib/plugin/internal/load/PluginDescriptorEvaluationCache.js.map +1 -1
  44. package/lib/plugin/internal/load/loadProjectPlugins.d.ts +24 -14
  45. package/lib/plugin/internal/load/loadProjectPlugins.js +141 -56
  46. package/lib/plugin/internal/load/loadProjectPlugins.js.map +1 -1
  47. package/lib/plugin/internal/readCapabilityResolution.d.ts +6 -0
  48. package/lib/plugin/internal/readCapabilityResolution.js +8 -5
  49. package/lib/plugin/internal/readCapabilityResolution.js.map +1 -1
  50. package/lib/plugin/internal/source/GoEnvironmentReading.d.ts +48 -0
  51. package/lib/plugin/internal/source/GoEnvironmentReading.js +156 -0
  52. package/lib/plugin/internal/source/GoEnvironmentReading.js.map +1 -0
  53. package/lib/plugin/internal/source/NativeSourcePackages.d.ts +51 -13
  54. package/lib/plugin/internal/source/NativeSourcePackages.js +182 -27
  55. package/lib/plugin/internal/source/NativeSourcePackages.js.map +1 -1
  56. package/lib/plugin/internal/source/PluginBuildEnvironmentReadings.d.ts +42 -3
  57. package/lib/plugin/internal/source/PluginBuildEnvironmentReadings.js +68 -7
  58. package/lib/plugin/internal/source/PluginBuildEnvironmentReadings.js.map +1 -1
  59. package/lib/plugin/internal/source/PluginBuildEnvironmentWitness.d.ts +5 -3
  60. package/lib/plugin/internal/source/PluginBuildEnvironmentWitness.js +14 -8
  61. package/lib/plugin/internal/source/PluginBuildEnvironmentWitness.js.map +1 -1
  62. package/lib/plugin/internal/source/PluginContentIdentities.d.ts +265 -0
  63. package/lib/plugin/internal/source/PluginContentIdentities.js +452 -0
  64. package/lib/plugin/internal/source/PluginContentIdentities.js.map +1 -0
  65. package/lib/plugin/internal/source/PluginLoadAnswers.d.ts +63 -0
  66. package/lib/plugin/internal/source/PluginLoadAnswers.js +128 -0
  67. package/lib/plugin/internal/source/PluginLoadAnswers.js.map +1 -0
  68. package/lib/plugin/internal/source/SourceBuildCacheLayout.d.ts +10 -0
  69. package/lib/plugin/internal/source/SourceBuildCacheLayout.js +12 -0
  70. package/lib/plugin/internal/source/SourceBuildCacheLayout.js.map +1 -1
  71. package/lib/plugin/internal/source/SourcePluginWorkspace.d.ts +53 -19
  72. package/lib/plugin/internal/source/SourcePluginWorkspace.js +111 -22
  73. package/lib/plugin/internal/source/SourcePluginWorkspace.js.map +1 -1
  74. package/lib/plugin/internal/source/buildSourcePlugin.d.ts +34 -18
  75. package/lib/plugin/internal/source/buildSourcePlugin.js +52 -24
  76. package/lib/plugin/internal/source/buildSourcePlugin.js.map +1 -1
  77. package/lib/plugin/internal/source/computeCacheKey.d.ts +25 -7
  78. package/lib/plugin/internal/source/computeCacheKey.js +85 -34
  79. package/lib/plugin/internal/source/computeCacheKey.js.map +1 -1
  80. package/lib/plugin/internal/source/hashPluginBuildEnvironment.d.ts +7 -3
  81. package/lib/plugin/internal/source/hashPluginBuildEnvironment.js +75 -102
  82. package/lib/plugin/internal/source/hashPluginBuildEnvironment.js.map +1 -1
  83. package/lib/plugin/internal/source/pluginBuildEnvironment.d.ts +8 -3
  84. package/lib/plugin/internal/source/pluginBuildEnvironment.js +8 -4
  85. package/lib/plugin/internal/source/pluginBuildEnvironment.js.map +1 -1
  86. package/lib/plugin/internal/source/pluginBuildEnvironmentWorker.js +12 -2
  87. package/lib/plugin/internal/source/pluginBuildEnvironmentWorker.js.map +1 -1
  88. package/lib/plugin/internal/source/pluginBuildVersions.d.ts +2 -2
  89. package/lib/plugin/internal/source/pluginBuildVersions.js +4 -17
  90. package/lib/plugin/internal/source/pluginBuildVersions.js.map +1 -1
  91. package/lib/plugin/internal/source/pluginModuleReplaceDirectories.d.ts +6 -5
  92. package/lib/plugin/internal/source/pluginModuleReplaceDirectories.js +10 -17
  93. package/lib/plugin/internal/source/pluginModuleReplaceDirectories.js.map +1 -1
  94. package/lib/plugin/internal/source/pluginSourceState.d.ts +6 -2
  95. package/lib/plugin/internal/source/pluginSourceState.js +20 -8
  96. package/lib/plugin/internal/source/pluginSourceState.js.map +1 -1
  97. package/lib/plugin/internal/source/pluginSourceStateHolds.d.ts +7 -2
  98. package/lib/plugin/internal/source/pluginSourceStateHolds.js +12 -7
  99. package/lib/plugin/internal/source/pluginSourceStateHolds.js.map +1 -1
  100. package/lib/plugin/internal/source/processPluginBuildEnvironment.d.ts +7 -2
  101. package/lib/plugin/internal/source/processPluginBuildEnvironment.js +8 -3
  102. package/lib/plugin/internal/source/processPluginBuildEnvironment.js.map +1 -1
  103. package/lib/plugin/internal/source/provenPluginSourceDigest.d.ts +28 -0
  104. package/lib/plugin/internal/source/provenPluginSourceDigest.js +41 -0
  105. package/lib/plugin/internal/source/provenPluginSourceDigest.js.map +1 -0
  106. package/lib/plugin/internal/source/pruneCacheFileRoot.d.ts +3 -2
  107. package/lib/plugin/internal/source/pruneCacheFileRoot.js +3 -2
  108. package/lib/plugin/internal/source/pruneCacheFileRoot.js.map +1 -1
  109. package/lib/plugin/internal/source/ttscPackageVersion.d.ts +26 -0
  110. package/lib/plugin/internal/source/ttscPackageVersion.js +47 -0
  111. package/lib/plugin/internal/source/ttscPackageVersion.js.map +1 -0
  112. package/lib/plugin/internal/writeCapabilityResolution.d.ts +6 -0
  113. package/lib/plugin/internal/writeCapabilityResolution.js +11 -7
  114. package/lib/plugin/internal/writeCapabilityResolution.js.map +1 -1
  115. package/lib/plugin/resolveCapabilityPlugins.js +67 -15
  116. package/lib/plugin/resolveCapabilityPlugins.js.map +1 -1
  117. package/package.json +8 -8
  118. package/src/compiler/internal/build/BuildExecution.ts +46 -13
  119. package/src/compiler/internal/startResidentTransform.ts +12 -3
  120. package/src/compiler/internal/transformProjectInMemory.ts +10 -2
  121. package/src/internal/javascriptRuntimeCapabilities.ts +71 -5
  122. package/src/internal/nativeBinary.ts +3 -3
  123. package/src/internal/pluginSource.ts +1 -0
  124. package/src/internal/resolveNodeBinary.ts +12 -1
  125. package/src/internal/runtimeExecutableIdentity.ts +227 -141
  126. package/src/launcher/internal/runtime/installRuntimeHooks.ts +68 -3
  127. package/src/launcher/internal/ttscserver/captureLSPPluginSelectionInputs.ts +11 -2
  128. package/src/launcher/internal/ttscserver/runTtscserver.ts +18 -1
  129. package/src/plugin/internal/CapabilityResolutionFormat.ts +23 -107
  130. package/src/plugin/internal/load/PluginDescriptorEvaluationCache.ts +14 -4
  131. package/src/plugin/internal/load/loadProjectPlugins.ts +421 -211
  132. package/src/plugin/internal/readCapabilityResolution.ts +17 -6
  133. package/src/plugin/internal/source/GoEnvironmentReading.ts +178 -0
  134. package/src/plugin/internal/source/NativeSourcePackages.ts +365 -48
  135. package/src/plugin/internal/source/PluginBuildEnvironmentReadings.ts +83 -5
  136. package/src/plugin/internal/source/PluginBuildEnvironmentWitness.ts +18 -8
  137. package/src/plugin/internal/source/PluginContentIdentities.ts +563 -0
  138. package/src/plugin/internal/source/PluginLoadAnswers.ts +151 -0
  139. package/src/plugin/internal/source/SourceBuildCacheLayout.ts +14 -0
  140. package/src/plugin/internal/source/SourcePluginWorkspace.ts +148 -25
  141. package/src/plugin/internal/source/buildSourcePlugin.ts +104 -36
  142. package/src/plugin/internal/source/computeCacheKey.ts +129 -55
  143. package/src/plugin/internal/source/hashPluginBuildEnvironment.ts +152 -105
  144. package/src/plugin/internal/source/pluginBuildEnvironment.ts +9 -2
  145. package/src/plugin/internal/source/pluginBuildEnvironmentWorker.ts +18 -2
  146. package/src/plugin/internal/source/pluginBuildVersions.ts +5 -26
  147. package/src/plugin/internal/source/pluginModuleReplaceDirectories.ts +13 -25
  148. package/src/plugin/internal/source/pluginSourceState.ts +28 -12
  149. package/src/plugin/internal/source/pluginSourceStateHolds.ts +15 -8
  150. package/src/plugin/internal/source/processPluginBuildEnvironment.ts +8 -2
  151. package/src/plugin/internal/source/provenPluginSourceDigest.ts +45 -0
  152. package/src/plugin/internal/source/pruneCacheFileRoot.ts +3 -2
  153. package/src/plugin/internal/source/ttscPackageVersion.ts +45 -0
  154. package/src/plugin/internal/writeCapabilityResolution.ts +29 -8
  155. package/src/plugin/resolveCapabilityPlugins.ts +87 -13
@@ -1,20 +1,29 @@
1
+ import { PluginContentIdentities } from "../plugin/internal/source/PluginContentIdentities";
1
2
  /**
2
3
  * Fingerprint an absolute executable's spelling, target and actual bytes.
3
4
  *
4
5
  * A changed link, file, or read failure yields no reusable identity. Metadata
5
- * brackets the streamed read; it is not used to reuse an earlier content hash.
6
- * Concurrent writes that evade every filesystem observation remain outside this
7
- * snapshot guarantee.
6
+ * brackets the streamed read. Concurrent writes that evade every filesystem
7
+ * observation remain outside this snapshot guarantee.
8
8
  *
9
- * @evidence contracts/common.md#principled-implementation The identity joins lexical-link metadata, the selected physical file metadata and SHA-256 of that opened file; matching metadata alone cannot authorize reuse after bytes change. Descriptor and pathname observations must still agree after reading.
10
- * @evidence contracts/common.md#clear-and-simple-design This one native owner supplies the same content proof to runtime capability and plugin caches; callers decide whether their other inputs permit reuse.
11
- * @evidence contracts/common.md#prohibited-implementation-shortcuts Supported Node filesystem and crypto APIs inspect the actual candidate; no fixture identity, foreign mutation or metadata-only shortcut substitutes for content.
12
- * @evidence contracts/common.md#meaningful-documentation Native prose explains absolute-path scope, failure meaning, hash freshness and the remaining concurrent-mutation limitation, with separate prose and tags.
13
- * @evidence contracts/portability.md#os-neutral-implementation Node native realpath and bigint stat preserve link/target identity on supported hosts; absolute paths use native platform semantics, and unreadable or non-regular targets cannot be reused.
14
- * @evidence contracts/performance.md#efficient-algorithms A sequential read hashes B bytes with one 64 KiB buffer instead of a complete executable allocation. Native path/realpath/stat observations and serialized physical spelling/metadata add text/lookup costs; B and spelling lengths have no quota here. Returned identity storage includes the physical path as well as the fixed-length digest.
15
- *
16
- * @evidenceExclude contracts/performance.md#reuse-equivalent-work This operation establishes whether later work is equivalent; retaining a digest by metadata would reproduce the stale-byte defect it must prevent.
9
+ * With a record store, the bytes of an unchanged executable are proven from its
10
+ * metadata instead of streamed again (`PluginContentIdentities`, #1723): the
11
+ * recorded digest stands only while the physical file's identity, size and both
12
+ * stamps match the record and its modification stamp is separable from a
13
+ * reference the store minted. A plugin load asks for this identity several
14
+ * times, and every launch is a new process, so streaming an 85 MB runtime each
15
+ * time cost about 0.9 s per launch. Without a store, or when that proof is
16
+ * unavailable, the file is streamed as before.
17
17
  *
18
- * @evidence contracts/performance.md#bound-retention-and-release-resources One descriptor and one fixed buffer belong to this synchronous call; finally attempts closure after read/observation failures as well as success. A close failure returns no identity but cannot confirm native release. Returned path/metadata/digest text transfers to the caller and no helper history survives. Opt-in opened/closed/close-failed observations carry one trace-only call id and actual descriptor, PID/thread and already observed physical identity. The existing finally performs the single close; no observer retries it or converts an unavailable identity to success. An observed close is release of this Node descriptor, not proof that an OS image lock or another actor has released the executable.
18
+ * @param runtime The executable, absolute.
19
+ * @param identities Optional record store of the caller's plugin cache.
20
+ * @evidence contracts/common.md#principled-implementation The identity joins lexical-link metadata, the selected physical file metadata and the SHA-256 of that file's bytes, streamed under metadata brackets or proven by a record whose separable signature still matches; descriptor and pathname observations must still agree after a read.
21
+ * @evidence contracts/common.md#clear-and-simple-design This one native owner supplies the same identity to runtime capability and plugin caches; the record store owns metadata reuse and a private helper owns the bracketed stream.
22
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Metadata alone never stands for bytes: reuse needs a record written under unchanged separable metadata around an actual read, which a same-tick rewrite or restored timestamps cannot satisfy because change time and the minted reference move.
23
+ * @evidence contracts/common.md#meaningful-documentation Native prose explains absolute-path scope, failure meaning, the record proof and the remaining concurrent-mutation limitation, with separate prose and tags.
24
+ * @evidence contracts/portability.md#os-neutral-implementation Node native realpath and bigint stat preserve link/target identity on supported hosts; absolute paths use native platform semantics, and unreadable or non-regular targets cannot be reused.
25
+ * @evidence contracts/performance.md#efficient-algorithms A proven record costs three stats and one small file read; otherwise a sequential read hashes B bytes with one 64 KiB buffer instead of a complete executable allocation. Native path/realpath/stat observations and serialized metadata add text/lookup costs.
26
+ * @evidence contracts/performance.md#reuse-equivalent-work Processes share an executable digest only through the record store's separable-signature proof; without a store every call streams the file.
27
+ * @evidence contracts/performance.md#bound-retention-and-release-resources One descriptor and one fixed buffer belong to a streamed read; finally attempts closure after read/observation failures as well as success. A close failure returns no identity but cannot confirm native release. Opt-in opened/closed/close-failed observations carry one trace-only call id and actual descriptor, PID/thread and already observed physical identity. Records belong to the single-file collector.
19
28
  */
20
- export declare function runtimeExecutableIdentity(runtime: string): string | undefined;
29
+ export declare function runtimeExecutableIdentity(runtime: string, identities?: PluginContentIdentities.Store): string | undefined;
@@ -8,55 +8,41 @@ const node_crypto_1 = __importDefault(require("node:crypto"));
8
8
  const node_fs_1 = __importDefault(require("node:fs"));
9
9
  const node_path_1 = __importDefault(require("node:path"));
10
10
  const node_worker_threads_1 = require("node:worker_threads");
11
+ const PluginContentIdentities_1 = require("../plugin/internal/source/PluginContentIdentities");
11
12
  const E2ETrace_1 = require("./E2ETrace");
12
13
  /**
13
14
  * Fingerprint an absolute executable's spelling, target and actual bytes.
14
15
  *
15
16
  * A changed link, file, or read failure yields no reusable identity. Metadata
16
- * brackets the streamed read; it is not used to reuse an earlier content hash.
17
- * Concurrent writes that evade every filesystem observation remain outside this
18
- * snapshot guarantee.
17
+ * brackets the streamed read. Concurrent writes that evade every filesystem
18
+ * observation remain outside this snapshot guarantee.
19
19
  *
20
- * @evidence contracts/common.md#principled-implementation The identity joins lexical-link metadata, the selected physical file metadata and SHA-256 of that opened file; matching metadata alone cannot authorize reuse after bytes change. Descriptor and pathname observations must still agree after reading.
21
- * @evidence contracts/common.md#clear-and-simple-design This one native owner supplies the same content proof to runtime capability and plugin caches; callers decide whether their other inputs permit reuse.
22
- * @evidence contracts/common.md#prohibited-implementation-shortcuts Supported Node filesystem and crypto APIs inspect the actual candidate; no fixture identity, foreign mutation or metadata-only shortcut substitutes for content.
23
- * @evidence contracts/common.md#meaningful-documentation Native prose explains absolute-path scope, failure meaning, hash freshness and the remaining concurrent-mutation limitation, with separate prose and tags.
24
- * @evidence contracts/portability.md#os-neutral-implementation Node native realpath and bigint stat preserve link/target identity on supported hosts; absolute paths use native platform semantics, and unreadable or non-regular targets cannot be reused.
25
- * @evidence contracts/performance.md#efficient-algorithms A sequential read hashes B bytes with one 64 KiB buffer instead of a complete executable allocation. Native path/realpath/stat observations and serialized physical spelling/metadata add text/lookup costs; B and spelling lengths have no quota here. Returned identity storage includes the physical path as well as the fixed-length digest.
26
- *
27
- * @evidenceExclude contracts/performance.md#reuse-equivalent-work This operation establishes whether later work is equivalent; retaining a digest by metadata would reproduce the stale-byte defect it must prevent.
20
+ * With a record store, the bytes of an unchanged executable are proven from its
21
+ * metadata instead of streamed again (`PluginContentIdentities`, #1723): the
22
+ * recorded digest stands only while the physical file's identity, size and both
23
+ * stamps match the record and its modification stamp is separable from a
24
+ * reference the store minted. A plugin load asks for this identity several
25
+ * times, and every launch is a new process, so streaming an 85 MB runtime each
26
+ * time cost about 0.9 s per launch. Without a store, or when that proof is
27
+ * unavailable, the file is streamed as before.
28
28
  *
29
- * @evidence contracts/performance.md#bound-retention-and-release-resources One descriptor and one fixed buffer belong to this synchronous call; finally attempts closure after read/observation failures as well as success. A close failure returns no identity but cannot confirm native release. Returned path/metadata/digest text transfers to the caller and no helper history survives. Opt-in opened/closed/close-failed observations carry one trace-only call id and actual descriptor, PID/thread and already observed physical identity. The existing finally performs the single close; no observer retries it or converts an unavailable identity to success. An observed close is release of this Node descriptor, not proof that an OS image lock or another actor has released the executable.
29
+ * @param runtime The executable, absolute.
30
+ * @param identities Optional record store of the caller's plugin cache.
31
+ * @evidence contracts/common.md#principled-implementation The identity joins lexical-link metadata, the selected physical file metadata and the SHA-256 of that file's bytes, streamed under metadata brackets or proven by a record whose separable signature still matches; descriptor and pathname observations must still agree after a read.
32
+ * @evidence contracts/common.md#clear-and-simple-design This one native owner supplies the same identity to runtime capability and plugin caches; the record store owns metadata reuse and a private helper owns the bracketed stream.
33
+ * @evidence contracts/common.md#prohibited-implementation-shortcuts Metadata alone never stands for bytes: reuse needs a record written under unchanged separable metadata around an actual read, which a same-tick rewrite or restored timestamps cannot satisfy because change time and the minted reference move.
34
+ * @evidence contracts/common.md#meaningful-documentation Native prose explains absolute-path scope, failure meaning, the record proof and the remaining concurrent-mutation limitation, with separate prose and tags.
35
+ * @evidence contracts/portability.md#os-neutral-implementation Node native realpath and bigint stat preserve link/target identity on supported hosts; absolute paths use native platform semantics, and unreadable or non-regular targets cannot be reused.
36
+ * @evidence contracts/performance.md#efficient-algorithms A proven record costs three stats and one small file read; otherwise a sequential read hashes B bytes with one 64 KiB buffer instead of a complete executable allocation. Native path/realpath/stat observations and serialized metadata add text/lookup costs.
37
+ * @evidence contracts/performance.md#reuse-equivalent-work Processes share an executable digest only through the record store's separable-signature proof; without a store every call streams the file.
38
+ * @evidence contracts/performance.md#bound-retention-and-release-resources One descriptor and one fixed buffer belong to a streamed read; finally attempts closure after read/observation failures as well as success. A close failure returns no identity but cannot confirm native release. Opt-in opened/closed/close-failed observations carry one trace-only call id and actual descriptor, PID/thread and already observed physical identity. Records belong to the single-file collector.
30
39
  */
31
- function runtimeExecutableIdentity(runtime) {
40
+ function runtimeExecutableIdentity(runtime, identities) {
32
41
  if (!node_path_1.default.isAbsolute(runtime))
33
42
  return undefined;
34
43
  const startedAt = new Date().toISOString();
35
- let descriptor;
36
- let traceLease;
37
44
  let stage = "lexical-stat";
38
- const unavailable = (reason, expected, observed, observations) => {
39
- E2ETrace_1.E2ETrace.capabilityResolution("runtime-executable-identity-unavailable", {
40
- runtime,
41
- stage,
42
- reason,
43
- expected,
44
- observed,
45
- expectedAtimeNs: observations === undefined
46
- ? undefined
47
- : String(observations.before.atimeNs),
48
- observedAtimeNs: observations === undefined
49
- ? undefined
50
- : String(observations.after.atimeNs),
51
- expectedBirthtimeNs: observations === undefined
52
- ? undefined
53
- : String(observations.before.birthtimeNs),
54
- observedBirthtimeNs: observations === undefined
55
- ? undefined
56
- : String(observations.after.birthtimeNs),
57
- });
58
- return undefined;
59
- };
45
+ let refused;
60
46
  try {
61
47
  const lexical = node_fs_1.default.lstatSync(runtime, { bigint: true });
62
48
  stage = "physical-realpath";
@@ -64,68 +50,23 @@ function runtimeExecutableIdentity(runtime) {
64
50
  stage = "physical-stat";
65
51
  const physical = node_fs_1.default.statSync(physicalPath, { bigint: true });
66
52
  if (!physical.isFile())
67
- return unavailable("not-regular", undefined, fileIdentity(physical));
68
- stage = "open";
69
- descriptor = node_fs_1.default.openSync(physicalPath, "r");
70
- if (process.env.TTSC_E2E_TRACE) {
71
- traceLease = {
72
- callId: String(++identityTraceOrdinal),
73
- runtime,
74
- physicalPath,
75
- descriptor,
76
- pid: process.pid,
77
- threadId: node_worker_threads_1.threadId,
78
- dev: String(physical.dev),
79
- ino: String(physical.ino),
80
- };
81
- E2ETrace_1.E2ETrace.capabilityResolution("runtime-executable-identity-opened", traceLease);
82
- }
83
- stage = "opened-stat";
84
- const opened = node_fs_1.default.fstatSync(descriptor, { bigint: true });
85
- if (fileIdentity(opened) !== fileIdentity(physical))
86
- return unavailable("opened-file-changed", fileIdentity(physical), fileIdentity(opened));
87
- const hash = node_crypto_1.default.createHash("sha256");
88
- const buffer = Buffer.allocUnsafe(64 * 1024);
89
- let remaining = opened.size;
90
- stage = "read";
91
- while (remaining > 0n) {
92
- const requested = remaining > BigInt(buffer.length) ? buffer.length : Number(remaining);
93
- const length = node_fs_1.default.readSync(descriptor, buffer, 0, requested, null);
94
- if (length === 0)
95
- return unavailable("premature-eof", String(opened.size), String(opened.size - remaining));
96
- hash.update(buffer.subarray(0, length));
97
- remaining -= BigInt(length);
98
- }
99
- stage = "post-read-opened-stat";
100
- const afterOpened = node_fs_1.default.fstatSync(descriptor, { bigint: true });
101
- if (fileIdentity(afterOpened) !== fileIdentity(opened))
102
- return unavailable("opened-file-changed-during-read", fileIdentity(opened), fileIdentity(afterOpened), { before: opened, after: afterOpened });
103
- stage = "post-read-realpath";
104
- const afterPath = node_fs_1.default.realpathSync.native(runtime);
105
- if (afterPath !== physicalPath)
106
- return unavailable("physical-target-changed", physicalPath, afterPath);
107
- stage = "post-read-lexical-stat";
108
- const afterLexical = node_fs_1.default.lstatSync(runtime, { bigint: true });
109
- if (fileIdentity(afterLexical) !== fileIdentity(lexical))
110
- return unavailable("lexical-file-changed-during-read", fileIdentity(lexical), fileIdentity(afterLexical));
111
- stage = "post-read-physical-stat";
112
- const afterPhysical = node_fs_1.default.statSync(physicalPath, { bigint: true });
113
- if (fileIdentity(afterPhysical) !== fileIdentity(physical))
114
- return unavailable("physical-file-changed-during-read", fileIdentity(physical), fileIdentity(afterPhysical));
115
- const digest = hash.digest("hex");
116
- E2ETrace_1.E2ETrace.capabilityResolution("runtime-executable-identity-observed", {
117
- runtime,
118
- physicalPath,
119
- startedAt,
120
- finishedAt: new Date().toISOString(),
121
- lexical: fileIdentity(lexical),
122
- physical: fileIdentity(physical),
123
- digest,
124
- openedAtimeNs: String(opened.atimeNs),
125
- afterOpenedAtimeNs: String(afterOpened.atimeNs),
126
- openedBirthtimeNs: String(opened.birthtimeNs),
127
- afterOpenedBirthtimeNs: String(afterOpened.birthtimeNs),
128
- });
53
+ return unavailable(runtime, {
54
+ stage,
55
+ reason: "not-regular",
56
+ observed: fileIdentity(physical),
57
+ });
58
+ const read = () => {
59
+ const streamed = streamDigest(runtime, physicalPath, physical, lexical, {
60
+ startedAt,
61
+ });
62
+ if (typeof streamed === "string")
63
+ return streamed;
64
+ refused = streamed;
65
+ throw new Error(streamed.reason);
66
+ };
67
+ const digest = identities === undefined
68
+ ? read()
69
+ : PluginContentIdentities_1.PluginContentIdentities.digest(identities, "executable", physicalPath, (references) => PluginContentIdentities_1.PluginContentIdentities.fileObservation(references, physicalPath), read);
129
70
  return [
130
71
  physicalPath,
131
72
  fileIdentity(lexical),
@@ -134,7 +75,48 @@ function runtimeExecutableIdentity(runtime) {
134
75
  ].join("\0");
135
76
  }
136
77
  catch (error) {
137
- return unavailable("filesystem-error", undefined, error instanceof Error ? error.message : String(error));
78
+ return unavailable(runtime, refused ?? {
79
+ stage,
80
+ reason: "filesystem-error",
81
+ observed: error instanceof Error ? error.message : String(error),
82
+ });
83
+ }
84
+ }
85
+ function unavailable(runtime, failure) {
86
+ E2ETrace_1.E2ETrace.capabilityResolution("runtime-executable-identity-unavailable", {
87
+ runtime,
88
+ stage: failure.stage,
89
+ reason: failure.reason,
90
+ expected: failure.expected,
91
+ observed: failure.observed,
92
+ expectedAtimeNs: failure.observations === undefined
93
+ ? undefined
94
+ : String(failure.observations.before.atimeNs),
95
+ observedAtimeNs: failure.observations === undefined
96
+ ? undefined
97
+ : String(failure.observations.after.atimeNs),
98
+ expectedBirthtimeNs: failure.observations === undefined
99
+ ? undefined
100
+ : String(failure.observations.before.birthtimeNs),
101
+ observedBirthtimeNs: failure.observations === undefined
102
+ ? undefined
103
+ : String(failure.observations.after.birthtimeNs),
104
+ });
105
+ return undefined;
106
+ }
107
+ /**
108
+ * Stream the physical file's bytes between metadata observations of the open
109
+ * descriptor, the physical path and the lexical spelling, returning the digest
110
+ * or what moved. The descriptor is closed in finally; a failed close refuses
111
+ * the identity.
112
+ */
113
+ function streamDigest(runtime, physicalPath, physical, lexical, timing) {
114
+ let stage = "open";
115
+ let descriptor;
116
+ let traceLease;
117
+ let result;
118
+ try {
119
+ result = observe();
138
120
  }
139
121
  finally {
140
122
  if (descriptor !== undefined) {
@@ -149,11 +131,119 @@ function runtimeExecutableIdentity(runtime) {
149
131
  ...traceLease,
150
132
  error: error instanceof Error ? error.message : String(error),
151
133
  });
152
- stage = "close";
153
- return unavailable("descriptor-close-error", undefined, error instanceof Error ? error.message : String(error));
134
+ // A digest whose descriptor could not be closed is refused, as before.
135
+ result = {
136
+ stage: "close",
137
+ reason: "descriptor-close-error",
138
+ observed: error instanceof Error ? error.message : String(error),
139
+ };
154
140
  }
155
141
  }
156
142
  }
143
+ return result;
144
+ function observe() {
145
+ try {
146
+ descriptor = node_fs_1.default.openSync(physicalPath, "r");
147
+ if (process.env.TTSC_E2E_TRACE) {
148
+ traceLease = {
149
+ callId: String(++identityTraceOrdinal),
150
+ runtime,
151
+ physicalPath,
152
+ descriptor,
153
+ pid: process.pid,
154
+ threadId: node_worker_threads_1.threadId,
155
+ dev: String(physical.dev),
156
+ ino: String(physical.ino),
157
+ };
158
+ E2ETrace_1.E2ETrace.capabilityResolution("runtime-executable-identity-opened", traceLease);
159
+ }
160
+ stage = "opened-stat";
161
+ const opened = node_fs_1.default.fstatSync(descriptor, { bigint: true });
162
+ if (fileIdentity(opened) !== fileIdentity(physical))
163
+ return {
164
+ stage,
165
+ reason: "opened-file-changed",
166
+ expected: fileIdentity(physical),
167
+ observed: fileIdentity(opened),
168
+ };
169
+ const hash = node_crypto_1.default.createHash("sha256");
170
+ const buffer = Buffer.allocUnsafe(64 * 1024);
171
+ let remaining = opened.size;
172
+ stage = "read";
173
+ while (remaining > 0n) {
174
+ const requested = remaining > BigInt(buffer.length) ? buffer.length : Number(remaining);
175
+ const length = node_fs_1.default.readSync(descriptor, buffer, 0, requested, null);
176
+ if (length === 0)
177
+ return {
178
+ stage,
179
+ reason: "premature-eof",
180
+ expected: String(opened.size),
181
+ observed: String(opened.size - remaining),
182
+ };
183
+ hash.update(buffer.subarray(0, length));
184
+ remaining -= BigInt(length);
185
+ }
186
+ stage = "post-read-opened-stat";
187
+ const afterOpened = node_fs_1.default.fstatSync(descriptor, { bigint: true });
188
+ if (fileIdentity(afterOpened) !== fileIdentity(opened))
189
+ return {
190
+ stage,
191
+ reason: "opened-file-changed-during-read",
192
+ expected: fileIdentity(opened),
193
+ observed: fileIdentity(afterOpened),
194
+ observations: { before: opened, after: afterOpened },
195
+ };
196
+ stage = "post-read-realpath";
197
+ const afterPath = node_fs_1.default.realpathSync.native(runtime);
198
+ if (afterPath !== physicalPath)
199
+ return {
200
+ stage,
201
+ reason: "physical-target-changed",
202
+ expected: physicalPath,
203
+ observed: afterPath,
204
+ };
205
+ stage = "post-read-lexical-stat";
206
+ const afterLexical = node_fs_1.default.lstatSync(runtime, { bigint: true });
207
+ if (fileIdentity(afterLexical) !== fileIdentity(lexical))
208
+ return {
209
+ stage,
210
+ reason: "lexical-file-changed-during-read",
211
+ expected: fileIdentity(lexical),
212
+ observed: fileIdentity(afterLexical),
213
+ };
214
+ stage = "post-read-physical-stat";
215
+ const afterPhysical = node_fs_1.default.statSync(physicalPath, { bigint: true });
216
+ if (fileIdentity(afterPhysical) !== fileIdentity(physical))
217
+ return {
218
+ stage,
219
+ reason: "physical-file-changed-during-read",
220
+ expected: fileIdentity(physical),
221
+ observed: fileIdentity(afterPhysical),
222
+ };
223
+ const digest = hash.digest("hex");
224
+ E2ETrace_1.E2ETrace.capabilityResolution("runtime-executable-identity-observed", {
225
+ runtime,
226
+ physicalPath,
227
+ startedAt: timing.startedAt,
228
+ finishedAt: new Date().toISOString(),
229
+ lexical: fileIdentity(lexical),
230
+ physical: fileIdentity(physical),
231
+ digest,
232
+ openedAtimeNs: String(opened.atimeNs),
233
+ afterOpenedAtimeNs: String(afterOpened.atimeNs),
234
+ openedBirthtimeNs: String(opened.birthtimeNs),
235
+ afterOpenedBirthtimeNs: String(afterOpened.birthtimeNs),
236
+ });
237
+ return digest;
238
+ }
239
+ catch (error) {
240
+ return {
241
+ stage,
242
+ reason: "filesystem-error",
243
+ observed: error instanceof Error ? error.message : String(error),
244
+ };
245
+ }
246
+ }
157
247
  }
158
248
  // Trace-only ordinal distinguishes sequential uses of a reused descriptor.
159
249
  let identityTraceOrdinal = 0;
@@ -1 +1 @@
1
- {"version":3,"file":"runtimeExecutableIdentity.js","sourceRoot":"","sources":["../../src/internal/runtimeExecutableIdentity.ts"],"names":[],"mappings":";;;;;;AAAA,8DAAiC;AACjC,sDAAyB;AACzB,0DAA6B;AAC7B,6DAA+C;AAE/C,yCAAsC;AAEtC;;;;;;;;;;;;;;;;;;GAkBG;AACH,mCAA0C,OAAe;IACvD,IAAI,CAAC,mBAAI,CAAC,UAAU,CAAC,OAAO,CAAC;QAAE,OAAO,SAAS,CAAC;IAChD,MAAM,SAAS,GAAG,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC;IAC3C,IAAI,UAA8B,CAAC;IACnC,IAAI,UAAiE,CAAC;IACtE,IAAI,KAAK,GAAG,cAAc,CAAC;IAC3B,MAAM,WAAW,GAAG,CAClB,MAAc,EACd,QAAiB,EACjB,QAAiB,EACjB,YAAgE,EAChE,EAAE;QACF,mBAAQ,CAAC,oBAAoB,CAAC,yCAAyC,EAAE;YACvE,OAAO;YACP,KAAK;YACL,MAAM;YACN,QAAQ;YACR,QAAQ;YACR,eAAe,EACb,YAAY,KAAK,SAAS;gBACxB,CAAC,CAAC,SAAS;gBACX,CAAC,CAAC,MAAM,CAAC,YAAY,CAAC,MAAM,CAAC,OAAO,CAAC;YACzC,eAAe,EACb,YAAY,KAAK,SAAS;gBACxB,CAAC,CAAC,SAAS;gBACX,CAAC,CAAC,MAAM,CAAC,YAAY,CAAC,KAAK,CAAC,OAAO,CAAC;YACxC,mBAAmB,EACjB,YAAY,KAAK,SAAS;gBACxB,CAAC,CAAC,SAAS;gBACX,CAAC,CAAC,MAAM,CAAC,YAAY,CAAC,MAAM,CAAC,WAAW,CAAC;YAC7C,mBAAmB,EACjB,YAAY,KAAK,SAAS;gBACxB,CAAC,CAAC,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J,KAAK,GAAG,OAAO,CAAC;gBAChB,OAAO,WAAW,CAChB,wBAAwB,EACxB,SAAS,EACT,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CACvD,CAAC;YACJ,CAAC;QACH,CAAC;IACH,CAAC;AACH,CAAC;AAED,2EAA2E;AAC3E,IAAI,oBAAoB,GAAG,CAAC,CAAC;AAE7B,0EAA0E;AAC1E,SAAS,YAAY,CAAC,IAAoB;IACxC,OAAO;QACL,IAAI,CAAC,GAAG;QACR,IAAI,CAAC,GAAG;QACR,IAAI,CAAC,IAAI;QACT,IAAI,CAAC,IAAI;QACT,IAAI,CAAC,OAAO;QACZ,IAAI,CAAC,OAAO;KACb,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACf,CAAC"}
1
+ {"version":3,"file":"runtimeExecutableIdentity.js","sourceRoot":"","sources":["../../src/internal/runtimeExecutableIdentity.ts"],"names":[],"mappings":";;;;;;AAAA,8DAAiC;AACjC,sDAAyB;AACzB,0DAA6B;AAC7B,6DAA+C;AAE/C,+FAA4F;AAC5F,yCAAsC;AAEtC;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,mCACE,OAAe,EACf,UAA0C;IAE1C,IAAI,CAAC,mBAAI,CAAC,UAAU,CAAC,OAAO,CAAC;QAAE,OAAO,SAAS,CAAC;IAChD,MAAM,SAAS,GAAG,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC;IAC3C,IAAI,KAAK,GAAG,cAAc,CAAC;IAC3B,IAAI,OAAiC,CAAC;IACtC,IAAI,CAAC;QACH,MAAM,OAAO,GAAG,iBAAE,CAAC,SAAS,CAAC,OAAO,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;QACxD,KAAK,GAAG,mBAAmB,CAAC;QAC5B,MAAM,YAAY,GAAG,iBAAE,CAAC,YAAY,CAAC,MAAM,CAAC,OAAO,C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,IAAI,oBAAoB,GAAG,CAAC,CAAC;AAE7B,0EAA0E;AAC1E,SAAS,YAAY,CAAC,IAAoB;IACxC,OAAO;QACL,IAAI,CAAC,GAAG;QACR,IAAI,CAAC,GAAG;QACR,IAAI,CAAC,IAAI;QACT,IAAI,CAAC,IAAI;QACT,IAAI,CAAC,OAAO;QACZ,IAAI,CAAC,OAAO;KACb,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACf,CAAC"}
@@ -15,11 +15,13 @@ const runBuild_1 = require("../../../compiler/internal/build/runBuild");
15
15
  const readProjectConfig_1 = require("../../../compiler/internal/project/readProjectConfig");
16
16
  const resolveOwningProjectConfig_1 = require("../../../compiler/internal/project/resolveOwningProjectConfig");
17
17
  const resolveTsgo_1 = require("../../../compiler/internal/resolveTsgo");
18
+ const SidecarEnvironment_1 = require("../../../compiler/internal/sharedHost/SidecarEnvironment");
18
19
  const spawnNative_1 = require("../../../compiler/internal/spawnNative");
19
20
  const E2ETrace_1 = require("../../../internal/E2ETrace");
20
21
  const createCanonicalTempDirectory_1 = require("../../../internal/createCanonicalTempDirectory");
21
22
  const runtimeExecutableIdentity_1 = require("../../../internal/runtimeExecutableIdentity");
22
23
  const moduleResolutionBaseSelects_1 = require("../../../plugin/internal/load/moduleResolutionBaseSelects");
24
+ const PluginContentIdentities_1 = require("../../../plugin/internal/source/PluginContentIdentities");
23
25
  const recordCacheFileUse_1 = require("../../../plugin/internal/source/recordCacheFileUse");
24
26
  const buildSingleRootProject_1 = require("../buildSingleRootProject");
25
27
  const inlineServedSourceMap_1 = require("../inlineServedSourceMap");
@@ -547,6 +549,17 @@ function observePluginDescriptorInputOnce(record) {
547
549
  (record.hash !== undefined && record.hash !== observedHash) ||
548
550
  (record.realpath !== undefined && record.realpath !== observedRealpath) ||
549
551
  (record.signature !== undefined && record.signature !== afterSignature);
552
+ // A missing path's signature is its nearest existing ancestor's metadata,
553
+ // so a write anywhere in that ancestor refuses the proof; the trace names
554
+ // which observation moved.
555
+ if (unstable)
556
+ E2ETrace_1.E2ETrace.capabilityResolution("plugin-descriptor-input-unstable", {
557
+ resolved: record.resolved,
558
+ recordedSignature: record.signature,
559
+ beforeSignature,
560
+ afterSignature,
561
+ hashChanged: record.hash !== undefined && record.hash !== observedHash,
562
+ });
550
563
  return `${JSON.stringify({
551
564
  ...record,
552
565
  hash: observedHash,
@@ -1189,11 +1202,52 @@ function orphanCacheRoot() {
1189
1202
  * Read afresh at every use, never remembered by path: a long-lived process can
1190
1203
  * lower orphans before and after the compiler at that path is replaced, and an
1191
1204
  * entry lowered by the new one must not be recorded under the old one's key for
1192
- * a later process to adopt.
1205
+ * a later process to adopt. A fresh use proves an unchanged compiler from the
1206
+ * run's plugin cache records (`runtimeRecordStore`), which observe its metadata
1207
+ * again each time.
1193
1208
  */
1194
1209
  function compilerIdentity(binary) {
1195
- return (0, runtimeExecutableIdentity_1.runtimeExecutableIdentity)(binary) ?? node_crypto_1.default.randomUUID();
1210
+ return ((0, runtimeExecutableIdentity_1.runtimeExecutableIdentity)(binary, runtimeRecordStore()) ??
1211
+ node_crypto_1.default.randomUUID());
1212
+ }
1213
+ /**
1214
+ * The record store of this run's plugin cache root, or `undefined` without one.
1215
+ *
1216
+ * WARNING (#1726): every ttsx process and every descriptor evaluation streamed
1217
+ * the whole compiler executable (24.5 MB) to key its orphan and dependency
1218
+ * builds, although the bytes had not changed since the last process. The root
1219
+ * is the one a descriptor evaluator's parent load selected
1220
+ * (`TTSC_PLUGIN_RECORD_ROOT`), or the cache root of this run's manifest; a
1221
+ * process with neither streams as before and never selects a root itself.
1222
+ */
1223
+ function runtimeRecordStore() {
1224
+ const descriptorRoot = process.env.TTSC_PLUGIN_DESCRIPTOR_LOAD === "1"
1225
+ ? SidecarEnvironment_1.SidecarEnvironment.read(process.env, "TTSC_PLUGIN_RECORD_ROOT")
1226
+ : undefined;
1227
+ const owner = RuntimeManifestRegistry_1.RuntimeManifestRegistry.runtimeManifests().find((candidate) => typeof candidate.orphanCacheDir === "string" &&
1228
+ candidate.orphanCacheDir.length !== 0);
1229
+ const root = descriptorRoot !== undefined && node_path_1.default.isAbsolute(descriptorRoot)
1230
+ ? descriptorRoot
1231
+ : owner === undefined
1232
+ ? undefined
1233
+ : node_path_1.default.dirname(owner.orphanCacheDir);
1234
+ if (root === undefined)
1235
+ return undefined;
1236
+ // One store per root serves the process: its references only grow older,
1237
+ // which can make fewer stamps separable but never more, and each identity
1238
+ // still observes the compiler's metadata afresh.
1239
+ if (runtimeStore?.root !== root)
1240
+ runtimeStore = {
1241
+ root,
1242
+ store: PluginContentIdentities_1.PluginContentIdentities.open({
1243
+ projectRoot: root,
1244
+ cacheDir: root,
1245
+ env: process.env,
1246
+ }),
1247
+ };
1248
+ return runtimeStore.store;
1196
1249
  }
1250
+ let runtimeStore;
1197
1251
  /** The version of this ttsc package, which owns the orphan post-processing. */
1198
1252
  function ownPackageVersion() {
1199
1253
  if (ownPackageVersionCache === undefined) {
@@ -1627,7 +1681,7 @@ const failedProjects = new Map();
1627
1681
  function dependencyCachePaths(tsconfig, rootSource) {
1628
1682
  let compilerProof;
1629
1683
  try {
1630
- compilerProof = (0, runtimeExecutableIdentity_1.runtimeExecutableIdentity)((0, resolveTsgo_1.resolveTsgo)({ cwd: node_path_1.default.dirname(tsconfig) }).binary);
1684
+ compilerProof = (0, runtimeExecutableIdentity_1.runtimeExecutableIdentity)((0, resolveTsgo_1.resolveTsgo)({ cwd: node_path_1.default.dirname(tsconfig) }).binary, runtimeRecordStore());
1631
1685
  }
1632
1686
  catch {
1633
1687
  // An unobservable executable gets a unique, non-reusable generation key.
@@ -1653,7 +1707,7 @@ function assertCompilerStillCurrent(tsconfig, proof) {
1653
1707
  if (proof === undefined)
1654
1708
  return;
1655
1709
  const binary = (0, resolveTsgo_1.resolveTsgo)({ cwd: node_path_1.default.dirname(tsconfig) }).binary;
1656
- const current = (0, runtimeExecutableIdentity_1.runtimeExecutableIdentity)(binary);
1710
+ const current = (0, runtimeExecutableIdentity_1.runtimeExecutableIdentity)(binary, runtimeRecordStore());
1657
1711
  if (current !== proof) {
1658
1712
  E2ETrace_1.E2ETrace.capabilityResolution("runtime-compiler-publication-refused", {
1659
1713
  tsconfig,