@ttsc/unplugin 0.38.1 → 0.38.3
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/README.md +1 -1
- package/lib/core/bridge/HostWatchBridge.d.cts +1 -1
- package/lib/core/bridge/HostWatchBridge.d.mts +1 -1
- package/lib/core/bridge/HostWatchBridge.d.ts +1 -1
- package/lib/core/bridge/MANAGED_PROJECT_RECORDS.d.cts +2 -0
- package/lib/core/bridge/MANAGED_PROJECT_RECORDS.d.mts +2 -0
- package/lib/core/bridge/MANAGED_PROJECT_RECORDS.d.ts +2 -0
- package/lib/core/bridge/MANAGED_PROJECT_RECORDS.js +7 -0
- package/lib/core/bridge/MANAGED_PROJECT_RECORDS.js.map +1 -0
- package/lib/core/bridge/MANAGED_PROJECT_RECORDS.mjs +5 -0
- package/lib/core/bridge/MANAGED_PROJECT_RECORDS.mjs.map +1 -0
- package/lib/core/bridge/TtscProjectRecord.d.cts +9 -0
- package/lib/core/bridge/TtscProjectRecord.d.mts +9 -0
- package/lib/core/bridge/TtscProjectRecord.d.ts +9 -0
- package/lib/core/bridge/fallbackRecordStorage.d.cts +33 -0
- package/lib/core/bridge/fallbackRecordStorage.d.mts +33 -0
- package/lib/core/bridge/fallbackRecordStorage.d.ts +33 -0
- package/lib/core/bridge/fallbackRecordStorage.js +96 -0
- package/lib/core/bridge/fallbackRecordStorage.js.map +1 -0
- package/lib/core/bridge/fallbackRecordStorage.mjs +94 -0
- package/lib/core/bridge/fallbackRecordStorage.mjs.map +1 -0
- package/lib/core/bridge/fallbackToolDirectory.d.cts +11 -15
- package/lib/core/bridge/fallbackToolDirectory.d.mts +11 -15
- package/lib/core/bridge/fallbackToolDirectory.d.ts +11 -15
- package/lib/core/bridge/fallbackToolDirectory.js +19 -30
- package/lib/core/bridge/fallbackToolDirectory.js.map +1 -1
- package/lib/core/bridge/fallbackToolDirectory.mjs +19 -30
- package/lib/core/bridge/fallbackToolDirectory.mjs.map +1 -1
- package/lib/core/bridge/fallbackToolDirectoryLocation.d.cts +14 -0
- package/lib/core/bridge/fallbackToolDirectoryLocation.d.mts +14 -0
- package/lib/core/bridge/fallbackToolDirectoryLocation.d.ts +14 -0
- package/lib/core/bridge/fallbackToolDirectoryLocation.js +38 -0
- package/lib/core/bridge/fallbackToolDirectoryLocation.js.map +1 -0
- package/lib/core/bridge/fallbackToolDirectoryLocation.mjs +36 -0
- package/lib/core/bridge/fallbackToolDirectoryLocation.mjs.map +1 -0
- package/lib/core/bridge/hostToolDirectory.d.cts +13 -46
- package/lib/core/bridge/hostToolDirectory.d.mts +13 -46
- package/lib/core/bridge/hostToolDirectory.d.ts +13 -46
- package/lib/core/bridge/hostToolDirectory.js +14 -47
- package/lib/core/bridge/hostToolDirectory.js.map +1 -1
- package/lib/core/bridge/hostToolDirectory.mjs +14 -47
- package/lib/core/bridge/hostToolDirectory.mjs.map +1 -1
- package/lib/core/bridge/openHostWatchBridge.d.cts +11 -1
- package/lib/core/bridge/openHostWatchBridge.d.mts +11 -1
- package/lib/core/bridge/openHostWatchBridge.d.ts +11 -1
- package/lib/core/bridge/openHostWatchBridge.js +28 -6
- package/lib/core/bridge/openHostWatchBridge.js.map +1 -1
- package/lib/core/bridge/openHostWatchBridge.mjs +28 -6
- package/lib/core/bridge/openHostWatchBridge.mjs.map +1 -1
- package/lib/core/bridge/prepareProjectRecordDirectory.d.cts +41 -0
- package/lib/core/bridge/prepareProjectRecordDirectory.d.mts +41 -0
- package/lib/core/bridge/prepareProjectRecordDirectory.d.ts +41 -0
- package/lib/core/bridge/prepareProjectRecordDirectory.js +127 -0
- package/lib/core/bridge/prepareProjectRecordDirectory.js.map +1 -0
- package/lib/core/bridge/prepareProjectRecordDirectory.mjs +125 -0
- package/lib/core/bridge/prepareProjectRecordDirectory.mjs.map +1 -0
- package/lib/core/bridge/privateProjectRecordAvailable.d.cts +13 -0
- package/lib/core/bridge/privateProjectRecordAvailable.d.mts +13 -0
- package/lib/core/bridge/privateProjectRecordAvailable.d.ts +13 -0
- package/lib/core/bridge/privateProjectRecordAvailable.js +31 -0
- package/lib/core/bridge/privateProjectRecordAvailable.js.map +1 -0
- package/lib/core/bridge/privateProjectRecordAvailable.mjs +29 -0
- package/lib/core/bridge/privateProjectRecordAvailable.mjs.map +1 -0
- package/lib/core/bridge/projectRecordMoved.js +5 -0
- package/lib/core/bridge/projectRecordMoved.js.map +1 -1
- package/lib/core/bridge/projectRecordMoved.mjs +5 -0
- package/lib/core/bridge/projectRecordMoved.mjs.map +1 -1
- package/lib/core/bridge/projectRecordWatchInputs.js +6 -0
- package/lib/core/bridge/projectRecordWatchInputs.js.map +1 -1
- package/lib/core/bridge/projectRecordWatchInputs.mjs +6 -0
- package/lib/core/bridge/projectRecordWatchInputs.mjs.map +1 -1
- package/lib/core/bridge/readProjectRecordFile.js +23 -1
- package/lib/core/bridge/readProjectRecordFile.js.map +1 -1
- package/lib/core/bridge/readProjectRecordFile.mjs +23 -1
- package/lib/core/bridge/readProjectRecordFile.mjs.map +1 -1
- package/lib/core/bridge/refreshProjectRecordFile.d.cts +7 -2
- package/lib/core/bridge/refreshProjectRecordFile.d.mts +7 -2
- package/lib/core/bridge/refreshProjectRecordFile.d.ts +7 -2
- package/lib/core/bridge/refreshProjectRecordFile.js +24 -7
- package/lib/core/bridge/refreshProjectRecordFile.js.map +1 -1
- package/lib/core/bridge/refreshProjectRecordFile.mjs +24 -7
- package/lib/core/bridge/refreshProjectRecordFile.mjs.map +1 -1
- package/lib/core/bridge/refreshProjectRecordFiles.d.cts +7 -4
- package/lib/core/bridge/refreshProjectRecordFiles.d.mts +7 -4
- package/lib/core/bridge/refreshProjectRecordFiles.d.ts +7 -4
- package/lib/core/bridge/refreshProjectRecordFiles.js +30 -8
- package/lib/core/bridge/refreshProjectRecordFiles.js.map +1 -1
- package/lib/core/bridge/refreshProjectRecordFiles.mjs +30 -8
- package/lib/core/bridge/refreshProjectRecordFiles.mjs.map +1 -1
- package/lib/core/bridge/registerProjectRecord.js +3 -1
- package/lib/core/bridge/registerProjectRecord.js.map +1 -1
- package/lib/core/bridge/registerProjectRecord.mjs +3 -1
- package/lib/core/bridge/registerProjectRecord.mjs.map +1 -1
- package/lib/core/bridge/signalProjectRecordFile.d.cts +7 -2
- package/lib/core/bridge/signalProjectRecordFile.d.mts +7 -2
- package/lib/core/bridge/signalProjectRecordFile.d.ts +7 -2
- package/lib/core/bridge/signalProjectRecordFile.js +18 -5
- package/lib/core/bridge/signalProjectRecordFile.js.map +1 -1
- package/lib/core/bridge/signalProjectRecordFile.mjs +18 -5
- package/lib/core/bridge/signalProjectRecordFile.mjs.map +1 -1
- package/lib/core/bridge/writeProjectRecordFile.js +7 -3
- package/lib/core/bridge/writeProjectRecordFile.js.map +1 -1
- package/lib/core/bridge/writeProjectRecordFile.mjs +7 -3
- package/lib/core/bridge/writeProjectRecordFile.mjs.map +1 -1
- package/lib/core/esbuild/createEsbuildOptions.js +9 -7
- package/lib/core/esbuild/createEsbuildOptions.js.map +1 -1
- package/lib/core/esbuild/createEsbuildOptions.mjs +9 -7
- package/lib/core/esbuild/createEsbuildOptions.mjs.map +1 -1
- package/lib/core/farm/createFarmRecordUpdates.d.cts +63 -0
- package/lib/core/farm/createFarmRecordUpdates.d.mts +63 -0
- package/lib/core/farm/createFarmRecordUpdates.d.ts +63 -0
- package/lib/core/farm/createFarmRecordUpdates.js +129 -0
- package/lib/core/farm/createFarmRecordUpdates.js.map +1 -0
- package/lib/core/farm/createFarmRecordUpdates.mjs +127 -0
- package/lib/core/farm/createFarmRecordUpdates.mjs.map +1 -0
- package/lib/core/farm/farmPersistentCacheWithoutRecords.d.cts +15 -40
- package/lib/core/farm/farmPersistentCacheWithoutRecords.d.mts +15 -40
- package/lib/core/farm/farmPersistentCacheWithoutRecords.d.ts +15 -40
- package/lib/core/farm/farmPersistentCacheWithoutRecords.js +23 -56
- package/lib/core/farm/farmPersistentCacheWithoutRecords.js.map +1 -1
- package/lib/core/farm/farmPersistentCacheWithoutRecords.mjs +23 -56
- package/lib/core/farm/farmPersistentCacheWithoutRecords.mjs.map +1 -1
- package/lib/core/farm/farmRecordFallback.d.cts +15 -15
- package/lib/core/farm/farmRecordFallback.d.mts +15 -15
- package/lib/core/farm/farmRecordFallback.d.ts +15 -15
- package/lib/core/farm/farmRecordFallback.js +22 -20
- package/lib/core/farm/farmRecordFallback.js.map +1 -1
- package/lib/core/farm/farmRecordFallback.mjs +22 -20
- package/lib/core/farm/farmRecordFallback.mjs.map +1 -1
- package/lib/core/next/next.js +5 -4
- package/lib/core/next/next.js.map +1 -1
- package/lib/core/next/next.mjs +5 -4
- package/lib/core/next/next.mjs.map +1 -1
- package/lib/core/observer/InputCondition.d.cts +5 -0
- package/lib/core/observer/InputCondition.d.mts +5 -0
- package/lib/core/observer/InputCondition.d.ts +5 -0
- package/lib/core/observer/InputObserverChange.d.cts +2 -0
- package/lib/core/observer/InputObserverChange.d.mts +2 -0
- package/lib/core/observer/InputObserverChange.d.ts +2 -0
- package/lib/core/observer/createInputObserver.d.cts +3 -1
- package/lib/core/observer/createInputObserver.d.mts +3 -1
- package/lib/core/observer/createInputObserver.d.ts +3 -1
- package/lib/core/observer/createInputObserver.js +179 -26
- package/lib/core/observer/createInputObserver.js.map +1 -1
- package/lib/core/observer/createInputObserver.mjs +180 -27
- package/lib/core/observer/createInputObserver.mjs.map +1 -1
- package/lib/core/observer/ttscWriteDirectories.d.cts +31 -0
- package/lib/core/observer/ttscWriteDirectories.d.mts +31 -0
- package/lib/core/observer/ttscWriteDirectories.d.ts +31 -0
- package/lib/core/observer/ttscWriteDirectories.js +59 -0
- package/lib/core/observer/ttscWriteDirectories.js.map +1 -0
- package/lib/core/observer/ttscWriteDirectories.mjs +57 -0
- package/lib/core/observer/ttscWriteDirectories.mjs.map +1 -0
- package/lib/core/rollup/TtscRollupDelivery.d.cts +2 -0
- package/lib/core/rollup/TtscRollupDelivery.d.mts +2 -0
- package/lib/core/rollup/TtscRollupDelivery.d.ts +2 -0
- package/lib/core/rollup/createRollupCachedModuleProof.d.cts +15 -11
- package/lib/core/rollup/createRollupCachedModuleProof.d.mts +15 -11
- package/lib/core/rollup/createRollupCachedModuleProof.d.ts +15 -11
- package/lib/core/rollup/createRollupCachedModuleProof.js +62 -33
- package/lib/core/rollup/createRollupCachedModuleProof.js.map +1 -1
- package/lib/core/rollup/createRollupCachedModuleProof.mjs +62 -33
- package/lib/core/rollup/createRollupCachedModuleProof.mjs.map +1 -1
- package/lib/core/rollup/rollupDeliveryOptions.d.cts +6 -4
- package/lib/core/rollup/rollupDeliveryOptions.d.mts +6 -4
- package/lib/core/rollup/rollupDeliveryOptions.d.ts +6 -4
- package/lib/core/rollup/rollupDeliveryOptions.js +7 -4
- package/lib/core/rollup/rollupDeliveryOptions.js.map +1 -1
- package/lib/core/rollup/rollupDeliveryOptions.mjs +7 -4
- package/lib/core/rollup/rollupDeliveryOptions.mjs.map +1 -1
- package/lib/core/transform/cache/TtscCachedProjectTransform.d.cts +7 -0
- package/lib/core/transform/cache/TtscCachedProjectTransform.d.mts +7 -0
- package/lib/core/transform/cache/TtscCachedProjectTransform.d.ts +7 -0
- package/lib/core/transform/cache/selectCachedGenerationAction.d.cts +3 -1
- package/lib/core/transform/cache/selectCachedGenerationAction.d.mts +3 -1
- package/lib/core/transform/cache/selectCachedGenerationAction.d.ts +3 -1
- package/lib/core/transform/cache/selectCachedGenerationAction.js +7 -4
- package/lib/core/transform/cache/selectCachedGenerationAction.js.map +1 -1
- package/lib/core/transform/cache/selectCachedGenerationAction.mjs +7 -4
- package/lib/core/transform/cache/selectCachedGenerationAction.mjs.map +1 -1
- package/lib/core/transform/deliverCachedTransform.js +1 -0
- package/lib/core/transform/deliverCachedTransform.js.map +1 -1
- package/lib/core/transform/deliverCachedTransform.mjs +1 -0
- package/lib/core/transform/deliverCachedTransform.mjs.map +1 -1
- package/lib/core/transform/envelope/TtscEnvelopeDerivation.d.cts +6 -15
- package/lib/core/transform/envelope/TtscEnvelopeDerivation.d.mts +6 -15
- package/lib/core/transform/envelope/TtscEnvelopeDerivation.d.ts +6 -15
- package/lib/core/transform/envelope/collectDeclaredIdentities.d.cts +1 -1
- package/lib/core/transform/envelope/collectDeclaredIdentities.d.mts +1 -1
- package/lib/core/transform/envelope/collectDeclaredIdentities.d.ts +1 -1
- package/lib/core/transform/envelope/collectDeclaredIdentities.js.map +1 -1
- package/lib/core/transform/envelope/collectDeclaredIdentities.mjs.map +1 -1
- package/lib/core/transform/envelope/createEnvelopeKeyIndex.d.cts +1 -1
- package/lib/core/transform/envelope/createEnvelopeKeyIndex.d.mts +1 -1
- package/lib/core/transform/envelope/createEnvelopeKeyIndex.d.ts +1 -1
- package/lib/core/transform/envelope/createEnvelopeKeyIndex.js.map +1 -1
- package/lib/core/transform/envelope/createEnvelopeKeyIndex.mjs.map +1 -1
- package/lib/core/transform/envelope/declaresCompleteDependencies.d.cts +2 -2
- package/lib/core/transform/envelope/declaresCompleteDependencies.d.mts +2 -2
- package/lib/core/transform/envelope/declaresCompleteDependencies.d.ts +2 -2
- package/lib/core/transform/envelope/declaresCompleteDependencies.js +2 -1
- package/lib/core/transform/envelope/declaresCompleteDependencies.js.map +1 -1
- package/lib/core/transform/envelope/declaresCompleteDependencies.mjs +2 -1
- package/lib/core/transform/envelope/declaresCompleteDependencies.mjs.map +1 -1
- package/lib/core/transform/envelope/derivationIdentity.d.cts +1 -1
- package/lib/core/transform/envelope/derivationIdentity.d.mts +1 -1
- package/lib/core/transform/envelope/derivationIdentity.d.ts +1 -1
- package/lib/core/transform/envelope/derivationIdentity.js.map +1 -1
- package/lib/core/transform/envelope/derivationIdentity.mjs.map +1 -1
- package/lib/core/transform/envelope/deriveWatchInputs.js +4 -64
- package/lib/core/transform/envelope/deriveWatchInputs.js.map +1 -1
- package/lib/core/transform/envelope/deriveWatchInputs.mjs +4 -64
- package/lib/core/transform/envelope/deriveWatchInputs.mjs.map +1 -1
- package/lib/core/transform/envelope/deriveWatchInputsFromIndexes.d.cts +24 -0
- package/lib/core/transform/envelope/deriveWatchInputsFromIndexes.d.mts +24 -0
- package/lib/core/transform/envelope/deriveWatchInputsFromIndexes.d.ts +24 -0
- package/lib/core/transform/envelope/deriveWatchInputsFromIndexes.js +84 -0
- package/lib/core/transform/envelope/deriveWatchInputsFromIndexes.js.map +1 -0
- package/lib/core/transform/envelope/deriveWatchInputsFromIndexes.mjs +82 -0
- package/lib/core/transform/envelope/deriveWatchInputsFromIndexes.mjs.map +1 -0
- package/lib/core/transform/envelope/envelopeDerivation.js +1 -0
- package/lib/core/transform/envelope/envelopeDerivation.js.map +1 -1
- package/lib/core/transform/envelope/envelopeDerivation.mjs +1 -0
- package/lib/core/transform/envelope/envelopeDerivation.mjs.map +1 -1
- package/lib/core/transform/envelope/envelopeGraphIndexes.d.cts +2 -1
- package/lib/core/transform/envelope/envelopeGraphIndexes.d.mts +2 -1
- package/lib/core/transform/envelope/envelopeGraphIndexes.d.ts +2 -1
- package/lib/core/transform/envelope/envelopeGraphIndexes.js +2 -1
- package/lib/core/transform/envelope/envelopeGraphIndexes.js.map +1 -1
- package/lib/core/transform/envelope/envelopeGraphIndexes.mjs +2 -1
- package/lib/core/transform/envelope/envelopeGraphIndexes.mjs.map +1 -1
- package/lib/core/transform/envelope/isVolatileFile.d.cts +2 -2
- package/lib/core/transform/envelope/isVolatileFile.d.mts +2 -2
- package/lib/core/transform/envelope/isVolatileFile.d.ts +2 -2
- package/lib/core/transform/envelope/isVolatileFile.js +1 -1
- package/lib/core/transform/envelope/isVolatileFile.js.map +1 -1
- package/lib/core/transform/envelope/isVolatileFile.mjs +1 -1
- package/lib/core/transform/envelope/isVolatileFile.mjs.map +1 -1
- package/lib/core/transform/envelope/selectFileDependencies.d.cts +4 -5
- package/lib/core/transform/envelope/selectFileDependencies.d.mts +4 -5
- package/lib/core/transform/envelope/selectFileDependencies.d.ts +4 -5
- package/lib/core/transform/envelope/selectFileDependencies.js +3 -10
- package/lib/core/transform/envelope/selectFileDependencies.js.map +1 -1
- package/lib/core/transform/envelope/selectFileDependencies.mjs +3 -10
- package/lib/core/transform/envelope/selectFileDependencies.mjs.map +1 -1
- package/lib/core/transform/envelope/selectGraphInputs.d.cts +2 -5
- package/lib/core/transform/envelope/selectGraphInputs.d.mts +2 -5
- package/lib/core/transform/envelope/selectGraphInputs.d.ts +2 -5
- package/lib/core/transform/envelope/selectGraphInputs.js +5 -4
- package/lib/core/transform/envelope/selectGraphInputs.js.map +1 -1
- package/lib/core/transform/envelope/selectGraphInputs.mjs +5 -4
- package/lib/core/transform/envelope/selectGraphInputs.mjs.map +1 -1
- package/lib/core/transform/envelope/selectHostInputs.d.cts +1 -1
- package/lib/core/transform/envelope/selectHostInputs.d.mts +1 -1
- package/lib/core/transform/envelope/selectHostInputs.d.ts +1 -1
- package/lib/core/transform/envelope/selectHostInputs.js +4 -1
- package/lib/core/transform/envelope/selectHostInputs.js.map +1 -1
- package/lib/core/transform/envelope/selectHostInputs.mjs +4 -1
- package/lib/core/transform/envelope/selectHostInputs.mjs.map +1 -1
- package/lib/core/transform/envelope/selectNotifiableAbsentInputs.d.cts +8 -7
- package/lib/core/transform/envelope/selectNotifiableAbsentInputs.d.mts +8 -7
- package/lib/core/transform/envelope/selectNotifiableAbsentInputs.d.ts +8 -7
- package/lib/core/transform/envelope/selectNotifiableAbsentInputs.js +11 -8
- package/lib/core/transform/envelope/selectNotifiableAbsentInputs.js.map +1 -1
- package/lib/core/transform/envelope/selectNotifiableAbsentInputs.mjs +11 -8
- package/lib/core/transform/envelope/selectNotifiableAbsentInputs.mjs.map +1 -1
- package/lib/core/transform/envelope/selectReachableEdges.d.cts +1 -1
- package/lib/core/transform/envelope/selectReachableEdges.d.mts +1 -1
- package/lib/core/transform/envelope/selectReachableEdges.d.ts +1 -1
- package/lib/core/transform/envelope/selectReachableEdges.js.map +1 -1
- package/lib/core/transform/envelope/selectReachableEdges.mjs.map +1 -1
- package/lib/core/transform/envelope/selectReachableSources.d.cts +1 -1
- package/lib/core/transform/envelope/selectReachableSources.d.mts +1 -1
- package/lib/core/transform/envelope/selectReachableSources.d.ts +1 -1
- package/lib/core/transform/envelope/selectReachableSources.js.map +1 -1
- package/lib/core/transform/envelope/selectReachableSources.mjs.map +1 -1
- package/lib/core/transform/envelope/selectResolutionCandidateInputs.d.cts +1 -6
- package/lib/core/transform/envelope/selectResolutionCandidateInputs.d.mts +1 -6
- package/lib/core/transform/envelope/selectResolutionCandidateInputs.d.ts +1 -6
- package/lib/core/transform/envelope/selectResolutionCandidateInputs.js +3 -6
- package/lib/core/transform/envelope/selectResolutionCandidateInputs.js.map +1 -1
- package/lib/core/transform/envelope/selectResolutionCandidateInputs.mjs +3 -6
- package/lib/core/transform/envelope/selectResolutionCandidateInputs.mjs.map +1 -1
- package/lib/core/transform/filesystem/userStateDirectory.d.cts +22 -4
- package/lib/core/transform/filesystem/userStateDirectory.d.mts +22 -4
- package/lib/core/transform/filesystem/userStateDirectory.d.ts +22 -4
- package/lib/core/transform/filesystem/userStateDirectory.js +37 -12
- package/lib/core/transform/filesystem/userStateDirectory.js.map +1 -1
- package/lib/core/transform/filesystem/userStateDirectory.mjs +37 -12
- package/lib/core/transform/filesystem/userStateDirectory.mjs.map +1 -1
- package/lib/core/transform/generation/TtscFailedGenerationValidation.d.cts +3 -0
- package/lib/core/transform/generation/TtscFailedGenerationValidation.d.mts +3 -0
- package/lib/core/transform/generation/TtscFailedGenerationValidation.d.ts +3 -0
- package/lib/core/transform/generation/captureTransformGeneration.js +51 -13
- package/lib/core/transform/generation/captureTransformGeneration.js.map +1 -1
- package/lib/core/transform/generation/captureTransformGeneration.mjs +51 -13
- package/lib/core/transform/generation/captureTransformGeneration.mjs.map +1 -1
- package/lib/core/transform/generation/createUnstableGenerationError.d.cts +5 -3
- package/lib/core/transform/generation/createUnstableGenerationError.d.mts +5 -3
- package/lib/core/transform/generation/createUnstableGenerationError.d.ts +5 -3
- package/lib/core/transform/generation/createUnstableGenerationError.js +21 -4
- package/lib/core/transform/generation/createUnstableGenerationError.js.map +1 -1
- package/lib/core/transform/generation/createUnstableGenerationError.mjs +21 -4
- package/lib/core/transform/generation/createUnstableGenerationError.mjs.map +1 -1
- package/lib/core/transform/generation/failedGenerationEnvironmentChanged.d.cts +5 -1
- package/lib/core/transform/generation/failedGenerationEnvironmentChanged.d.mts +5 -1
- package/lib/core/transform/generation/failedGenerationEnvironmentChanged.d.ts +5 -1
- package/lib/core/transform/generation/failedGenerationEnvironmentChanged.js +13 -1
- package/lib/core/transform/generation/failedGenerationEnvironmentChanged.js.map +1 -1
- package/lib/core/transform/generation/failedGenerationEnvironmentChanged.mjs +14 -2
- package/lib/core/transform/generation/failedGenerationEnvironmentChanged.mjs.map +1 -1
- package/lib/core/transform/inputs/hostInputRealpath.d.cts +9 -8
- package/lib/core/transform/inputs/hostInputRealpath.d.mts +9 -8
- package/lib/core/transform/inputs/hostInputRealpath.d.ts +9 -8
- package/lib/core/transform/inputs/hostInputRealpath.js +12 -8
- package/lib/core/transform/inputs/hostInputRealpath.js.map +1 -1
- package/lib/core/transform/inputs/hostInputRealpath.mjs +12 -8
- package/lib/core/transform/inputs/hostInputRealpath.mjs.map +1 -1
- package/lib/core/transform/inputs/sameHostInputRealpath.d.cts +3 -2
- package/lib/core/transform/inputs/sameHostInputRealpath.d.mts +3 -2
- package/lib/core/transform/inputs/sameHostInputRealpath.d.ts +3 -2
- package/lib/core/transform/inputs/sameHostInputRealpath.js +5 -2
- package/lib/core/transform/inputs/sameHostInputRealpath.js.map +1 -1
- package/lib/core/transform/inputs/sameHostInputRealpath.mjs +5 -2
- package/lib/core/transform/inputs/sameHostInputRealpath.mjs.map +1 -1
- package/lib/core/transform/session/claimSharedCompile.js +2 -0
- package/lib/core/transform/session/claimSharedCompile.js.map +1 -1
- package/lib/core/transform/session/claimSharedCompile.mjs +2 -0
- package/lib/core/transform/session/claimSharedCompile.mjs.map +1 -1
- package/lib/core/transform/transformTtsc.d.cts +1 -1
- package/lib/core/transform/transformTtsc.d.mts +1 -1
- package/lib/core/transform/transformTtsc.d.ts +1 -1
- package/lib/core/transform/transformTtsc.js +26 -8
- package/lib/core/transform/transformTtsc.js.map +1 -1
- package/lib/core/transform/transformTtsc.mjs +26 -8
- package/lib/core/transform/transformTtsc.mjs.map +1 -1
- package/lib/core/transform/tsconfig/createTransformScratchDirectory.d.cts +11 -9
- package/lib/core/transform/tsconfig/createTransformScratchDirectory.d.mts +11 -9
- package/lib/core/transform/tsconfig/createTransformScratchDirectory.d.ts +11 -9
- package/lib/core/transform/tsconfig/createTransformScratchDirectory.js +31 -32
- package/lib/core/transform/tsconfig/createTransformScratchDirectory.js.map +1 -1
- package/lib/core/transform/tsconfig/createTransformScratchDirectory.mjs +31 -32
- package/lib/core/transform/tsconfig/createTransformScratchDirectory.mjs.map +1 -1
- package/lib/core/transform/validation/TtscGenerationProof.d.cts +19 -2
- package/lib/core/transform/validation/TtscGenerationProof.d.mts +19 -2
- package/lib/core/transform/validation/TtscGenerationProof.d.ts +19 -2
- package/lib/core/transform/validation/TtscGenerationProof.js +41 -2
- package/lib/core/transform/validation/TtscGenerationProof.js.map +1 -1
- package/lib/core/transform/validation/TtscGenerationProof.mjs +42 -3
- package/lib/core/transform/validation/TtscGenerationProof.mjs.map +1 -1
- package/lib/core/transform/validation/captureUniversalHostInputValidation.js +9 -0
- package/lib/core/transform/validation/captureUniversalHostInputValidation.js.map +1 -1
- package/lib/core/transform/validation/captureUniversalHostInputValidation.mjs +10 -1
- package/lib/core/transform/validation/captureUniversalHostInputValidation.mjs.map +1 -1
- package/lib/core/transform/validation/matchesCachedExternalInputs.d.cts +6 -2
- package/lib/core/transform/validation/matchesCachedExternalInputs.d.mts +6 -2
- package/lib/core/transform/validation/matchesCachedExternalInputs.d.ts +6 -2
- package/lib/core/transform/validation/matchesCachedExternalInputs.js +8 -2
- package/lib/core/transform/validation/matchesCachedExternalInputs.js.map +1 -1
- package/lib/core/transform/validation/matchesCachedExternalInputs.mjs +8 -2
- package/lib/core/transform/validation/matchesCachedExternalInputs.mjs.map +1 -1
- package/lib/core/transform/validation/matchesCompleteInputSnapshot.d.cts +8 -7
- package/lib/core/transform/validation/matchesCompleteInputSnapshot.d.mts +8 -7
- package/lib/core/transform/validation/matchesCompleteInputSnapshot.d.ts +8 -7
- package/lib/core/transform/validation/matchesCompleteInputSnapshot.js +19 -9
- package/lib/core/transform/validation/matchesCompleteInputSnapshot.js.map +1 -1
- package/lib/core/transform/validation/matchesCompleteInputSnapshot.mjs +19 -9
- package/lib/core/transform/validation/matchesCompleteInputSnapshot.mjs.map +1 -1
- package/lib/core/transform/validation/matchesExternalInputRealpaths.d.cts +7 -4
- package/lib/core/transform/validation/matchesExternalInputRealpaths.d.mts +7 -4
- package/lib/core/transform/validation/matchesExternalInputRealpaths.d.ts +7 -4
- package/lib/core/transform/validation/matchesExternalInputRealpaths.js +9 -4
- package/lib/core/transform/validation/matchesExternalInputRealpaths.js.map +1 -1
- package/lib/core/transform/validation/matchesExternalInputRealpaths.mjs +9 -4
- package/lib/core/transform/validation/matchesExternalInputRealpaths.mjs.map +1 -1
- package/lib/core/transform/validation/matchesNarrowPersistentInputs.d.cts +5 -2
- package/lib/core/transform/validation/matchesNarrowPersistentInputs.d.mts +5 -2
- package/lib/core/transform/validation/matchesNarrowPersistentInputs.d.ts +5 -2
- package/lib/core/transform/validation/matchesNarrowPersistentInputs.js +62 -2
- package/lib/core/transform/validation/matchesNarrowPersistentInputs.js.map +1 -1
- package/lib/core/transform/validation/matchesNarrowPersistentInputs.mjs +62 -2
- package/lib/core/transform/validation/matchesNarrowPersistentInputs.mjs.map +1 -1
- package/lib/core/transform/validation/nativeInputPredicatesHold.d.cts +7 -6
- package/lib/core/transform/validation/nativeInputPredicatesHold.d.mts +7 -6
- package/lib/core/transform/validation/nativeInputPredicatesHold.d.ts +7 -6
- package/lib/core/transform/validation/nativeInputPredicatesHold.js +16 -6
- package/lib/core/transform/validation/nativeInputPredicatesHold.js.map +1 -1
- package/lib/core/transform/validation/nativeInputPredicatesHold.mjs +16 -6
- package/lib/core/transform/validation/nativeInputPredicatesHold.mjs.map +1 -1
- package/lib/core/transform/watch/RECOVERY_TREE_DIGEST.d.cts +8 -0
- package/lib/core/transform/watch/RECOVERY_TREE_DIGEST.d.mts +8 -0
- package/lib/core/transform/watch/RECOVERY_TREE_DIGEST.d.ts +8 -0
- package/lib/core/transform/watch/RECOVERY_TREE_DIGEST.js +12 -0
- package/lib/core/transform/watch/RECOVERY_TREE_DIGEST.js.map +1 -0
- package/lib/core/transform/watch/RECOVERY_TREE_DIGEST.mjs +10 -0
- package/lib/core/transform/watch/RECOVERY_TREE_DIGEST.mjs.map +1 -0
- package/lib/core/transform/watch/TtscProjectRegistration.d.cts +3 -0
- package/lib/core/transform/watch/TtscProjectRegistration.d.mts +3 -0
- package/lib/core/transform/watch/TtscProjectRegistration.d.ts +3 -0
- package/lib/core/transform/watch/TtscProjectRegistration.js +3 -0
- package/lib/core/transform/watch/TtscProjectRegistration.js.map +1 -0
- package/lib/core/transform/watch/TtscProjectRegistration.mjs +2 -0
- package/lib/core/transform/watch/TtscProjectRegistration.mjs.map +1 -0
- package/lib/core/transform/watch/TtscTransformHooks.d.cts +33 -12
- package/lib/core/transform/watch/TtscTransformHooks.d.mts +33 -12
- package/lib/core/transform/watch/TtscTransformHooks.d.ts +33 -12
- package/lib/core/transform/watch/TtscTransformHooks.js +3 -0
- package/lib/core/transform/watch/TtscTransformHooks.js.map +1 -0
- package/lib/core/transform/watch/TtscTransformHooks.mjs +2 -0
- package/lib/core/transform/watch/TtscTransformHooks.mjs.map +1 -0
- package/lib/core/transform/watch/TtscWatchInputEvidence.d.cts +3 -0
- package/lib/core/transform/watch/TtscWatchInputEvidence.d.mts +3 -0
- package/lib/core/transform/watch/TtscWatchInputEvidence.d.ts +3 -0
- package/lib/core/transform/watch/TtscWorkspaceWatchEvidence.d.cts +14 -0
- package/lib/core/transform/watch/TtscWorkspaceWatchEvidence.d.mts +14 -0
- package/lib/core/transform/watch/TtscWorkspaceWatchEvidence.d.ts +14 -0
- package/lib/core/transform/watch/captureRecoveryTreeDigest.d.cts +26 -0
- package/lib/core/transform/watch/captureRecoveryTreeDigest.d.mts +26 -0
- package/lib/core/transform/watch/captureRecoveryTreeDigest.d.ts +26 -0
- package/lib/core/transform/watch/captureRecoveryTreeDigest.js +54 -0
- package/lib/core/transform/watch/captureRecoveryTreeDigest.js.map +1 -0
- package/lib/core/transform/watch/captureRecoveryTreeDigest.mjs +52 -0
- package/lib/core/transform/watch/captureRecoveryTreeDigest.mjs.map +1 -0
- package/lib/core/transform/watch/evidencedWatchInput.js +6 -0
- package/lib/core/transform/watch/evidencedWatchInput.js.map +1 -1
- package/lib/core/transform/watch/evidencedWatchInput.mjs +6 -0
- package/lib/core/transform/watch/evidencedWatchInput.mjs.map +1 -1
- package/lib/core/transform/watch/handWatchInputs.d.cts +4 -4
- package/lib/core/transform/watch/handWatchInputs.d.mts +4 -4
- package/lib/core/transform/watch/handWatchInputs.d.ts +4 -4
- package/lib/core/transform/watch/handWatchInputs.js +21 -5
- package/lib/core/transform/watch/handWatchInputs.js.map +1 -1
- package/lib/core/transform/watch/handWatchInputs.mjs +21 -5
- package/lib/core/transform/watch/handWatchInputs.mjs.map +1 -1
- package/lib/core/transform/watch/notifyFailedGenerationInputs.d.cts +8 -1
- package/lib/core/transform/watch/notifyFailedGenerationInputs.d.mts +8 -1
- package/lib/core/transform/watch/notifyFailedGenerationInputs.d.ts +8 -1
- package/lib/core/transform/watch/notifyFailedGenerationInputs.js +51 -9
- package/lib/core/transform/watch/notifyFailedGenerationInputs.js.map +1 -1
- package/lib/core/transform/watch/notifyFailedGenerationInputs.mjs +51 -9
- package/lib/core/transform/watch/notifyFailedGenerationInputs.mjs.map +1 -1
- package/lib/core/transform/watch/notifyProjectRecord.js +55 -20
- package/lib/core/transform/watch/notifyProjectRecord.js.map +1 -1
- package/lib/core/transform/watch/notifyProjectRecord.mjs +55 -20
- package/lib/core/transform/watch/notifyProjectRecord.mjs.map +1 -1
- package/lib/core/transform/watch/notifyRejectedGenerationInputs.js +20 -10
- package/lib/core/transform/watch/notifyRejectedGenerationInputs.js.map +1 -1
- package/lib/core/transform/watch/notifyRejectedGenerationInputs.mjs +20 -10
- package/lib/core/transform/watch/notifyRejectedGenerationInputs.mjs.map +1 -1
- package/lib/core/transform/watch/notifyVolatileDelivery.d.cts +4 -6
- package/lib/core/transform/watch/notifyVolatileDelivery.d.mts +4 -6
- package/lib/core/transform/watch/notifyVolatileDelivery.d.ts +4 -6
- package/lib/core/transform/watch/notifyVolatileDelivery.js +12 -11
- package/lib/core/transform/watch/notifyVolatileDelivery.js.map +1 -1
- package/lib/core/transform/watch/notifyVolatileDelivery.mjs +12 -11
- package/lib/core/transform/watch/notifyVolatileDelivery.mjs.map +1 -1
- package/lib/core/transform/watch/notifyWatchInputs.d.cts +6 -3
- package/lib/core/transform/watch/notifyWatchInputs.d.mts +6 -3
- package/lib/core/transform/watch/notifyWatchInputs.d.ts +6 -3
- package/lib/core/transform/watch/notifyWatchInputs.js +66 -14
- package/lib/core/transform/watch/notifyWatchInputs.js.map +1 -1
- package/lib/core/transform/watch/notifyWatchInputs.mjs +66 -14
- package/lib/core/transform/watch/notifyWatchInputs.mjs.map +1 -1
- package/lib/core/transform/watch/prepareProjectRecordDirectories.d.cts +4 -5
- package/lib/core/transform/watch/prepareProjectRecordDirectories.d.mts +4 -5
- package/lib/core/transform/watch/prepareProjectRecordDirectories.d.ts +4 -5
- package/lib/core/transform/watch/prepareProjectRecordDirectories.js +9 -16
- package/lib/core/transform/watch/prepareProjectRecordDirectories.js.map +1 -1
- package/lib/core/transform/watch/prepareProjectRecordDirectories.mjs +9 -16
- package/lib/core/transform/watch/prepareProjectRecordDirectories.mjs.map +1 -1
- package/lib/core/transform/watch/projectRecordDirectories.d.cts +18 -0
- package/lib/core/transform/watch/projectRecordDirectories.d.mts +18 -0
- package/lib/core/transform/watch/projectRecordDirectories.d.ts +18 -0
- package/lib/core/transform/watch/projectRecordDirectories.js +34 -0
- package/lib/core/transform/watch/projectRecordDirectories.js.map +1 -0
- package/lib/core/transform/watch/projectRecordDirectories.mjs +32 -0
- package/lib/core/transform/watch/projectRecordDirectories.mjs.map +1 -0
- package/lib/core/transform/watch/recordedDependencyWitnesses.js +7 -7
- package/lib/core/transform/watch/recordedDependencyWitnesses.js.map +1 -1
- package/lib/core/transform/watch/recordedDependencyWitnesses.mjs +7 -7
- package/lib/core/transform/watch/recordedDependencyWitnesses.mjs.map +1 -1
- package/lib/core/transform/watch/watchInputEvidenceMatchesBaseline.js +2 -1
- package/lib/core/transform/watch/watchInputEvidenceMatchesBaseline.js.map +1 -1
- package/lib/core/transform/watch/watchInputEvidenceMatchesBaseline.mjs +2 -1
- package/lib/core/transform/watch/watchInputEvidenceMatchesBaseline.mjs.map +1 -1
- package/lib/core/transform/watch/watchInputEvidenceMatchesDisk.js +7 -0
- package/lib/core/transform/watch/watchInputEvidenceMatchesDisk.js.map +1 -1
- package/lib/core/transform/watch/watchInputEvidenceMatchesDisk.mjs +7 -0
- package/lib/core/transform/watch/watchInputEvidenceMatchesDisk.mjs.map +1 -1
- package/lib/core/unplugin.js +43 -27
- package/lib/core/unplugin.js.map +1 -1
- package/lib/core/unplugin.mjs +43 -27
- package/lib/core/unplugin.mjs.map +1 -1
- package/lib/core/vite/ViteServeInputWatch.d.cts +17 -0
- package/lib/core/vite/ViteServeInputWatch.d.mts +17 -0
- package/lib/core/vite/ViteServeInputWatch.d.ts +17 -0
- package/lib/core/vite/createViteServeInputWatch.d.cts +5 -0
- package/lib/core/vite/createViteServeInputWatch.d.mts +5 -0
- package/lib/core/vite/createViteServeInputWatch.d.ts +5 -0
- package/lib/core/vite/createViteServeInputWatch.js +86 -10
- package/lib/core/vite/createViteServeInputWatch.js.map +1 -1
- package/lib/core/vite/createViteServeInputWatch.mjs +86 -10
- package/lib/core/vite/createViteServeInputWatch.mjs.map +1 -1
- package/lib/core/vite/createViteServeWatchHooks.d.cts +6 -5
- package/lib/core/vite/createViteServeWatchHooks.d.mts +6 -5
- package/lib/core/vite/createViteServeWatchHooks.d.ts +6 -5
- package/lib/core/vite/createViteServeWatchHooks.js +10 -4
- package/lib/core/vite/createViteServeWatchHooks.js.map +1 -1
- package/lib/core/vite/createViteServeWatchHooks.mjs +10 -4
- package/lib/core/vite/createViteServeWatchHooks.mjs.map +1 -1
- package/package.json +3 -3
- package/src/core/bridge/HostWatchBridge.ts +2 -0
- package/src/core/bridge/MANAGED_PROJECT_RECORDS.ts +2 -0
- package/src/core/bridge/TtscProjectRecord.ts +9 -0
- package/src/core/bridge/fallbackRecordStorage.ts +104 -0
- package/src/core/bridge/fallbackToolDirectory.ts +22 -38
- package/src/core/bridge/fallbackToolDirectoryLocation.ts +40 -0
- package/src/core/bridge/hostToolDirectory.ts +14 -47
- package/src/core/bridge/openHostWatchBridge.ts +48 -6
- package/src/core/bridge/prepareProjectRecordDirectory.ts +134 -0
- package/src/core/bridge/privateProjectRecordAvailable.ts +25 -0
- package/src/core/bridge/projectRecordMoved.ts +7 -0
- package/src/core/bridge/projectRecordWatchInputs.ts +6 -0
- package/src/core/bridge/readProjectRecordFile.ts +28 -1
- package/src/core/bridge/refreshProjectRecordFile.ts +40 -7
- package/src/core/bridge/refreshProjectRecordFiles.ts +44 -12
- package/src/core/bridge/registerProjectRecord.ts +2 -0
- package/src/core/bridge/signalProjectRecordFile.ts +25 -5
- package/src/core/bridge/writeProjectRecordFile.ts +10 -3
- package/src/core/esbuild/createEsbuildOptions.ts +9 -10
- package/src/core/farm/createFarmRecordUpdates.ts +167 -0
- package/src/core/farm/farmPersistentCacheWithoutRecords.ts +25 -55
- package/src/core/farm/farmRecordFallback.ts +25 -20
- package/src/core/next/next.ts +5 -3
- package/src/core/observer/InputCondition.ts +7 -0
- package/src/core/observer/InputObserverChange.ts +3 -0
- package/src/core/observer/createInputObserver.ts +186 -25
- package/src/core/observer/ttscWriteDirectories.ts +56 -0
- package/src/core/rollup/TtscRollupDelivery.ts +2 -0
- package/src/core/rollup/createRollupCachedModuleProof.ts +65 -33
- package/src/core/rollup/rollupDeliveryOptions.ts +7 -4
- package/src/core/transform/cache/TtscCachedProjectTransform.ts +6 -0
- package/src/core/transform/cache/selectCachedGenerationAction.ts +9 -4
- package/src/core/transform/deliverCachedTransform.ts +1 -0
- package/src/core/transform/envelope/TtscEnvelopeDerivation.ts +6 -17
- package/src/core/transform/envelope/collectDeclaredIdentities.ts +1 -1
- package/src/core/transform/envelope/createEnvelopeKeyIndex.ts +1 -1
- package/src/core/transform/envelope/declaresCompleteDependencies.ts +17 -7
- package/src/core/transform/envelope/derivationIdentity.ts +1 -1
- package/src/core/transform/envelope/deriveWatchInputs.ts +10 -64
- package/src/core/transform/envelope/deriveWatchInputsFromIndexes.ts +117 -0
- package/src/core/transform/envelope/envelopeDerivation.ts +1 -0
- package/src/core/transform/envelope/envelopeGraphIndexes.ts +2 -1
- package/src/core/transform/envelope/isVolatileFile.ts +12 -3
- package/src/core/transform/envelope/selectFileDependencies.ts +11 -14
- package/src/core/transform/envelope/selectGraphInputs.ts +13 -10
- package/src/core/transform/envelope/selectHostInputs.ts +11 -2
- package/src/core/transform/envelope/selectNotifiableAbsentInputs.ts +13 -8
- package/src/core/transform/envelope/selectReachableEdges.ts +2 -2
- package/src/core/transform/envelope/selectReachableSources.ts +2 -2
- package/src/core/transform/envelope/selectResolutionCandidateInputs.ts +9 -15
- package/src/core/transform/filesystem/userStateDirectory.ts +46 -15
- package/src/core/transform/generation/TtscFailedGenerationValidation.ts +5 -0
- package/src/core/transform/generation/captureTransformGeneration.ts +64 -22
- package/src/core/transform/generation/createUnstableGenerationError.ts +24 -4
- package/src/core/transform/generation/failedGenerationEnvironmentChanged.ts +18 -2
- package/src/core/transform/inputs/hostInputRealpath.ts +13 -8
- package/src/core/transform/inputs/sameHostInputRealpath.ts +4 -2
- package/src/core/transform/session/claimSharedCompile.ts +2 -0
- package/src/core/transform/transformTtsc.ts +28 -7
- package/src/core/transform/tsconfig/createTransformScratchDirectory.ts +36 -31
- package/src/core/transform/validation/TtscGenerationProof.ts +57 -2
- package/src/core/transform/validation/captureUniversalHostInputValidation.ts +12 -0
- package/src/core/transform/validation/matchesCachedExternalInputs.ts +6 -1
- package/src/core/transform/validation/matchesCompleteInputSnapshot.ts +23 -9
- package/src/core/transform/validation/matchesExternalInputRealpaths.ts +7 -3
- package/src/core/transform/validation/matchesNarrowPersistentInputs.ts +81 -2
- package/src/core/transform/validation/nativeInputPredicatesHold.ts +15 -6
- package/src/core/transform/watch/RECOVERY_TREE_DIGEST.ts +12 -0
- package/src/core/transform/watch/TtscProjectRegistration.ts +4 -0
- package/src/core/transform/watch/TtscTransformHooks.ts +40 -12
- package/src/core/transform/watch/TtscWatchInputEvidence.ts +3 -0
- package/src/core/transform/watch/TtscWorkspaceWatchEvidence.ts +17 -0
- package/src/core/transform/watch/captureRecoveryTreeDigest.ts +58 -0
- package/src/core/transform/watch/evidencedWatchInput.ts +7 -0
- package/src/core/transform/watch/handWatchInputs.ts +21 -5
- package/src/core/transform/watch/notifyFailedGenerationInputs.ts +66 -10
- package/src/core/transform/watch/notifyProjectRecord.ts +68 -25
- package/src/core/transform/watch/notifyRejectedGenerationInputs.ts +22 -9
- package/src/core/transform/watch/notifyVolatileDelivery.ts +7 -6
- package/src/core/transform/watch/notifyWatchInputs.ts +112 -14
- package/src/core/transform/watch/prepareProjectRecordDirectories.ts +14 -16
- package/src/core/transform/watch/projectRecordDirectories.ts +33 -0
- package/src/core/transform/watch/recordedDependencyWitnesses.ts +8 -9
- package/src/core/transform/watch/watchInputEvidenceMatchesBaseline.ts +2 -1
- package/src/core/transform/watch/watchInputEvidenceMatchesDisk.ts +7 -0
- package/src/core/unplugin.ts +72 -42
- package/src/core/vite/ViteServeInputWatch.ts +24 -0
- package/src/core/vite/createViteServeInputWatch.ts +98 -9
- package/src/core/vite/createViteServeWatchHooks.ts +15 -6
- package/lib/core/bridge/projectRecordDirectoryWritable.d.cts +0 -36
- package/lib/core/bridge/projectRecordDirectoryWritable.d.mts +0 -36
- package/lib/core/bridge/projectRecordDirectoryWritable.d.ts +0 -36
- package/lib/core/bridge/projectRecordDirectoryWritable.js +0 -65
- package/lib/core/bridge/projectRecordDirectoryWritable.js.map +0 -1
- package/lib/core/bridge/projectRecordDirectoryWritable.mjs +0 -63
- package/lib/core/bridge/projectRecordDirectoryWritable.mjs.map +0 -1
- package/src/core/bridge/projectRecordDirectoryWritable.ts +0 -61
|
@@ -1,20 +1,23 @@
|
|
|
1
|
+
import { realpathHostInput } from "ttsc/plugin-source";
|
|
2
|
+
|
|
1
3
|
import { DEFAULT_FILESYSTEM_OPERATIONS } from "../filesystem/DEFAULT_FILESYSTEM_OPERATIONS";
|
|
2
4
|
import type { TtscTransformFilesystemOperations } from "../filesystem/TtscTransformFilesystemOperations";
|
|
3
5
|
|
|
4
6
|
/**
|
|
5
|
-
* Read the physical
|
|
6
|
-
*
|
|
7
|
-
*
|
|
7
|
+
* Read the physical identity selected by a host-input path. The native resolver
|
|
8
|
+
* shares the compiler's encoding for POSIX byte paths. A custom resolver
|
|
9
|
+
* supplies its own identity. Resolution failure returns null.
|
|
8
10
|
*
|
|
9
11
|
* @evidence contracts/common.md#principled-implementation Successful physical resolution and failure remain distinct through string and null without applying the compiler's lexical fallback.
|
|
10
|
-
* @evidence contracts/common.md#clear-and-simple-design
|
|
12
|
+
* @evidence contracts/common.md#clear-and-simple-design The compiler helper owns native witness encoding, the supplied resolver owns custom observations, and callers own identity comparison.
|
|
11
13
|
* @evidence contracts/common.md#prohibited-implementation-shortcuts Failed native resolution is not replaced with guessed lexical identity or a known-input target.
|
|
12
|
-
* @evidence contracts/common.md#meaningful-documentation Native prose states
|
|
13
|
-
* @evidence contracts/portability.md#os-neutral-implementation
|
|
14
|
+
* @evidence contracts/common.md#meaningful-documentation Native prose states the native witness, custom identity and unresolved semantics.
|
|
15
|
+
* @evidence contracts/portability.md#os-neutral-implementation Native observations use the compiler's byte-preserving resolver. Custom views keep their realpath capability and spelling policy.
|
|
14
16
|
* @evidenceExclude contracts/performance.md#bound-retention-and-release-resources The call returns before the function does; no handle is retained.
|
|
15
17
|
* @evidence contracts/performance.md#efficient-algorithms
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
+
* The native helper checks missing paths by lstat and resolves present paths
|
|
19
|
+
* with byte preservation. The custom view supplies one resolver call. Both
|
|
20
|
+
* costs depend on the path components and native link targets.
|
|
18
21
|
* @evidenceExclude contracts/performance.md#reuse-equivalent-work
|
|
19
22
|
* This observes one current target. Identity contexts and enclosing generation
|
|
20
23
|
* validators own any sharing and its observation lifetime.
|
|
@@ -23,6 +26,8 @@ export function hostInputRealpath(
|
|
|
23
26
|
file: string,
|
|
24
27
|
filesystem: TtscTransformFilesystemOperations = DEFAULT_FILESYSTEM_OPERATIONS,
|
|
25
28
|
): string | null {
|
|
29
|
+
if (filesystem.realpath === DEFAULT_FILESYSTEM_OPERATIONS.realpath)
|
|
30
|
+
return realpathHostInput(file);
|
|
26
31
|
try {
|
|
27
32
|
return filesystem.realpath(file);
|
|
28
33
|
} catch {
|
|
@@ -5,9 +5,10 @@ import { pathIdentityKey } from "../filesystem/pathIdentityKey";
|
|
|
5
5
|
/**
|
|
6
6
|
* Compare reported physical targets through the supplied filesystem identity
|
|
7
7
|
* context. Undefined recorded evidence never matches; two failed resolutions
|
|
8
|
-
* represented by null do match.
|
|
8
|
+
* represented by null do match. Opaque POSIX byte witnesses compare by their
|
|
9
|
+
* exact representation without being passed to native path operations.
|
|
9
10
|
*
|
|
10
|
-
* @evidence contracts/common.md#principled-implementation Absence, resolution failure and resolved identity are distinguished before comparing
|
|
11
|
+
* @evidence contracts/common.md#principled-implementation Absence, resolution failure and resolved identity are distinguished before comparing path keys or exact reserved byte witnesses.
|
|
11
12
|
* @evidence contracts/common.md#clear-and-simple-design One shared identity context owns native equivalence; this adapter handles only optional-result states and key equality.
|
|
12
13
|
* @evidence contracts/common.md#prohibited-implementation-shortcuts Realpath equality does not rely on blanket lowercase, removed separators or consumer-specific spelling exceptions.
|
|
13
14
|
* @evidence contracts/common.md#meaningful-documentation Native prose states undefined and null meaning and separates comparison from rewriting, with a blank acknowledgment separator under documentation guidance.
|
|
@@ -27,6 +28,7 @@ export function sameHostInputRealpath(
|
|
|
27
28
|
): boolean {
|
|
28
29
|
if (left === undefined || (left === null) !== (right === null)) return false;
|
|
29
30
|
if (left === null || right === null) return true;
|
|
31
|
+
if (left.includes("\0") || right.includes("\0")) return left === right;
|
|
30
32
|
return (
|
|
31
33
|
pathIdentityKey(left, identities) === pathIdentityKey(right, identities)
|
|
32
34
|
);
|
|
@@ -541,6 +541,8 @@ function isPublicationResult(value: unknown): boolean {
|
|
|
541
541
|
// certify cross-worker reuse. Unsupported marker shapes are not ignored.
|
|
542
542
|
if (
|
|
543
543
|
value.observationsComplete !== undefined ||
|
|
544
|
+
value.workspaceReplayRequired !== undefined ||
|
|
545
|
+
value.workspaceInputs !== undefined ||
|
|
544
546
|
(value.hostInputProofFailures !== undefined &&
|
|
545
547
|
(!isPublicationRecord(value.hostInputProofFailures) ||
|
|
546
548
|
Object.keys(value.hostInputProofFailures).length !== 0))
|
|
@@ -9,6 +9,7 @@ import { TRANSFORM_CACHE_CASE_POLICIES } from "./cache/TRANSFORM_CACHE_CASE_POLI
|
|
|
9
9
|
import { TRANSFORM_CACHE_DEPENDENCY_WITNESSES } from "./cache/TRANSFORM_CACHE_DEPENDENCY_WITNESSES";
|
|
10
10
|
import { TRANSFORM_CACHE_MEMBERSHIP_POLICIES } from "./cache/TRANSFORM_CACHE_MEMBERSHIP_POLICIES";
|
|
11
11
|
import { TRANSFORM_RESULT_FILESYSTEM } from "./cache/TRANSFORM_RESULT_FILESYSTEM";
|
|
12
|
+
import type { TtscCachedProjectTransform } from "./cache/TtscCachedProjectTransform";
|
|
12
13
|
import type { TtscTransformCache } from "./cache/TtscTransformCache";
|
|
13
14
|
import { awaitOrEvict } from "./cache/awaitOrEvict";
|
|
14
15
|
import { createTransformCacheKey } from "./cache/createTransformCacheKey";
|
|
@@ -38,6 +39,9 @@ import { notifyRejectedGenerationInputs } from "./watch/notifyRejectedGeneration
|
|
|
38
39
|
import { prepareProjectRecordDirectories } from "./watch/prepareProjectRecordDirectories";
|
|
39
40
|
import { recordedDependencyWitnesses } from "./watch/recordedDependencyWitnesses";
|
|
40
41
|
|
|
42
|
+
/** Exact captures still available to join before they settle. */
|
|
43
|
+
const PENDING_CAPTURES = new WeakSet<Promise<TtscCachedProjectTransform>>();
|
|
44
|
+
|
|
41
45
|
/**
|
|
42
46
|
* Apply the ttsc plugin transform to a single source file.
|
|
43
47
|
*
|
|
@@ -71,7 +75,7 @@ import { recordedDependencyWitnesses } from "./watch/recordedDependencyWitnesses
|
|
|
71
75
|
* @param hooks - Optional adapter callbacks; see {@link TtscTransformHooks}.
|
|
72
76
|
* Dependency notifications fire on cache hits too; watch registrations are
|
|
73
77
|
* per build, not per compilation.
|
|
74
|
-
* @evidence contracts/common.md#principled-implementation Project selection and generation-qualified admission preserve compiler disk authority; preparation shares selection, keys, capture and input proofs with delivery, while host effects and first-delivery permission remain exclusive to actual delivery. Fresh-only success
|
|
78
|
+
* @evidence contracts/common.md#principled-implementation Project selection and generation-qualified admission preserve compiler disk authority; preparation shares selection, keys, capture and input proofs with delivery, while host effects and first-delivery permission remain exclusive to actual delivery. An unregistered caller can join an exact pending capture without granting reuse of settled workspace-restricted output. Fresh-only success requires an explicit nonwatching lifecycle, coherent project declaration and supported host-cache withdrawal.
|
|
75
79
|
* @evidence contracts/common.md#clear-and-simple-design One coordinator mode shares project selection, admission, compilation and output selection between preparation and delivery; dedicated owners retain proof and lifetime internals, and delivery alone performs host notification.
|
|
76
80
|
* @evidence contracts/common.md#prohibited-implementation-shortcuts Wrapper modules cannot poison source baselines. Preparation skips handoff rather than postcompile proof, and superseded preparation stops without reviving withdrawn generations. Incomplete local results share only explicitly nonwatching first deliveries in their exact pass; unknown/watching lifecycles or unsupported withdrawal reject and evict without invented persistent records or dependency closure.
|
|
77
81
|
* @evidence contracts/common.md#meaningful-documentation Native paragraphs and argument tags explain project scope, no-transform outcomes, cache epochs and per-build notifications; coordinator prose identifies delivery-only effects and postpreparation admission, with maintained invalidation reference context.
|
|
@@ -225,6 +229,7 @@ async function runTransformTtsc(
|
|
|
225
229
|
}
|
|
226
230
|
}
|
|
227
231
|
if (transformed !== undefined) {
|
|
232
|
+
const joinedCapture = PENDING_CAPTURES.has(transformed);
|
|
228
233
|
const cached = await awaitOrEvict(cache, key, transformed).catch(
|
|
229
234
|
(rejection: unknown) => {
|
|
230
235
|
if (!preparing)
|
|
@@ -258,18 +263,26 @@ async function runTransformTtsc(
|
|
|
258
263
|
continue;
|
|
259
264
|
}
|
|
260
265
|
}
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
266
|
+
const grouped = hooks?.watchGeneration !== undefined;
|
|
267
|
+
let proof =
|
|
268
|
+
grouped && epoch === undefined
|
|
269
|
+
? TtscGenerationProof.currentWatch(cached, file)
|
|
270
|
+
: undefined;
|
|
271
|
+
if (proof === undefined) {
|
|
272
|
+
await TtscGenerationProof.prepare(cached, file, epoch);
|
|
273
|
+
if (cache?.get(key) !== transformed) {
|
|
274
|
+
if (preparing) return undefined;
|
|
275
|
+
continue;
|
|
276
|
+
}
|
|
277
|
+
proof = TtscGenerationProof.create(cached, file, epoch, grouped);
|
|
265
278
|
}
|
|
266
279
|
// No await between this observation and synchronous admission.
|
|
267
|
-
const proof = TtscGenerationProof.create(cached, file, epoch);
|
|
268
280
|
const action = selectCachedGenerationAction({
|
|
269
281
|
proof,
|
|
270
282
|
cache,
|
|
271
283
|
cached,
|
|
272
284
|
epoch,
|
|
285
|
+
joinedCapture,
|
|
273
286
|
file,
|
|
274
287
|
generation: transformed,
|
|
275
288
|
key,
|
|
@@ -341,7 +354,15 @@ async function runTransformTtsc(
|
|
|
341
354
|
: (TRANSFORM_CACHE_DEPENDENCY_WITNESSES.get(cache)?.get(key) ??
|
|
342
355
|
recordedDependencyWitnesses(hooks?.project, tsconfig)),
|
|
343
356
|
});
|
|
344
|
-
cache
|
|
357
|
+
if (cache !== undefined) {
|
|
358
|
+
const pending = transformed;
|
|
359
|
+
PENDING_CAPTURES.add(pending);
|
|
360
|
+
const settled = (): void => {
|
|
361
|
+
PENDING_CAPTURES.delete(pending);
|
|
362
|
+
};
|
|
363
|
+
void pending.then(settled, settled);
|
|
364
|
+
cache.set(key, pending);
|
|
365
|
+
}
|
|
345
366
|
}
|
|
346
367
|
const generation = transformed;
|
|
347
368
|
const cached = await awaitOrEvict(cache, key, generation).catch(
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import fs from "node:fs";
|
|
2
|
-
import os from "node:os";
|
|
3
2
|
import path from "node:path";
|
|
3
|
+
import { systemTempOutsideProject } from "ttsc/internal/system-temp";
|
|
4
4
|
|
|
5
5
|
import { DEFAULT_FILESYSTEM_OPERATIONS } from "../filesystem/DEFAULT_FILESYSTEM_OPERATIONS";
|
|
6
6
|
import type { TtscTransformFilesystemOperations } from "../filesystem/TtscTransformFilesystemOperations";
|
|
@@ -9,20 +9,22 @@ import { pathIsWithin } from "../filesystem/pathIsWithin";
|
|
|
9
9
|
/**
|
|
10
10
|
* Create compiler scratch storage outside the project snapshot and watchers.
|
|
11
11
|
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
12
|
+
* The SDK qualifies system temporary parents against project ancestry and ends
|
|
13
|
+
* with the installation's private `node_modules/.cache/ttsc/temp`. The adapter
|
|
14
|
+
* also checks the current project's lexical worktree, which admits only that
|
|
15
|
+
* private directory inside the project. The created child's postflight physical
|
|
16
|
+
* address is checked again and returned, avoiding reuse of the candidate's
|
|
17
|
+
* known lexical parent alias. These path observations do not pin directory
|
|
18
|
+
* handles or rule out later native replacement. Failed candidates are skipped
|
|
19
|
+
* only after their owned empty child is removed.
|
|
18
20
|
*
|
|
19
|
-
* @evidence contracts/common.md#principled-implementation Preflight and postflight containment reject observed scratch addresses inside the project; returning the checked child spelling avoids knowingly reusing an unresolved parent alias, without certifying later topology cannot change.
|
|
21
|
+
* @evidence contracts/common.md#principled-implementation Preflight and postflight containment reject observed scratch addresses inside the project other than the SDK-verified installation private directory; returning the checked child spelling avoids knowingly reusing an unresolved parent alias, without certifying later topology cannot change.
|
|
20
22
|
* @evidence contracts/common.md#clear-and-simple-design One bounded candidate loop owns creation and immediate rejection cleanup, while the capturing generation owns the lifetime of an accepted directory.
|
|
21
23
|
* @evidence contracts/common.md#prohibited-implementation-shortcuts A failed outside-project check never falls back to project scratch, and rejected child cleanup failures propagate instead of being hidden as another candidate miss.
|
|
22
24
|
* @evidence contracts/common.md#meaningful-documentation The native paragraphs explain both identity checks, the returned physical spelling and the ownership condition on skipping a failed candidate; inline comments justify postflight removal.
|
|
23
|
-
* @evidence contracts/portability.md#os-neutral-implementation
|
|
25
|
+
* @evidence contracts/portability.md#os-neutral-implementation The shared SDK selector qualifies native system temporary parents. Adapter containment checks retain their injected project view, and the native filesystem creates and removes the random child.
|
|
24
26
|
* @evidence contracts/performance.md#bound-retention-and-release-resources Rejected random empty children receive synchronous removal attempts; failure propagates and can leave an artifact rather than silently skipping it. Accepted directory ownership transfers to capture's finally cleanup or its separately retained clock owner. No native directory handle pins these path identities against later replacement.
|
|
25
|
-
* @evidence contracts/performance.md#efficient-algorithms
|
|
27
|
+
* @evidence contracts/performance.md#efficient-algorithms Two adapter ancestor walks and a bounded SDK candidate scan observe workspace markers without enumerating directory contents. Allocation tries each accepted physical parent at most once.
|
|
26
28
|
* @evidenceExclude contracts/performance.md#reuse-equivalent-work Scratch allocation is an ownership-bearing effect for one capture and must not be shared merely because two generations select the same candidate parent.
|
|
27
29
|
*/
|
|
28
30
|
export function createTransformScratchDirectory(
|
|
@@ -31,29 +33,32 @@ export function createTransformScratchDirectory(
|
|
|
31
33
|
): string {
|
|
32
34
|
const root = path.resolve(projectRoot);
|
|
33
35
|
const canonicalRoot = filesystem.realpath(root);
|
|
34
|
-
const
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
36
|
+
const protectedRoots = new Set([root, canonicalRoot]);
|
|
37
|
+
for (const start of [root, canonicalRoot]) {
|
|
38
|
+
for (let directory = start; ; directory = path.dirname(directory)) {
|
|
39
|
+
if (
|
|
40
|
+
fs.existsSync(path.join(directory, ".git")) ||
|
|
41
|
+
fs.existsSync(path.join(directory, "pnpm-workspace.yaml"))
|
|
42
|
+
)
|
|
43
|
+
protectedRoots.add(directory);
|
|
44
|
+
if (path.dirname(directory) === directory) break;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
// The installation's private directory is the one location inside a
|
|
48
|
+
// project the SDK yields, after every system candidate. Project walks and
|
|
49
|
+
// watches skip node_modules, as the brokered watch probes below it rely on.
|
|
50
|
+
const isProtected = (candidate: string): boolean =>
|
|
51
|
+
!systemTempOutsideProject.withinInstallationTemp(candidate) &&
|
|
52
|
+
[...protectedRoots].some((directory) => pathIsWithin(candidate, directory));
|
|
44
53
|
const canonicalCandidates = new Set<string>();
|
|
45
54
|
let failure: unknown;
|
|
46
|
-
for (const
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
canonicalCandidate = filesystem.realpath(candidate);
|
|
51
|
-
} catch (error) {
|
|
52
|
-
failure = error;
|
|
53
|
-
continue;
|
|
54
|
-
}
|
|
55
|
+
for (const {
|
|
56
|
+
spelling,
|
|
57
|
+
directory: canonicalCandidate,
|
|
58
|
+
} of systemTempOutsideProject.candidates(root)) {
|
|
55
59
|
if (
|
|
56
|
-
|
|
60
|
+
isProtected(spelling) ||
|
|
61
|
+
isProtected(canonicalCandidate) ||
|
|
57
62
|
canonicalCandidates.has(canonicalCandidate)
|
|
58
63
|
) {
|
|
59
64
|
continue;
|
|
@@ -83,7 +88,7 @@ export function createTransformScratchDirectory(
|
|
|
83
88
|
// parent symlink/junction after validation, redirecting compiler writes or
|
|
84
89
|
// the final recursive removal into the project through that known alias.
|
|
85
90
|
// The returned path still is not an atomic handle against later replacement.
|
|
86
|
-
if (!
|
|
91
|
+
if (!isProtected(canonicalDirectory)) {
|
|
87
92
|
return canonicalDirectory;
|
|
88
93
|
}
|
|
89
94
|
// Refuse the result and synchronously remove only our empty random child
|
|
@@ -8,10 +8,14 @@ import { resultFilesystem } from "../cache/resultFilesystem";
|
|
|
8
8
|
import { envelopeDerivation } from "../envelope/envelopeDerivation";
|
|
9
9
|
import { selectPluginSourceInputs } from "../envelope/selectPluginSourceInputs";
|
|
10
10
|
import { pathIdentityKey } from "../filesystem/pathIdentityKey";
|
|
11
|
-
import {
|
|
11
|
+
import {
|
|
12
|
+
preparePluginBuildEnvironments,
|
|
13
|
+
usesPreparedPluginBuildEnvironments,
|
|
14
|
+
} from "../inputs/preparePluginBuildEnvironments";
|
|
12
15
|
import { toProjectKey } from "../project/toProjectKey";
|
|
13
16
|
import { verifyGenerationLocations } from "../tracker/verifyGenerationLocations";
|
|
14
17
|
import type { TtscTransformHooks } from "../watch/TtscTransformHooks";
|
|
18
|
+
import { trackerProvesInputUnchanged } from "./trackerProvesInputUnchanged";
|
|
15
19
|
|
|
16
20
|
/**
|
|
17
21
|
* The shared ownership boundary for generation reuse in every adapter.
|
|
@@ -67,6 +71,9 @@ export namespace TtscGenerationProof {
|
|
|
67
71
|
* one now; an absent or undefined entry proves nothing.
|
|
68
72
|
*/
|
|
69
73
|
readonly locations?: ReadonlyMap<string, string | undefined>;
|
|
74
|
+
|
|
75
|
+
/** Whether the adapter uses one generation-wide watch input set. */
|
|
76
|
+
readonly groupedWatchInputs?: boolean;
|
|
70
77
|
}
|
|
71
78
|
|
|
72
79
|
/**
|
|
@@ -75,7 +82,7 @@ export namespace TtscGenerationProof {
|
|
|
75
82
|
*
|
|
76
83
|
* @evidence contracts/common.md#principled-implementation A qualified first-delivery pass already owns environment proof; all other requests prepare actual authority before synchronous admission.
|
|
77
84
|
* @evidence contracts/common.md#clear-and-simple-design One branch delegates native preparation rather than repeating it in adapters.
|
|
78
|
-
* @evidence contracts/common.md#prohibited-implementation-shortcuts
|
|
85
|
+
* @evidence contracts/common.md#prohibited-implementation-shortcuts The pass may supply its own qualified readings. Persistent callers use this route whenever currentWatch cannot establish current native and source-tree authority.
|
|
79
86
|
* @evidence contracts/common.md#meaningful-documentation Prose states preparation versus transaction ordering.
|
|
80
87
|
* @evidence contracts/portability.md#os-neutral-implementation Preparation uses the actual generation filesystem and native toolchain reader.
|
|
81
88
|
* @evidence contracts/performance.md#efficient-algorithms Qualified first deliveries perform baseline/identity lookups; other deliveries delegate one preparation per unique plugin directory.
|
|
@@ -114,9 +121,11 @@ export namespace TtscGenerationProof {
|
|
|
114
121
|
cached: TtscCachedProjectTransform,
|
|
115
122
|
file: string,
|
|
116
123
|
epoch: number | undefined,
|
|
124
|
+
groupedWatchInputs = false,
|
|
117
125
|
): Transaction {
|
|
118
126
|
return {
|
|
119
127
|
cached,
|
|
128
|
+
...(groupedWatchInputs ? { groupedWatchInputs } : {}),
|
|
120
129
|
// A persistent delivery rechecks its watched directories here, after
|
|
121
130
|
// its last await, so a directory replaced while it prepared withdraws
|
|
122
131
|
// its tracker before admission reads it.
|
|
@@ -133,6 +142,52 @@ export namespace TtscGenerationProof {
|
|
|
133
142
|
};
|
|
134
143
|
}
|
|
135
144
|
|
|
145
|
+
/**
|
|
146
|
+
* Admit a watching delivery that already has a proof for its source trees.
|
|
147
|
+
* Capture fresh native environment readings after the last await and share
|
|
148
|
+
* them with synchronous admission.
|
|
149
|
+
*
|
|
150
|
+
* @evidence contracts/common.md#principled-implementation Exact watcher coverage and the recorded digest qualify each tree, and current environment readings must equal the environment that earned that proof.
|
|
151
|
+
* @evidence contracts/common.md#clear-and-simple-design Current admission can avoid asynchronous work only when its native readings and watched trees already suffice; the normal preparation owns every refusal.
|
|
152
|
+
* @evidence contracts/common.md#prohibited-implementation-shortcuts No prior delivery or unobserved source tree grants permission to reuse the current environment.
|
|
153
|
+
* @evidence contracts/common.md#meaningful-documentation The prose states the qualification and the synchronous lifetime.
|
|
154
|
+
* @evidence contracts/portability.md#os-neutral-implementation The existing tracker and environment reader establish native scope and path identity.
|
|
155
|
+
* @evidence contracts/performance.md#efficient-algorithms Healthy deliveries perform one current environment batch and two bounded tree-coverage checks instead of a preparation batch followed by another native witness scan.
|
|
156
|
+
* @evidence contracts/performance.md#reuse-equivalent-work Source-tree evidence serves sibling deliveries only alongside current exact coverage and environment qualification.
|
|
157
|
+
* @evidenceExclude contracts/performance.md#bound-retention-and-release-resources The returned transaction belongs to the following synchronous admission and acquires no handles.
|
|
158
|
+
*/
|
|
159
|
+
export function currentWatch(
|
|
160
|
+
cached: TtscCachedProjectTransform,
|
|
161
|
+
file: string,
|
|
162
|
+
): Transaction | undefined {
|
|
163
|
+
const sources = selectPluginSourceInputs(cached.result);
|
|
164
|
+
if (sources.size === 0) return create(cached, file, undefined, true);
|
|
165
|
+
const validation = cached.hostInputValidation;
|
|
166
|
+
const tracker = cached.hostInputMutationTracker;
|
|
167
|
+
if (
|
|
168
|
+
validation === undefined ||
|
|
169
|
+
!usesPreparedPluginBuildEnvironments(cached.result)
|
|
170
|
+
)
|
|
171
|
+
return undefined;
|
|
172
|
+
for (const [directory, state] of sources)
|
|
173
|
+
if (
|
|
174
|
+
validation.trees.get(directory) !== state ||
|
|
175
|
+
validation.treeEnvironments?.get(directory) === undefined ||
|
|
176
|
+
!trackerProvesInputUnchanged(tracker, directory)
|
|
177
|
+
)
|
|
178
|
+
return undefined;
|
|
179
|
+
|
|
180
|
+
const proof = create(cached, file, undefined, true);
|
|
181
|
+
for (const directory of sources.keys())
|
|
182
|
+
if (
|
|
183
|
+
proof.environments?.get(directory) !==
|
|
184
|
+
validation.treeEnvironments?.get(directory) ||
|
|
185
|
+
!trackerProvesInputUnchanged(tracker, directory)
|
|
186
|
+
)
|
|
187
|
+
return undefined;
|
|
188
|
+
return proof;
|
|
189
|
+
}
|
|
190
|
+
|
|
136
191
|
/**
|
|
137
192
|
* Whether this module's first delivery belongs to this generation's proven
|
|
138
193
|
* pass. A missing source baseline cannot acquire this permission.
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import path from "node:path";
|
|
2
|
+
import { PluginBuildEnvironmentWitness } from "ttsc/plugin-source";
|
|
2
3
|
import {
|
|
3
4
|
PluginBuildEnvironmentReadings,
|
|
4
5
|
processPluginBuildEnvironment,
|
|
@@ -90,6 +91,17 @@ export function captureUniversalHostInputValidation(
|
|
|
90
91
|
detail: "observer-incomplete",
|
|
91
92
|
});
|
|
92
93
|
}
|
|
94
|
+
if (result.type !== "exception")
|
|
95
|
+
for (const [anchor, state] of Object.entries(
|
|
96
|
+
result.workspaceInputs ?? {},
|
|
97
|
+
)) {
|
|
98
|
+
if (!PluginBuildEnvironmentWitness.holds(state.entries))
|
|
99
|
+
recordGenerationProofFailure(failures, {
|
|
100
|
+
domain: "host",
|
|
101
|
+
kind: "snapshot-mismatch",
|
|
102
|
+
path: anchor,
|
|
103
|
+
});
|
|
104
|
+
}
|
|
93
105
|
const environmentChanged = environmentInputMismatch(
|
|
94
106
|
result.type === "exception" ? undefined : result.environmentInputs,
|
|
95
107
|
environment,
|
|
@@ -14,6 +14,7 @@ import { MISSING_INPUT_STATE } from "./MISSING_INPUT_STATE";
|
|
|
14
14
|
|
|
15
15
|
/**
|
|
16
16
|
* Re-check a cached mixed graph/dependency input set with its owning codec,
|
|
17
|
+
* accepting exact current notification coverage where the caller has it and
|
|
17
18
|
* reusing the recorded hash of any input whose metadata signature still holds
|
|
18
19
|
* under a freshly minted same-device reference and reporting the signatures
|
|
19
20
|
* this pass captured.
|
|
@@ -29,7 +30,8 @@ import { MISSING_INPUT_STATE } from "./MISSING_INPUT_STATE";
|
|
|
29
30
|
* @evidenceExclude contracts/performance.md#bound-retention-and-release-resources The returned signature DTO transfers to the generation owner; this pass retains no independent cache or native resource.
|
|
30
31
|
* @evidence contracts/performance.md#efficient-algorithms
|
|
31
32
|
* Scans the recorded spelling population, including later entries after a
|
|
32
|
-
* mismatch.
|
|
33
|
+
* mismatch. Exact notification proof can settle an input immediately. Each
|
|
34
|
+
* remaining input pays path/identity and initial native metadata work;
|
|
33
35
|
* a qualified signature skips replay and recapture. Formatting follows
|
|
34
36
|
* path/bigint text. Replay hashes selected bytes or collects predicate
|
|
35
37
|
* failures/listings, then recaptures metadata for earned signatures.
|
|
@@ -40,6 +42,8 @@ import { MISSING_INPUT_STATE } from "./MISSING_INPUT_STATE";
|
|
|
40
42
|
export function matchesCachedExternalInputs(
|
|
41
43
|
/** Generation recording lexical inputs, distinct codecs and earned signatures. */
|
|
42
44
|
cached: TtscCachedProjectTransform,
|
|
45
|
+
/** Whether this delivery's verified watcher proves this exact spelling. */
|
|
46
|
+
provenByWatch?: (file: string) => boolean,
|
|
43
47
|
): {
|
|
44
48
|
/** Whether every recorded external spelling still matches its authority. */
|
|
45
49
|
matches: boolean;
|
|
@@ -64,6 +68,7 @@ export function matchesCachedExternalInputs(
|
|
|
64
68
|
// whichever came first decide.
|
|
65
69
|
for (const file of cached.externalInputPaths ??
|
|
66
70
|
Object.keys(cached.externalInputHashes ?? {})) {
|
|
71
|
+
if (provenByWatch?.(file) === true) continue;
|
|
67
72
|
const identity = derivationIdentity(state, file);
|
|
68
73
|
const spelling = path.resolve(file);
|
|
69
74
|
const observation = cached.externalInputObservations?.[spelling];
|
|
@@ -12,11 +12,13 @@ import { matchesUniversalHostInputTrees } from "./matchesUniversalHostInputTrees
|
|
|
12
12
|
import { nativeInputPredicatesHold } from "./nativeInputPredicatesHold";
|
|
13
13
|
import { sameHashes } from "./sameHashes";
|
|
14
14
|
import { sameProjectDirectories } from "./sameProjectDirectories";
|
|
15
|
+
import { trackerProvesInputUnchanged } from "./trackerProvesInputUnchanged";
|
|
15
16
|
import { walkSnapshotComplete } from "./walkSnapshotComplete";
|
|
16
17
|
|
|
17
18
|
/**
|
|
18
|
-
* Prove one generation
|
|
19
|
-
*
|
|
19
|
+
* Prove one generation against its entire recorded snapshot. A verified Vite
|
|
20
|
+
* delivery can keep exact external-input proof from its healthy host tracker
|
|
21
|
+
* while it checks the rest of the snapshot directly.
|
|
20
22
|
*
|
|
21
23
|
* This is the fallback for a graph-free envelope and for a generation whose
|
|
22
24
|
* watchers could not be opened or have since failed: losing the notification
|
|
@@ -31,7 +33,7 @@ import { walkSnapshotComplete } from "./walkSnapshotComplete";
|
|
|
31
33
|
* native clock reference before this operation; this validator does not mint a
|
|
32
34
|
* reference itself.
|
|
33
35
|
*
|
|
34
|
-
* @evidence contracts/common.md#principled-implementation Universal authority,
|
|
36
|
+
* @evidence contracts/common.md#principled-implementation Universal authority, project membership, and external content and targets must all be proven before adoption. A grouped delivery accepts exact external watch coverage only after checking current tracker health and directory location.
|
|
35
37
|
* @evidence contracts/common.md#clear-and-simple-design One complete-proof boundary composes domain validators and adopts aggregate project/external witnesses after combined success, while universal entry qualification stays with its owner.
|
|
36
38
|
* @evidence contracts/common.md#prohibited-implementation-shortcuts Failed notifications neither prove unchanged state nor force recompilation when direct recorded-state validation can establish the same generation.
|
|
37
39
|
* @evidence contracts/common.md#meaningful-documentation Native paragraphs explain lost-notification fallback, membership authority, disk-source comparison and the reason signatures are re-earned.
|
|
@@ -40,10 +42,10 @@ import { walkSnapshotComplete } from "./walkSnapshotComplete";
|
|
|
40
42
|
* @evidence contracts/performance.md#efficient-algorithms Every admission first replays all generation-owned typed config predicates; this mandatory cost includes native queries, file bytes or directory membership independently of watcher/epoch qualification.
|
|
41
43
|
* Universal entries/probes/tree environments precede a native membership
|
|
42
44
|
* walk. Declared keys avoid irrelevant byte hashes but do not skip directory
|
|
43
|
-
* enumeration.
|
|
44
|
-
*
|
|
45
|
-
*
|
|
46
|
-
*
|
|
45
|
+
* enumeration. The external scans check exact watch coverage before direct
|
|
46
|
+
* metadata, content, and identity work. Costs follow the native paths,
|
|
47
|
+
* adopted signatures, and any remaining bytes or listings. Early rejection
|
|
48
|
+
* skips subsequent domains.
|
|
47
49
|
* @evidence contracts/performance.md#reuse-equivalent-work Typed config predicates remain mandatory on every delivery. An exact-generation synchronous transaction may share their current replay across nested validators, but no pass or notification shortcut authorizes a later delivery to skip them. Qualified separable signatures avoid repeated content reads under the caller's refreshed clock. Successful aggregate proof adopts earned project/external signatures and clears unverified flags; it neither clears recorded changes/failed flags nor makes later quiet notifications sufficient without their other admission conditions.
|
|
48
50
|
*/
|
|
49
51
|
export function matchesCompleteInputSnapshot(
|
|
@@ -115,8 +117,20 @@ export function matchesCompleteInputSnapshot(
|
|
|
115
117
|
// edge requires editing an in-walk source, and a new global or config file
|
|
116
118
|
// requires a tsconfig or package manifest change, both of which the project
|
|
117
119
|
// walk above already detects.
|
|
118
|
-
|
|
119
|
-
|
|
120
|
+
// A loss of project or candidate coverage can require the full comparison
|
|
121
|
+
// while the independently drained host tracker still proves exact inputs.
|
|
122
|
+
const provenExternal =
|
|
123
|
+
proof?.cached === cached &&
|
|
124
|
+
proof.groupedWatchInputs === true &&
|
|
125
|
+
proof.locations !== undefined
|
|
126
|
+
? (file: string) =>
|
|
127
|
+
trackerProvesInputUnchanged(cached.hostInputMutationTracker, file)
|
|
128
|
+
: undefined;
|
|
129
|
+
const externalCurrent = matchesCachedExternalInputs(cached, provenExternal);
|
|
130
|
+
if (
|
|
131
|
+
!externalCurrent.matches ||
|
|
132
|
+
!matchesExternalInputRealpaths(cached, provenExternal)
|
|
133
|
+
) {
|
|
120
134
|
return false;
|
|
121
135
|
}
|
|
122
136
|
adoptProvenSignatures(cached, {
|
|
@@ -11,7 +11,8 @@ import { sameHostInputRealpath } from "../inputs/sameHostInputRealpath";
|
|
|
11
11
|
* Re-check graph-owned physical identities in complete-snapshot fallback.
|
|
12
12
|
*
|
|
13
13
|
* Predicate-bearing spellings are already replayed by their owning validator;
|
|
14
|
-
* this pass handles only
|
|
14
|
+
* this pass handles only legacy graph realpath witnesses outside the caller's
|
|
15
|
+
* verified host tracker coverage.
|
|
15
16
|
*
|
|
16
17
|
* @evidence contracts/common.md#principled-implementation Each recorded legacy physical target must still match under the generation's identity context; predicate observations retain their independent native semantics.
|
|
17
18
|
* @evidence contracts/common.md#clear-and-simple-design This pass owns only the physical half of legacy external snapshot fallback rather than duplicating predicate replay.
|
|
@@ -21,8 +22,8 @@ import { sameHostInputRealpath } from "../inputs/sameHostInputRealpath";
|
|
|
21
22
|
* @evidenceExclude contracts/performance.md#bound-retention-and-release-resources The pass borrows generation records and retains no map, handle or historical result.
|
|
22
23
|
* @evidence contracts/performance.md#efficient-algorithms
|
|
23
24
|
* Materializes recorded target keys for the empty check, then scans external
|
|
24
|
-
* spellings until a mismatch. Predicate
|
|
25
|
-
* entries pay native identity
|
|
25
|
+
* spellings until a mismatch. Predicate and currently proven spellings skip
|
|
26
|
+
* legacy proof. Other entries pay native identity and realpath observation
|
|
26
27
|
* comparison, including uncached native components/case and path text.
|
|
27
28
|
* No source content or recursive directory enumeration is performed here.
|
|
28
29
|
* @evidenceExclude contracts/performance.md#reuse-equivalent-work Complete snapshot admission owns shared proof and adoption; this pass contributes one physical-target verdict.
|
|
@@ -33,12 +34,15 @@ export function matchesExternalInputRealpaths(
|
|
|
33
34
|
* predicates.
|
|
34
35
|
*/
|
|
35
36
|
cached: TtscCachedProjectTransform,
|
|
37
|
+
/** Whether this delivery's verified watcher proves this exact spelling. */
|
|
38
|
+
provenByWatch?: (file: string) => boolean,
|
|
36
39
|
): boolean {
|
|
37
40
|
const expected = cached.externalInputRealpaths;
|
|
38
41
|
if (expected === undefined || Object.keys(expected).length === 0) return true;
|
|
39
42
|
const state = envelopeDerivation(cached);
|
|
40
43
|
const filesystem = resultFilesystem(cached.result);
|
|
41
44
|
for (const input of cached.externalInputPaths ?? []) {
|
|
45
|
+
if (provenByWatch?.(input) === true) continue;
|
|
42
46
|
if (cached.externalInputObservations?.[path.resolve(input)] !== undefined) {
|
|
43
47
|
continue;
|
|
44
48
|
}
|