ttsc 0.30.3 → 0.31.0
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/cmd/graphbench/main.go +2 -3
- package/cmd/graphdump/main.go +42 -16
- package/cmd/graphdump/run_declares_the_capability_its_output_carries_test.go +32 -18
- package/cmd/graphdump/run_reports_an_unknown_flag_without_exiting_the_process_test.go +10 -9
- package/cmd/graphdump/run_reports_an_unloadable_project_without_printing_a_dump_test.go +8 -7
- package/cmd/platform/command_operation_families_test.go +192 -0
- package/cmd/platform/main.go +11 -1
- package/cmd/ttsc/api_compile.go +166 -46
- package/cmd/ttsc/api_compile_branches_test.go +97 -10
- package/cmd/ttsc/api_transform.go +134 -46
- package/cmd/ttsc/api_transform_branches_test.go +10 -7
- package/cmd/ttsc/build.go +177 -68
- package/cmd/ttsc/build_branches_test.go +35 -7
- package/cmd/ttsc/cli_command_operation_families_test.go +1287 -0
- package/cmd/ttsc/cli_contract_helpers_test.go +82 -0
- package/cmd/ttsc/compiler_argument_cwd_test.go +57 -0
- package/cmd/ttsc/filter.go +31 -14
- package/cmd/ttsc/filter_resolves_flag_names_case_insensitively_test.go +10 -13
- package/cmd/ttsc/filter_strips_unknown_forwarded_flag_test.go +10 -16
- package/cmd/ttsc/flags_gen.go +2 -2
- package/cmd/ttsc/helpers_test.go +67 -10
- package/cmd/ttsc/main.go +122 -21
- package/cmd/ttsc/main_alias_branches_test.go +35 -9
- package/cmd/ttsc/testdata/cli_operation_families/TestAPITransformEnvelopeCarriesReferenceGraph/ambient.d.ts +1 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestAPITransformEnvelopeCarriesReferenceGraph/main.ts +2 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestAPITransformEnvelopeCarriesReferenceGraph/mytype.ts +1 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestAPITransformEnvelopeCarriesReferenceGraph/tsconfig.base.json +3 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestAPITransformEnvelopeCarriesReferenceGraph/tsconfig.json +5 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIAPICompileAndTransform/index.ts +1 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIAPICompileAndTransform/src/decorated/main.ts +10 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIAPICompileAndTransform/src/decorated/types.ts +3 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIAPICompileAndTransform/src/helpers.ts +1 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIAPICompileAndTransform/src/isolated.ts +1 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIAPICompileAndTransform/src/main.ts +7 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIAPICompileAndTransform/src/nested/model.ts +1 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIAPICompileAndTransform/tsconfig.json +14 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIAPITransformUsesCurrentDirectory/index.ts +1 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIAPITransformUsesCurrentDirectory/tsconfig.json +7 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIProjectBuildAllowsUnusedTypeParametersOnOverloadSignatures/index.ts +4 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIProjectBuildAllowsUnusedTypeParametersOnOverloadSignatures/tsconfig.json +11 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIProjectBuildBlocksSemanticDiagnostics/index.ts +2 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIProjectBuildBlocksSemanticDiagnostics/tsconfig.json +9 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIProjectBuildBlocksSyntacticDiagnostics/index.ts +2 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIProjectBuildBlocksSyntacticDiagnostics/tsconfig.json +8 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIProjectBuildBlocksUnusedParameters/index.ts +3 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIProjectBuildBlocksUnusedParameters/tsconfig.json +10 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIProjectBuildEmitErrorRejectsManifest/index.ts +1 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIProjectBuildEmitErrorRejectsManifest/tsconfig.json +1 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIReportsDiagnosticsWithoutEmit/index.ts +1 -0
- package/cmd/ttsc/testdata/cli_operation_families/TestCLIReportsDiagnosticsWithoutEmit/tsconfig.json +8 -0
- package/cmd/ttsc/testdata/cli_operation_families/shared-value-one/project/emit.json +8 -0
- package/cmd/ttsc/testdata/cli_operation_families/shared-value-one/project/flag-shaped.json +7 -0
- package/cmd/ttsc/testdata/cli_operation_families/shared-value-one/project/index.ts +2 -0
- package/cmd/ttsc/testdata/cli_operation_families/shared-value-one/project/nested/tsconfig.app.json +11 -0
- package/cmd/ttsc/testdata/cli_operation_families/shared-value-one/project/outside.json +8 -0
- package/cmd/ttsc/testdata/cli_operation_families/shared-value-one/project/tsconfig.json +8 -0
- package/cmd/ttscgraph/auxiliary_identity_state_tracks_retargets_not_source_contents_test.go +26 -15
- package/cmd/ttscgraph/disk_realpath_other.go +2 -0
- package/cmd/ttscgraph/dump.go +46 -29
- package/cmd/ttscgraph/prepared_projection.go +61 -0
- package/cmd/ttscgraph/projection_fixture_test.go +96 -0
- package/cmd/ttscgraph/run_dump_claims_artifacts_only_when_it_asked_test.go +30 -5
- package/cmd/ttscgraph/run_dump_declares_the_capability_its_output_carries_test.go +6 -1
- package/cmd/ttscgraph/run_dump_emits_only_checker_verified_member_relations_test.go +12 -5
- package/cmd/ttscgraph/run_dump_prints_the_graph_as_json_test.go +17 -12
- package/cmd/ttscgraph/run_help_version_and_bad_flags_exit_codes_test.go +8 -3
- package/cmd/ttscgraph/serve.go +116 -79
- package/cmd/ttscgraph/serve_adopts_a_republished_artifact_set_test.go +16 -167
- package/cmd/ttscgraph/serve_adopts_a_republished_set_over_the_shard_protocol_test.go +122 -0
- package/cmd/ttscgraph/serve_answers_a_project_that_implements_its_own_ambient_declaration_test.go +35 -7
- package/cmd/ttscgraph/serve_early_error_encode_failure_is_observable_test.go +5 -0
- package/cmd/ttscgraph/serve_error_response_still_names_its_mode_test.go +10 -5
- package/cmd/ttscgraph/serve_git_ignore_projection_test.go +150 -0
- package/cmd/ttscgraph/serve_keeps_a_startup_set_a_client_never_mentions_test.go +69 -0
- package/cmd/ttscgraph/serve_object_members_refresh_without_identity_collisions_test.go +82 -0
- package/cmd/ttscgraph/serve_phase_trace_accounts_for_load_failure_test.go +9 -3
- package/cmd/ttscgraph/serve_phase_trace_is_opt_in_and_payload_free_test.go +12 -6
- package/cmd/ttscgraph/serve_projects_an_artifact_no_source_owns_test.go +13 -16
- package/cmd/ttscgraph/serve_protocol_fails_the_stream_on_an_unaddressable_request_line_test.go +10 -9
- package/cmd/ttscgraph/serve_protocol_negotiates_incremental_shards_test.go +37 -2
- package/cmd/ttscgraph/serve_protocol_retries_session_creation_test.go +7 -2
- package/cmd/ttscgraph/serve_protocol_reuses_session_test.go +13 -3
- package/cmd/ttscgraph/serve_session_applies_source_edit_incrementally_test.go +12 -7
- package/cmd/ttscgraph/serve_session_fails_closed_on_deleted_config_test.go +12 -7
- package/cmd/ttscgraph/serve_session_fails_closed_on_invalid_config_test.go +8 -3
- package/cmd/ttscgraph/serve_session_keeps_base_url_fallback_unchanged_test.go +7 -2
- package/cmd/ttscgraph/serve_session_keeps_change_detection_live_after_initial_dump_error_test.go +66 -0
- package/cmd/ttscgraph/serve_session_keeps_esm_directory_candidate_unchanged_test.go +12 -3
- package/cmd/ttscgraph/serve_session_keeps_exports_blocked_file_candidates_unchanged_test.go +8 -3
- package/cmd/ttscgraph/serve_session_keeps_inactive_conditional_export_unchanged_test.go +12 -3
- package/cmd/ttscgraph/serve_session_keeps_lower_priority_module_candidate_unchanged_test.go +14 -8
- package/cmd/ttscgraph/serve_session_keeps_lower_priority_paths_pattern_unchanged_test.go +12 -3
- package/cmd/ttscgraph/serve_session_keeps_missing_literal_root_unchanged_test.go +7 -2
- package/cmd/ttscgraph/serve_session_keeps_nonlongest_root_dirs_candidate_unchanged_test.go +12 -3
- package/cmd/ttscgraph/serve_session_rebuilds_import_graph_change_test.go +17 -8
- package/cmd/ttscgraph/serve_session_reloads_commonjs_package_entry_for_esm_test.go +11 -2
- package/cmd/ttscgraph/serve_session_reloads_created_literal_root_test.go +7 -2
- package/cmd/ttscgraph/serve_session_reloads_extended_config_change_test.go +9 -4
- package/cmd/ttscgraph/serve_session_reloads_module_suffix_candidate_test.go +13 -4
- package/cmd/ttscgraph/serve_session_reloads_newly_resolved_conditional_export_test.go +13 -8
- package/cmd/ttscgraph/serve_session_reloads_newly_resolved_config_types_test.go +7 -2
- package/cmd/ttscgraph/serve_session_reloads_newly_resolved_excluded_import_test.go +11 -3
- package/cmd/ttscgraph/serve_session_reloads_newly_resolved_package_export_test.go +11 -2
- package/cmd/ttscgraph/serve_session_reloads_newly_resolved_package_import_test.go +11 -2
- package/cmd/ttscgraph/serve_session_reloads_newly_resolved_path_alias_test.go +11 -2
- package/cmd/ttscgraph/serve_session_reloads_newly_resolved_reference_path_test.go +11 -2
- package/cmd/ttscgraph/serve_session_reloads_newly_resolved_root_dirs_target_test.go +11 -2
- package/cmd/ttscgraph/serve_session_reloads_newly_resolved_type_reference_test.go +11 -2
- package/cmd/ttscgraph/serve_session_reloads_root_file_set_test.go +11 -5
- package/cmd/ttscgraph/serve_session_reloads_source_deleted_during_load_test.go +16 -9
- package/cmd/ttscgraph/serve_session_reloads_superseding_module_candidates_test.go +18 -13
- package/cmd/ttscgraph/serve_session_reloads_transitive_project_reference_test.go +14 -5
- package/cmd/ttscgraph/serve_session_reloads_when_program_plugin_linked_test.go +13 -8
- package/cmd/ttscgraph/serve_session_retries_a_pending_dump_before_unchanged_test.go +62 -0
- package/cmd/ttscgraph/serve_session_reuses_unchanged_preamble_source_test.go +21 -0
- package/cmd/ttscgraph/serve_session_reuses_unchanged_snapshot_test.go +12 -7
- package/cmd/ttscgraph/serve_session_revisits_source_edited_during_load_test.go +18 -8
- package/cmd/ttscgraph/serve_session_tolerates_os_invalid_resolution_candidate_test.go +13 -9
- package/cmd/ttscgraph/serve_session_tracks_all_module_specifier_forms_test.go +12 -3
- package/cmd/ttscgraph/serve_session_tracks_diamond_project_references_once_test.go +12 -8
- package/cmd/ttscgraph/serve_shards.go +356 -279
- package/cmd/ttscgraph/serve_shards_abandoned_generation_converges_on_retry_test.go +41 -16
- package/cmd/ttscgraph/serve_shards_delete_removed_source_test.go +14 -4
- package/cmd/ttscgraph/serve_shards_external_endpoints_test.go +18 -2
- package/cmd/ttscgraph/serve_shards_keep_source_distributed_dependencies_at_the_boundary_test.go +36 -5
- package/cmd/ttscgraph/serve_shards_match_full_dump_oracle_test.go +12 -3
- package/cmd/ttscgraph/serve_shards_merge_pending_and_new_edits_test.go +36 -3
- package/cmd/ttscgraph/serve_shards_prune_unreferenced_external_endpoints_test.go +18 -2
- package/cmd/ttscgraph/serve_shards_publish_created_source_test.go +16 -13
- package/cmd/ttscgraph/serve_shards_rebuild_declaration_edit_test.go +14 -4
- package/cmd/ttscgraph/serve_shards_refresh_cross_file_implementation_test.go +24 -5
- package/cmd/ttscgraph/serve_shards_refresh_dependent_diagnostics_test.go +30 -7
- package/cmd/ttscgraph/serve_shards_rename_moves_source_identity_test.go +14 -11
- package/cmd/ttscgraph/serve_shards_retry_preserves_committed_generation_test.go +17 -7
- package/cmd/ttscgraph/serve_shards_reuse_unaffected_sources_test.go +21 -7
- package/cmd/ttscgraph/serve_snapshot_proves_its_program_without_a_second_read_test.go +57 -16
- package/cmd/ttscgraph/serve_source_encoding_test.go +133 -0
- package/cmd/ttscserver/command_operation_families_test.go +207 -0
- package/cmd/ttscserver/main.go +121 -39
- package/cmd/ttscserver/resolve_launch_uses_native_flag_authority_test.go +147 -0
- package/cmd/ttscserver/run_lsp_forwards_execute_command_advertisement_flags_test.go +7 -0
- package/cmd/ttscserver/run_lsp_prefers_tsgo_flag_test.go +13 -1
- package/cmd/ttscserver/run_lsp_reports_getwd_error_test.go +5 -0
- package/cmd/ttscserver/run_lsp_reports_server_error_test.go +10 -3
- package/cmd/ttscserver/run_lsp_uses_native_plugin_manifest_source_test.go +13 -10
- package/cmd/ttscserver/run_lsp_uses_tsgo_environment_test.go +10 -3
- package/driver/authored_region_maps_positions_around_the_preamble_test.go +95 -0
- package/driver/build_information_uses_selected_output_identity_test.go +148 -0
- package/driver/check_observations.go +67 -0
- package/driver/config_discovery.go +93 -24
- package/driver/declaration_shape.go +9 -0
- package/driver/diagnostics_preamble.go +8 -7
- package/driver/emit_containment.go +29 -8
- package/driver/emit_plugin.go +106 -36
- package/driver/emit_plugin_output.go +26 -2
- package/driver/emit_provenance.go +155 -0
- package/driver/graph.go +54 -20
- package/driver/host.go +26 -3
- package/driver/input_observation.go +78 -16
- package/driver/input_observation_test.go +34 -11
- package/driver/lsp.go +401 -30
- package/driver/overlay.go +69 -2
- package/driver/plugins.go +256 -24
- package/driver/private_result.go +43 -0
- package/driver/program.go +439 -95
- package/driver/resolution_candidates.go +63 -14
- package/driver/resolution_candidates_test.go +28 -0
- package/driver/resolutioninputs/recorder.cjs +1149 -0
- package/driver/resolutioninputs/resolutioninputs.go +37 -0
- package/driver/rewrite.go +373 -420
- package/driver/session.go +80 -12
- package/driver/sourcemap_preamble.go +38 -16
- package/driver/transform_dependencies.go +38 -10
- package/driver/transform_dependencies_declares_every_file_without_a_contributor_test.go +9 -8
- package/driver/transform_dependencies_drops_a_self_reported_dependency_test.go +7 -6
- package/driver/transform_dependencies_keys_a_reported_path_like_the_envelope_test.go +9 -9
- package/driver/transform_dependencies_requires_every_contributor_to_declare_test.go +10 -5
- package/driver/transform_dependencies_stays_silent_for_an_undeclared_contributor_test.go +8 -6
- package/driver/transform_dependencies_withdraws_completeness_after_an_unusable_dependency_test.go +9 -5
- package/driver/transform_source_map.go +388 -0
- package/driver/windowsjunction/create_preserves_existing_directory_windows_test.go +48 -0
- package/driver/windowsjunction/create_treats_paths_as_data_windows_test.go +55 -0
- package/driver/windowsjunction/windowsjunction.go +17 -1
- package/go.mod +10 -10
- package/go.sum +10 -10
- package/internal/cwd/cwd.go +13 -0
- package/internal/e2etrace/artifact.go +147 -0
- package/internal/e2etrace/completion_hints.go +35 -0
- package/internal/e2etrace/completion_hints_test.go +76 -0
- package/internal/e2etrace/e2etrace.go +303 -0
- package/internal/e2etrace/output.go +50 -0
- package/internal/graph/artifacts.go +69 -12
- package/internal/graph/artifacts_index_what_a_plugin_published_test.go +19 -8
- package/internal/graph/artifacts_survive_a_partial_rebuild_test.go +11 -12
- package/internal/graph/assigned_implementations_of_declaration_file_symbols_leave_no_edge_source_test.go +10 -12
- package/internal/graph/assigned_implementations_of_node_modules_symbols_leave_no_edge_source_test.go +7 -1
- package/internal/graph/build.go +122 -38
- package/internal/graph/build_files_reuses_committed_cross_file_endpoints_test.go +9 -3
- package/internal/graph/build_keeps_source_distributed_dependencies_at_the_external_boundary_test.go +10 -1
- package/internal/graph/build_records_a_node_per_top_level_declaration_test.go +10 -4
- package/internal/graph/build_releases_the_scratch_it_no_longer_reads_test.go +22 -15
- package/internal/graph/decorators.go +18 -0
- package/internal/graph/decorators_capture_name_and_literal_arguments_test.go +9 -4
- package/internal/graph/diagnostics.go +21 -8
- package/internal/graph/doc_refs_are_the_use_the_checker_already_counts_test.go +25 -13
- package/internal/graph/doc_refs_resolve_documentation_links_test.go +19 -15
- package/internal/graph/doc_tags.go +28 -19
- package/internal/graph/doc_tags_are_claimed_before_they_are_read_test.go +16 -6
- package/internal/graph/doc_tags_capture_every_unrecognized_tag_test.go +9 -2
- package/internal/graph/doc_tags_read_only_what_the_parser_attached_test.go +12 -8
- package/internal/graph/doc_tags_stop_at_the_external_boundary_test.go +11 -1
- package/internal/graph/doc_tags_survive_line_endings_and_repeated_blocks_test.go +16 -6
- package/internal/graph/dump.go +200 -51
- package/internal/graph/dump_checkout_paths_are_stable_test.go +9 -2
- package/internal/graph/dump_diagnostics_ride_the_generation_that_built_it_test.go +10 -11
- package/internal/graph/dump_evidence_skips_leading_trivia_test.go +8 -2
- package/internal/graph/dump_is_a_function_of_the_source_test.go +12 -13
- package/internal/graph/dump_never_serializes_a_list_as_null_test.go +9 -9
- package/internal/graph/dump_path_mapper_caches_alias_resolution_test.go +10 -2
- package/internal/graph/dump_path_mapper_rejects_unportable_roots_and_collisions_test.go +53 -0
- package/internal/graph/{dump_paths_are_portable_and_injective_test.go → dump_path_mapper_uses_portable_coordinates_test.go} +8 -43
- package/internal/graph/dump_paths.go +61 -25
- package/internal/graph/dump_paths_canonicalize_windows_short_root_test.go +45 -8
- package/internal/graph/dump_rejects_provenance_only_path_errors_test.go +5 -0
- package/internal/graph/dump_serializes_the_full_graph_test.go +13 -19
- package/internal/graph/dump_symlink_project_publishes_matching_base_test.go +8 -0
- package/internal/graph/dump_uses_ecma_line_terminators_test.go +12 -6
- package/internal/graph/duplicate_variable_object_members_keep_first_declaration_test.go +11 -8
- package/internal/graph/edge_spans_point_to_resolved_usage_test.go +13 -5
- package/internal/graph/edges.go +44 -47
- package/internal/graph/edges_cover_class_level_references_test.go +14 -11
- package/internal/graph/enum_initializer_calls_are_edges_test.go +13 -3
- package/internal/graph/enum_members_carry_their_names_on_the_enum_node_test.go +19 -26
- package/internal/graph/exports.go +3 -5
- package/internal/graph/file_diagnostics_match_tsgo_code_and_location_test.go +9 -4
- package/internal/graph/file_diagnostics_report_code_column_and_message_test.go +11 -5
- package/internal/graph/function_locals_do_not_collide_test.go +27 -7
- package/internal/graph/gitignore.go +25 -12
- package/internal/graph/graph.go +167 -52
- package/internal/graph/heritage_edges_cover_implements_and_interface_extends_test.go +11 -3
- package/internal/graph/heritage_edges_keep_extends_and_implements_to_same_base_test.go +6 -0
- package/internal/graph/heritage_edges_record_extends_versus_implements_origin_test.go +9 -3
- package/internal/graph/heritage_edges_traverse_barrels_and_stop_at_external_leaves_test.go +11 -4
- package/internal/graph/line_model.go +44 -25
- package/internal/graph/literals.go +6 -7
- package/internal/graph/literals_are_absent_when_the_type_admits_more_than_it_can_name_test.go +10 -5
- package/internal/graph/literals_cover_enum_members_the_graph_has_no_nodes_for_test.go +15 -17
- package/internal/graph/literals_do_not_depend_on_declaration_line_wrapping_test.go +10 -9
- package/internal/graph/literals_render_every_value_in_typescript_source_form_test.go +11 -11
- package/internal/graph/literals_resolve_through_alias_indirection_test.go +11 -11
- package/internal/graph/member_relation_edges_follow_checker_validity_test.go +11 -2
- package/internal/graph/member_relation_edges_preserve_checker_boundaries_test.go +11 -1
- package/internal/graph/member_relation_edges_reject_checker_invalid_pairs_test.go +12 -7
- package/internal/graph/namespace_dotted_form_qualifies_deeply_test.go +12 -3
- package/internal/graph/namespace_members_become_qualified_nodes_and_edges_test.go +12 -2
- package/internal/graph/node_identity_is_position_invariant_test.go +8 -2
- package/internal/graph/node_ids_preserve_hash_bearing_components_test.go +10 -2
- package/internal/graph/node_modifiers_emit_union_strings_test.go +13 -12
- package/internal/graph/nodes_are_marked_exported_through_the_export_table_test.go +12 -14
- package/internal/graph/object_literal_declarations_resolve_calls_test.go +170 -0
- package/internal/graph/object_literal_members_ride_on_the_snapshot_test.go +14 -13
- package/internal/graph/object_member_signatures_preserve_literal_whitespace_test.go +11 -7
- package/internal/graph/object_members.go +100 -1
- package/internal/graph/overload_implementation_replaces_signature_test.go +13 -2
- package/internal/graph/property_member_edges_remain_owner_visible_test.go +9 -3
- package/internal/graph/provenance.go +172 -87
- package/internal/graph/resolve.go +46 -12
- package/internal/graph/resolve_prefers_implementation_declaration_test.go +10 -2
- package/internal/graph/resolve_unwraps_barrel_reexport_to_real_declaration_test.go +16 -20
- package/internal/graph/source.go +16 -6
- package/internal/graph/source_texts_cover_every_resident_program_source_test.go +11 -7
- package/internal/graph/type_ref_edges_cover_typeof_as_satisfies_test.go +21 -2
- package/internal/graph/type_ref_edges_resolve_named_types_across_files_test.go +8 -3
- package/internal/graph/value_access_edges_cover_properties_test.go +11 -3
- package/internal/graph/value_call_edges_attribute_function_assignments_to_members_test.go +10 -4
- package/internal/graph/value_call_edges_cover_jsx_components_test.go +12 -8
- package/internal/graph/value_call_edges_cover_methods_and_constructors_test.go +12 -9
- package/internal/graph/value_call_edges_cover_variable_bound_callables_test.go +9 -3
- package/internal/graph/value_call_edges_do_not_double_record_invoked_member_access_test.go +10 -3
- package/internal/graph/value_call_edges_record_construct_versus_call_origin_test.go +12 -9
- package/internal/graph/value_call_edges_resolve_across_files_and_dedupe_test.go +10 -3
- package/internal/graph/value_call_edges_skip_self_and_unresolved_test.go +16 -5
- package/internal/graph/wire_node_ids_share_alias_resolution_test.go +10 -4
- package/internal/graphsymbols/position_helpers_follow_ecma_line_terminators_test.go +16 -4
- package/internal/graphsymbols/provider.go +278 -113
- package/internal/lspserver/lsp_clean_didopen_refreshes_compiler_state_test.go +14 -12
- package/internal/lspserver/lsp_completion_gate_never_refuses_a_matching_line_test.go +7 -1
- package/internal/lspserver/lsp_completion_hints_longest_trigger_wins_test.go +30 -5
- package/internal/lspserver/lsp_completion_hints_nearest_trigger_wins_test.go +5 -0
- package/internal/lspserver/lsp_completion_merges_into_upstream_response_test.go +23 -10
- package/internal/lspserver/lsp_completion_nearest_hint_replaces_nearest_filter_test.go +7 -1
- package/internal/lspserver/lsp_completion_preserves_completion_list_extensions_test.go +13 -5
- package/internal/lspserver/lsp_completion_refuses_hints_inside_a_string_literal_test.go +11 -7
- package/internal/lspserver/lsp_completion_replaces_full_filter_in_rank_order_test.go +12 -2
- package/internal/lspserver/lsp_completion_request.go +5 -26
- package/internal/lspserver/lsp_completion_scope.go +13 -10
- package/internal/lspserver/lsp_completion_scope_bench_test.go +11 -5
- package/internal/lspserver/lsp_completion_scope_classifies_regex_statement_and_operator_boundaries_test.go +8 -1
- package/internal/lspserver/lsp_completion_scope_ignores_jsdoc_bytes_in_literals_test.go +11 -10
- package/internal/lspserver/lsp_completion_scope_refuses_regex_hints_test.go +7 -3
- package/internal/lspserver/lsp_completion_trigger_uses_last_rune_test.go +6 -0
- package/internal/lspserver/lsp_deleted_watched_file_withdraws_plugin_diagnostics_test.go +11 -10
- package/internal/lspserver/lsp_didsave_keeps_the_incremental_changed_uri_path_test.go +12 -9
- package/internal/lspserver/lsp_document_diagnostics_omits_cached_project_when_current_result_has_none_test.go +17 -5
- package/internal/lspserver/lsp_envelope.go +84 -11
- package/internal/lspserver/lsp_executable_project_input_change_requests_launcher_restart_test.go +12 -9
- package/internal/lspserver/lsp_external_watched_change_retains_program_test.go +8 -2
- package/internal/lspserver/lsp_frame.go +42 -10
- package/internal/lspserver/lsp_hints_absence_is_not_an_error_test.go +16 -15
- package/internal/lspserver/lsp_hints_refresh_coalesces_concurrent_requests_test.go +21 -12
- package/internal/lspserver/lsp_hints_refresh_ignores_a_superseded_generation_test.go +20 -12
- package/internal/lspserver/lsp_hints_refresh_keeps_each_producer_isolated_test.go +30 -9
- package/internal/lspserver/lsp_hints_refresh_replaces_the_session_snapshot_test.go +25 -18
- package/internal/lspserver/lsp_hints_refresh_scheduled_by_editor_events_test.go +12 -12
- package/internal/lspserver/lsp_hints_refresh_serves_completion_while_running_test.go +21 -8
- package/internal/lspserver/lsp_index_byte_from_bounds_its_search_start_test.go +9 -7
- package/internal/lspserver/lsp_initialize_constrains_position_encoding_to_utf16_test.go +57 -21
- package/internal/lspserver/lsp_late_completion_trigger_is_reported_once_test.go +16 -17
- package/internal/lspserver/lsp_native_completion_hints_decode_flat_lint_wire_test.go +8 -2
- package/internal/lspserver/lsp_native_completion_hints_grouped_compatibility_boundary_test.go +5 -0
- package/internal/lspserver/lsp_native_plugin_source.go +381 -202
- package/internal/lspserver/lsp_native_plugin_source_ends_the_session_on_a_selection_input_test.go +234 -0
- package/internal/lspserver/lsp_native_reply_policies_test.go +475 -0
- package/internal/lspserver/lsp_native_reply_policy.go +232 -0
- package/internal/lspserver/lsp_native_resident.go +171 -57
- package/internal/lspserver/lsp_plugin.go +372 -68
- package/internal/lspserver/lsp_plugin_completion_resolve_stays_local_test.go +13 -4
- package/internal/lspserver/lsp_plugin_selection_inputs.go +283 -0
- package/internal/lspserver/lsp_plugin_selection_inputs_follow_directory_case_semantics_windows_test.go +81 -0
- package/internal/lspserver/lsp_position_conversions_span_astral_and_combining_runes_test.go +33 -11
- package/internal/lspserver/lsp_project_context_transport_identity_test.go +14 -2
- package/internal/lspserver/lsp_project_diagnostics.go +25 -4
- package/internal/lspserver/lsp_project_diagnostics_capability_is_independent_test.go +13 -2
- package/internal/lspserver/lsp_project_diagnostics_program_input_overlap_refreshes_all_producers_test.go +14 -4
- package/internal/lspserver/lsp_project_diagnostics_refresh_accumulates_owner_freshness_test.go +8 -2
- package/internal/lspserver/lsp_project_diagnostics_refresh_keeps_each_producer_last_good_test.go +10 -5
- package/internal/lspserver/lsp_project_diagnostics_refreshes_only_input_owners_test.go +14 -2
- package/internal/lspserver/lsp_project_diagnostics_resume_preserves_generation_test.go +8 -2
- package/internal/lspserver/lsp_project_diagnostics_translates_relative_client_project_test.go +15 -11
- package/internal/lspserver/lsp_project_input_ownership_resolves_declared_spellings_test.go +17 -8
- package/internal/lspserver/lsp_project_input_path_key_windows.go +16 -16
- package/internal/lspserver/lsp_project_input_path_key_windows_test.go +34 -18
- package/internal/lspserver/lsp_project_input_registration.go +5 -1
- package/internal/lspserver/lsp_project_input_registration_rechecks_selection_baseline_test.go +10 -4
- package/internal/lspserver/lsp_project_input_registration_reconciles_rejected_pending_request_test.go +5 -0
- package/internal/lspserver/lsp_project_input_registration_shapes_patterns_test.go +9 -3
- package/internal/lspserver/lsp_project_input_watchers_anchor_missing_paths_test.go +8 -3
- package/internal/lspserver/lsp_project_inputs.go +203 -59
- package/internal/lspserver/lsp_project_inputs_match_missing_exact_and_glob_test.go +10 -6
- package/internal/lspserver/lsp_project_inputs_reject_invalid_and_foreign_snapshots_test.go +25 -2
- package/internal/lspserver/lsp_proxy.go +239 -80
- package/internal/lspserver/lsp_refresh.go +16 -1
- package/internal/lspserver/lsp_reload_directories_compare_immediate_topology_test.go +66 -19
- package/internal/lspserver/lsp_reload_directories_separate_glob_territory_test.go +26 -6
- package/internal/lspserver/lsp_reload_file_fingerprint_preserves_raw_symlink_target_test.go +12 -6
- package/internal/lspserver/lsp_reload_fingerprints_read_a_junction_as_a_link_test.go +76 -0
- package/internal/lspserver/lsp_resident_falls_back_when_serve_unsupported_test.go +20 -13
- package/internal/lspserver/lsp_resident_invalidation_broadcasts_program_input_overlap_test.go +9 -4
- package/internal/lspserver/lsp_resident_invalidation_targets_project_input_owners_test.go +6 -1
- package/internal/lspserver/lsp_resident_maps_verb_args_test.go +5 -0
- package/internal/lspserver/lsp_same_transport_entries_are_deduplicated_test.go +10 -1
- package/internal/lspserver/lsp_server.go +124 -21
- package/internal/lspserver/lsp_symbols.go +92 -13
- package/internal/lspserver/lsp_watched_file_changes_reach_compiler_caches_test.go +11 -10
- package/internal/sourceprocess/complete_group.go +70 -0
- package/internal/sourceprocess/complete_group_preserves_original_wait_and_requires_independent_absence_test.go +145 -0
- package/internal/sourceprocess/contain_unix.go +143 -0
- package/internal/sourceprocess/contain_windows.go +442 -0
- package/internal/sourceprocess/darwin_group_retirement_preserves_phase_evidence_test.go +287 -0
- package/internal/sourceprocess/observe_exit_darwin.go +57 -0
- package/internal/sourceprocess/observe_exit_linux.go +27 -0
- package/internal/sourceprocess/observe_exit_other.go +11 -0
- package/internal/sourceprocess/reap_linux.go +31 -0
- package/internal/sourceprocess/reap_other.go +10 -0
- package/internal/sourceprocess/request_preserves_native_command_inputs_test.go +86 -0
- package/internal/sourceprocess/run.go +216 -0
- package/internal/sourceprocess/target_windows.go +211 -0
- package/internal/sourceprocess/windows_job_accounting_rejects_invalid_boundary_test.go +97 -0
- package/internal/sourceprocess/windows_target_owns_suspended_admission_test.go +179 -0
- package/internal/watchhelper/run.go +32 -0
- package/internal/watchhelper/run_linux.go +323 -0
- package/internal/watchhelper/run_linux_test.go +418 -0
- package/internal/watchhelper/run_other.go +16 -0
- package/internal/watchhelper/watchhelper.go +100 -0
- package/lib/TtscCompiler.d.ts +118 -21
- package/lib/TtscCompiler.js +175 -179
- package/lib/TtscCompiler.js.map +1 -1
- package/lib/TtscService.d.ts +66 -18
- package/lib/TtscService.js +81 -24
- package/lib/TtscService.js.map +1 -1
- package/lib/TtscServiceRequestOptions.d.ts +21 -0
- package/lib/TtscServiceRequestOptions.js +3 -0
- package/lib/TtscServiceRequestOptions.js.map +1 -0
- package/lib/compiler/internal/CapturedProcessOutput.d.ts +61 -0
- package/lib/compiler/internal/CapturedProcessOutput.js +3 -0
- package/lib/compiler/internal/CapturedProcessOutput.js.map +1 -0
- package/lib/compiler/internal/CompilerArgumentsInspection.d.ts +53 -0
- package/lib/compiler/internal/CompilerArgumentsInspection.js +173 -0
- package/lib/compiler/internal/CompilerArgumentsInspection.js.map +1 -0
- package/lib/compiler/internal/EmitOwnershipIndex.d.ts +92 -0
- package/lib/compiler/internal/EmitOwnershipIndex.js +215 -0
- package/lib/compiler/internal/EmitOwnershipIndex.js.map +1 -0
- package/lib/compiler/internal/PrivateCompilerOutput.d.ts +67 -0
- package/lib/compiler/internal/PrivateCompilerOutput.js +245 -0
- package/lib/compiler/internal/PrivateCompilerOutput.js.map +1 -0
- package/lib/compiler/internal/ResidentCheckProcess.d.ts +127 -0
- package/lib/compiler/internal/ResidentCheckProcess.js +403 -0
- package/lib/compiler/internal/ResidentCheckProcess.js.map +1 -0
- package/lib/compiler/internal/ResidentCheckProcessOptions.d.ts +29 -0
- package/lib/compiler/internal/ResidentCheckProcessOptions.js +3 -0
- package/lib/compiler/internal/ResidentCheckProcessOptions.js.map +1 -0
- package/lib/compiler/internal/ResidentCheckRequest.d.ts +37 -0
- package/lib/compiler/internal/ResidentCheckRequest.js +3 -0
- package/lib/compiler/internal/ResidentCheckRequest.js.map +1 -0
- package/lib/compiler/internal/ResidentCheckResult.d.ts +23 -0
- package/lib/compiler/internal/ResidentCheckResult.js +3 -0
- package/lib/compiler/internal/ResidentCheckResult.js.map +1 -0
- package/lib/compiler/internal/ResidentCheckTelemetry.d.ts +33 -0
- package/lib/compiler/internal/ResidentCheckTelemetry.js +3 -0
- package/lib/compiler/internal/ResidentCheckTelemetry.js.map +1 -0
- package/lib/compiler/internal/ResidentReplyKind.d.ts +18 -0
- package/lib/compiler/internal/ResidentReplyKind.js +3 -0
- package/lib/compiler/internal/ResidentReplyKind.js.map +1 -0
- package/lib/compiler/internal/ResidentTransformProcess.d.ts +83 -0
- package/lib/compiler/internal/ResidentTransformProcess.js +261 -0
- package/lib/compiler/internal/ResidentTransformProcess.js.map +1 -0
- package/lib/compiler/internal/ResidentTransformProcessOptions.d.ts +27 -0
- package/lib/compiler/internal/ResidentTransformProcessOptions.js +3 -0
- package/lib/compiler/internal/ResidentTransformProcessOptions.js.map +1 -0
- package/lib/compiler/internal/ResidentTransformReply.d.ts +51 -0
- package/lib/compiler/internal/ResidentTransformReply.js +79 -0
- package/lib/compiler/internal/ResidentTransformReply.js.map +1 -0
- package/lib/compiler/internal/ResidentTransformRequestOptions.d.ts +16 -0
- package/lib/compiler/internal/ResidentTransformRequestOptions.js +3 -0
- package/lib/compiler/internal/ResidentTransformRequestOptions.js.map +1 -0
- package/lib/compiler/internal/ResidentTransformRequests.d.ts +102 -0
- package/lib/compiler/internal/ResidentTransformRequests.js +172 -0
- package/lib/compiler/internal/ResidentTransformRequests.js.map +1 -0
- package/lib/compiler/internal/StartedResidentTransform.d.ts +27 -0
- package/lib/compiler/internal/StartedResidentTransform.js +3 -0
- package/lib/compiler/internal/StartedResidentTransform.js.map +1 -0
- package/lib/compiler/internal/TransformProjectWorkerReply.d.ts +34 -0
- package/lib/compiler/internal/TransformProjectWorkerReply.js +3 -0
- package/lib/compiler/internal/TransformProjectWorkerReply.js.map +1 -0
- package/lib/compiler/internal/TransformProjectWorkerRequest.d.ts +39 -0
- package/lib/compiler/internal/TransformProjectWorkerRequest.js +3 -0
- package/lib/compiler/internal/TransformProjectWorkerRequest.js.map +1 -0
- package/lib/compiler/internal/build/BuildExecution.d.ts +359 -0
- package/lib/compiler/internal/build/BuildExecution.js +977 -0
- package/lib/compiler/internal/build/BuildExecution.js.map +1 -0
- package/lib/compiler/internal/build/BuildTiming.d.ts +99 -0
- package/lib/compiler/internal/build/BuildTiming.js +113 -0
- package/lib/compiler/internal/build/BuildTiming.js.map +1 -0
- package/lib/compiler/internal/build/CompilerDiagnostics.d.ts +82 -0
- package/lib/compiler/internal/build/CompilerDiagnostics.js +270 -0
- package/lib/compiler/internal/build/CompilerDiagnostics.js.map +1 -0
- package/lib/compiler/internal/build/NativePluginArguments.d.ts +114 -0
- package/lib/compiler/internal/build/NativePluginArguments.js +255 -0
- package/lib/compiler/internal/build/NativePluginArguments.js.map +1 -0
- package/lib/compiler/internal/build/PassthroughFlags.d.ts +137 -0
- package/lib/compiler/internal/build/PassthroughFlags.js +213 -0
- package/lib/compiler/internal/build/PassthroughFlags.js.map +1 -0
- package/lib/compiler/internal/build/PluginFailureDiagnostics.d.ts +48 -0
- package/lib/compiler/internal/build/PluginFailureDiagnostics.js +68 -0
- package/lib/compiler/internal/build/PluginFailureDiagnostics.js.map +1 -0
- package/lib/compiler/internal/build/ResidentCheckEntryPlan.d.ts +38 -0
- package/lib/compiler/internal/build/ResidentCheckEntryPlan.js +3 -0
- package/lib/compiler/internal/build/ResidentCheckEntryPlan.js.map +1 -0
- package/lib/compiler/internal/build/ResidentCheckWatchChange.d.ts +30 -0
- package/lib/compiler/internal/build/ResidentCheckWatchChange.js +3 -0
- package/lib/compiler/internal/build/ResidentCheckWatchChange.js.map +1 -0
- package/lib/compiler/internal/build/ResidentCheckWatchSession.d.ts +113 -0
- package/lib/compiler/internal/build/ResidentCheckWatchSession.js +378 -0
- package/lib/compiler/internal/build/ResidentCheckWatchSession.js.map +1 -0
- package/lib/compiler/internal/build/RunBuildOptions.d.ts +130 -0
- package/lib/compiler/internal/build/RunBuildOptions.js +3 -0
- package/lib/compiler/internal/build/RunBuildOptions.js.map +1 -0
- package/lib/compiler/internal/build/TsgoArguments.d.ts +168 -0
- package/lib/compiler/internal/build/TsgoArguments.js +324 -0
- package/lib/compiler/internal/build/TsgoArguments.js.map +1 -0
- package/lib/compiler/internal/build/appendBuildOutput.d.ts +41 -0
- package/lib/compiler/internal/build/appendBuildOutput.js +182 -0
- package/lib/compiler/internal/build/appendBuildOutput.js.map +1 -0
- package/lib/compiler/internal/build/bufferResidentCheckEntryRequests.d.ts +20 -0
- package/lib/compiler/internal/build/bufferResidentCheckEntryRequests.js +40 -0
- package/lib/compiler/internal/build/bufferResidentCheckEntryRequests.js.map +1 -0
- package/lib/compiler/internal/build/createProcessDiagnostic.d.ts +19 -0
- package/lib/compiler/internal/build/createProcessDiagnostic.js +30 -0
- package/lib/compiler/internal/build/createProcessDiagnostic.js.map +1 -0
- package/lib/compiler/internal/build/isAbsoluteLocalProjectInputPath.d.ts +22 -0
- package/lib/compiler/internal/build/isAbsoluteLocalProjectInputPath.js +59 -0
- package/lib/compiler/internal/build/isAbsoluteLocalProjectInputPath.js.map +1 -0
- package/lib/compiler/internal/build/mergeProjectInputSnapshots.d.ts +28 -0
- package/lib/compiler/internal/build/mergeProjectInputSnapshots.js +121 -0
- package/lib/compiler/internal/build/mergeProjectInputSnapshots.js.map +1 -0
- package/lib/compiler/internal/build/normalizeBuildOutput.d.ts +29 -0
- package/lib/compiler/internal/build/normalizeBuildOutput.js +72 -0
- package/lib/compiler/internal/build/normalizeBuildOutput.js.map +1 -0
- package/lib/compiler/internal/build/parseProjectInputSnapshot.d.ts +26 -0
- package/lib/compiler/internal/build/parseProjectInputSnapshot.js +68 -0
- package/lib/compiler/internal/build/parseProjectInputSnapshot.js.map +1 -0
- package/lib/compiler/internal/build/planResidentCheckEntries.d.ts +21 -0
- package/lib/compiler/internal/build/planResidentCheckEntries.js +45 -0
- package/lib/compiler/internal/build/planResidentCheckEntries.js.map +1 -0
- package/lib/compiler/internal/build/privateRuntimeRootDir.d.ts +20 -0
- package/lib/compiler/internal/build/privateRuntimeRootDir.js +35 -0
- package/lib/compiler/internal/build/privateRuntimeRootDir.js.map +1 -0
- package/lib/compiler/internal/build/residentCheckRequest.d.ts +22 -0
- package/lib/compiler/internal/build/residentCheckRequest.js +42 -0
- package/lib/compiler/internal/build/residentCheckRequest.js.map +1 -0
- package/lib/compiler/internal/build/runBuild.d.ts +22 -0
- package/lib/compiler/internal/build/runBuild.js +44 -0
- package/lib/compiler/internal/build/runBuild.js.map +1 -0
- package/lib/compiler/internal/build/runExternalEmitProvenance.d.ts +61 -0
- package/lib/compiler/internal/build/runExternalEmitProvenance.js +451 -0
- package/lib/compiler/internal/build/runExternalEmitProvenance.js.map +1 -0
- package/lib/compiler/internal/build/takeResidentCheckEntryRequest.d.ts +18 -0
- package/lib/compiler/internal/build/takeResidentCheckEntryRequest.js +28 -0
- package/lib/compiler/internal/build/takeResidentCheckEntryRequest.js.map +1 -0
- package/lib/compiler/internal/buildNativeCompiler.d.ts +16 -1
- package/lib/compiler/internal/buildNativeCompiler.js +14 -2
- package/lib/compiler/internal/buildNativeCompiler.js.map +1 -1
- package/lib/compiler/internal/captureProcessOutput.d.ts +23 -21
- package/lib/compiler/internal/captureProcessOutput.js +40 -26
- package/lib/compiler/internal/captureProcessOutput.js.map +1 -1
- package/lib/compiler/internal/compileProjectInMemory.d.ts +30 -7
- package/lib/compiler/internal/compileProjectInMemory.js +103 -83
- package/lib/compiler/internal/compileProjectInMemory.js.map +1 -1
- package/lib/compiler/internal/ensureExecutable.d.ts +15 -0
- package/lib/compiler/internal/ensureExecutable.js +40 -0
- package/lib/compiler/internal/ensureExecutable.js.map +1 -0
- package/lib/compiler/internal/findNearestGoMod.d.ts +23 -0
- package/lib/compiler/internal/findNearestGoMod.js +48 -0
- package/lib/compiler/internal/findNearestGoMod.js.map +1 -0
- package/lib/compiler/internal/isOutsideRelativePath.d.ts +18 -0
- package/lib/compiler/internal/isOutsideRelativePath.js +30 -0
- package/lib/compiler/internal/isOutsideRelativePath.js.map +1 -0
- package/lib/compiler/internal/outputText.d.ts +16 -0
- package/lib/compiler/internal/outputText.js +25 -0
- package/lib/compiler/internal/outputText.js.map +1 -0
- package/lib/compiler/internal/packageRootDir.d.ts +25 -0
- package/lib/compiler/internal/packageRootDir.js +47 -0
- package/lib/compiler/internal/packageRootDir.js.map +1 -0
- package/lib/compiler/internal/parseNativeTransformOutput.d.ts +88 -0
- package/lib/compiler/internal/parseNativeTransformOutput.js +552 -0
- package/lib/compiler/internal/parseNativeTransformOutput.js.map +1 -0
- package/lib/compiler/internal/project/CompilerProjectSelection.d.ts +80 -0
- package/lib/compiler/internal/project/CompilerProjectSelection.js +187 -0
- package/lib/compiler/internal/project/CompilerProjectSelection.js.map +1 -0
- package/lib/compiler/internal/project/ConfigJsonText.d.ts +50 -0
- package/lib/compiler/internal/project/ConfigJsonText.js +61 -0
- package/lib/compiler/internal/project/ConfigJsonText.js.map +1 -0
- package/lib/compiler/internal/project/compilerUsesCaseSensitiveFileNames.d.ts +48 -0
- package/lib/compiler/internal/project/compilerUsesCaseSensitiveFileNames.js +119 -0
- package/lib/compiler/internal/project/compilerUsesCaseSensitiveFileNames.js.map +1 -0
- package/lib/compiler/internal/project/createNativeProjectContextArgs.d.ts +11 -8
- package/lib/compiler/internal/project/createNativeProjectContextArgs.js +15 -17
- package/lib/compiler/internal/project/createNativeProjectContextArgs.js.map +1 -1
- package/lib/compiler/internal/project/createNativeProjectContextJson.d.ts +19 -0
- package/lib/compiler/internal/project/createNativeProjectContextJson.js +27 -0
- package/lib/compiler/internal/project/createNativeProjectContextJson.js.map +1 -0
- package/lib/compiler/internal/project/parseJsonc.d.ts +42 -0
- package/lib/compiler/internal/project/parseJsonc.js +317 -0
- package/lib/compiler/internal/project/parseJsonc.js.map +1 -0
- package/lib/compiler/internal/project/readJsonFile.d.ts +21 -0
- package/lib/compiler/internal/project/readJsonFile.js +38 -0
- package/lib/compiler/internal/project/readJsonFile.js.map +1 -0
- package/lib/compiler/internal/project/readJsoncFile.d.ts +20 -0
- package/lib/compiler/internal/project/readJsoncFile.js +47 -0
- package/lib/compiler/internal/project/readJsoncFile.js.map +1 -0
- package/lib/compiler/internal/project/readProjectConfig.d.ts +29 -2
- package/lib/compiler/internal/project/readProjectConfig.js +105 -168
- package/lib/compiler/internal/project/readProjectConfig.js.map +1 -1
- package/lib/compiler/internal/project/resolveOwningProjectConfig.d.ts +65 -0
- package/lib/compiler/internal/project/resolveOwningProjectConfig.js +248 -0
- package/lib/compiler/internal/project/resolveOwningProjectConfig.js.map +1 -0
- package/lib/compiler/internal/project/resolveProjectConfig.d.ts +17 -14
- package/lib/compiler/internal/project/resolveProjectConfig.js +19 -122
- package/lib/compiler/internal/project/resolveProjectConfig.js.map +1 -1
- package/lib/compiler/internal/project/resolveProjectIdentity.d.ts +32 -0
- package/lib/compiler/internal/project/resolveProjectIdentity.js +144 -0
- package/lib/compiler/internal/project/resolveProjectIdentity.js.map +1 -0
- package/lib/compiler/internal/project/resolveTsconfigExtends.d.ts +38 -0
- package/lib/compiler/internal/project/resolveTsconfigExtends.js +163 -0
- package/lib/compiler/internal/project/resolveTsconfigExtends.js.map +1 -0
- package/lib/compiler/internal/project/selectReferencedProject.d.ts +26 -0
- package/lib/compiler/internal/project/selectReferencedProject.js +48 -0
- package/lib/compiler/internal/project/selectReferencedProject.js.map +1 -0
- package/lib/compiler/internal/project/tsconfigExtendsFileCandidates.d.ts +34 -0
- package/lib/compiler/internal/project/tsconfigExtendsFileCandidates.js +55 -0
- package/lib/compiler/internal/project/tsconfigExtendsFileCandidates.js.map +1 -0
- package/lib/compiler/internal/readEffectiveCompilerOptions.d.ts +54 -0
- package/lib/compiler/internal/readEffectiveCompilerOptions.js +116 -0
- package/lib/compiler/internal/readEffectiveCompilerOptions.js.map +1 -0
- package/lib/compiler/internal/resolveBinary.d.ts +17 -1
- package/lib/compiler/internal/resolveBinary.js +24 -9
- package/lib/compiler/internal/resolveBinary.js.map +1 -1
- package/lib/compiler/internal/resolveTsgo.d.ts +22 -7
- package/lib/compiler/internal/resolveTsgo.js +25 -9
- package/lib/compiler/internal/resolveTsgo.js.map +1 -1
- package/lib/compiler/internal/runNativeCheckWithObservations.d.ts +41 -0
- package/lib/compiler/internal/runNativeCheckWithObservations.js +185 -0
- package/lib/compiler/internal/runNativeCheckWithObservations.js.map +1 -0
- package/lib/compiler/internal/runSingleFileEmit.d.ts +26 -5
- package/lib/compiler/internal/runSingleFileEmit.js +82 -27
- package/lib/compiler/internal/runSingleFileEmit.js.map +1 -1
- package/lib/compiler/internal/sharedHost/SEMANTIC_CONFIG_PATH_ENV.d.ts +2 -0
- package/lib/compiler/internal/sharedHost/SEMANTIC_CONFIG_PATH_ENV.js +6 -0
- package/lib/compiler/internal/sharedHost/SEMANTIC_CONFIG_PATH_ENV.js.map +1 -0
- package/lib/compiler/internal/sharedHost/SidecarEnvironment.d.ts +90 -0
- package/lib/compiler/internal/sharedHost/SidecarEnvironment.js +153 -0
- package/lib/compiler/internal/sharedHost/SidecarEnvironment.js.map +1 -0
- package/lib/compiler/internal/sharedHost/TSGO_ARGS_CWD_ENV.d.ts +7 -0
- package/lib/compiler/internal/sharedHost/TSGO_ARGS_CWD_ENV.js +11 -0
- package/lib/compiler/internal/sharedHost/TSGO_ARGS_CWD_ENV.js.map +1 -0
- package/lib/compiler/internal/sharedHost/TSGO_ARGS_ENV.d.ts +7 -0
- package/lib/compiler/internal/sharedHost/TSGO_ARGS_ENV.js +11 -0
- package/lib/compiler/internal/sharedHost/TSGO_ARGS_ENV.js.map +1 -0
- package/lib/compiler/internal/sharedHost/assertSharedHostCompatibility.d.ts +24 -0
- package/lib/compiler/internal/sharedHost/assertSharedHostCompatibility.js +46 -0
- package/lib/compiler/internal/sharedHost/assertSharedHostCompatibility.js.map +1 -0
- package/lib/compiler/internal/sharedHost/clearInheritedSemanticConfigPath.d.ts +15 -0
- package/lib/compiler/internal/sharedHost/clearInheritedSemanticConfigPath.js +23 -0
- package/lib/compiler/internal/sharedHost/clearInheritedSemanticConfigPath.js.map +1 -0
- package/lib/compiler/internal/sharedHost/clearInheritedTsgoArgs.d.ts +23 -0
- package/lib/compiler/internal/sharedHost/clearInheritedTsgoArgs.js +33 -0
- package/lib/compiler/internal/sharedHost/clearInheritedTsgoArgs.js.map +1 -0
- package/lib/compiler/internal/sharedHost/inheritedSidecarEnv.d.ts +27 -0
- package/lib/compiler/internal/sharedHost/inheritedSidecarEnv.js +41 -0
- package/lib/compiler/internal/sharedHost/inheritedSidecarEnv.js.map +1 -0
- package/lib/compiler/internal/sharedHost/isLinkedTransform.d.ts +16 -0
- package/lib/compiler/internal/sharedHost/isLinkedTransform.js +21 -0
- package/lib/compiler/internal/sharedHost/isLinkedTransform.js.map +1 -0
- package/lib/compiler/internal/sharedHost/linkedTransformPlugins.d.ts +19 -0
- package/lib/compiler/internal/sharedHost/linkedTransformPlugins.js +25 -0
- package/lib/compiler/internal/sharedHost/linkedTransformPlugins.js.map +1 -0
- package/lib/compiler/internal/sharedHost/publishLinkedTransformPlugins.d.ts +25 -0
- package/lib/compiler/internal/sharedHost/publishLinkedTransformPlugins.js +35 -0
- package/lib/compiler/internal/sharedHost/publishLinkedTransformPlugins.js.map +1 -0
- package/lib/compiler/internal/sharedHost/resolvePluginConfigDir.d.ts +26 -0
- package/lib/compiler/internal/sharedHost/resolvePluginConfigDir.js +36 -0
- package/lib/compiler/internal/sharedHost/resolvePluginConfigDir.js.map +1 -0
- package/lib/compiler/internal/sharedHost/selectSharedHostPlugin.d.ts +22 -0
- package/lib/compiler/internal/sharedHost/selectSharedHostPlugin.js +32 -0
- package/lib/compiler/internal/sharedHost/selectSharedHostPlugin.js.map +1 -0
- package/lib/compiler/internal/spawnNative.d.ts +15 -16
- package/lib/compiler/internal/spawnNative.js +20 -48
- package/lib/compiler/internal/spawnNative.js.map +1 -1
- package/lib/compiler/internal/startResidentTransform.d.ts +26 -17
- package/lib/compiler/internal/startResidentTransform.js +51 -36
- package/lib/compiler/internal/startResidentTransform.js.map +1 -1
- package/lib/compiler/internal/transformProjectInMemory.d.ts +42 -5
- package/lib/compiler/internal/transformProjectInMemory.js +197 -471
- package/lib/compiler/internal/transformProjectInMemory.js.map +1 -1
- package/lib/compiler/internal/transformProjectInWorker.d.ts +49 -0
- package/lib/compiler/internal/transformProjectInWorker.js +168 -0
- package/lib/compiler/internal/transformProjectInWorker.js.map +1 -0
- package/lib/compiler/internal/transformProjectWorker.js +37 -0
- package/lib/compiler/internal/transformProjectWorker.js.map +1 -0
- package/lib/flags/AnySubcommand.d.ts +18 -0
- package/lib/flags/AnySubcommand.js +3 -0
- package/lib/flags/AnySubcommand.js.map +1 -0
- package/lib/flags/COMPILER_ENUM_WHITESPACE.d.ts +2 -0
- package/lib/flags/COMPILER_ENUM_WHITESPACE.js +38 -0
- package/lib/flags/COMPILER_ENUM_WHITESPACE.js.map +1 -0
- package/lib/flags/COMPILER_OPTIONS.d.ts +6 -0
- package/lib/flags/COMPILER_OPTIONS.js +509 -0
- package/lib/flags/COMPILER_OPTIONS.js.map +1 -0
- package/lib/flags/COMPILER_OPTION_ASCII_FOLDS.d.ts +2 -0
- package/lib/flags/COMPILER_OPTION_ASCII_FOLDS.js +13 -0
- package/lib/flags/COMPILER_OPTION_ASCII_FOLDS.js.map +1 -0
- package/lib/flags/COMPILER_OPTION_KINDS.d.ts +2 -0
- package/lib/flags/COMPILER_OPTION_KINDS.js +14 -0
- package/lib/flags/COMPILER_OPTION_KINDS.js.map +1 -0
- package/lib/flags/CompilerOptionSpec.d.ts +27 -0
- package/lib/flags/CompilerOptionSpec.js +3 -0
- package/lib/flags/CompilerOptionSpec.js.map +1 -0
- package/lib/flags/FLAG_BY_TOKEN.d.ts +8 -0
- package/lib/flags/FLAG_BY_TOKEN.js +34 -0
- package/lib/flags/FLAG_BY_TOKEN.js.map +1 -0
- package/lib/flags/FLAG_SCHEMA.d.ts +35 -0
- package/lib/flags/{schema.js → FLAG_SCHEMA.js} +47 -153
- package/lib/flags/FLAG_SCHEMA.js.map +1 -0
- package/lib/flags/FlagKind.d.ts +22 -0
- package/lib/flags/FlagKind.js +3 -0
- package/lib/flags/FlagKind.js.map +1 -0
- package/lib/flags/FlagLayer.d.ts +19 -0
- package/lib/flags/FlagLayer.js +3 -0
- package/lib/flags/FlagLayer.js.map +1 -0
- package/lib/flags/FlagSpec.d.ts +104 -0
- package/lib/flags/FlagSpec.js +3 -0
- package/lib/flags/FlagSpec.js.map +1 -0
- package/lib/flags/ParseOptions.d.ts +92 -0
- package/lib/flags/ParseOptions.js +3 -0
- package/lib/flags/ParseOptions.js.map +1 -0
- package/lib/flags/ParseResult.d.ts +37 -0
- package/lib/flags/ParseResult.js +3 -0
- package/lib/flags/ParseResult.js.map +1 -0
- package/lib/flags/TtscSubcommand.d.ts +14 -0
- package/lib/flags/TtscSubcommand.js +3 -0
- package/lib/flags/TtscSubcommand.js.map +1 -0
- package/lib/flags/TtsxSubcommand.d.ts +13 -0
- package/lib/flags/TtsxSubcommand.js +3 -0
- package/lib/flags/TtsxSubcommand.js.map +1 -0
- package/lib/flags/ValueValidator.d.ts +14 -0
- package/lib/flags/ValueValidator.js +3 -0
- package/lib/flags/ValueValidator.js.map +1 -0
- package/lib/flags/buildGoAllowList.d.ts +18 -0
- package/lib/flags/buildGoAllowList.js +45 -0
- package/lib/flags/buildGoAllowList.js.map +1 -0
- package/lib/flags/flagsForSubcommand.d.ts +18 -0
- package/lib/flags/flagsForSubcommand.js +23 -0
- package/lib/flags/flagsForSubcommand.js.map +1 -0
- package/lib/flags/getBoolean.d.ts +19 -0
- package/lib/flags/getBoolean.js +27 -0
- package/lib/flags/getBoolean.js.map +1 -0
- package/lib/flags/getNumber.d.ts +16 -0
- package/lib/flags/getNumber.js +24 -0
- package/lib/flags/getNumber.js.map +1 -0
- package/lib/flags/getString.d.ts +16 -0
- package/lib/flags/getString.js +24 -0
- package/lib/flags/getString.js.map +1 -0
- package/lib/flags/getStringList.d.ts +19 -0
- package/lib/flags/getStringList.js +24 -0
- package/lib/flags/getStringList.js.map +1 -0
- package/lib/flags/normalizeCompilerEnumValue.d.ts +20 -0
- package/lib/flags/normalizeCompilerEnumValue.js +40 -0
- package/lib/flags/normalizeCompilerEnumValue.js.map +1 -0
- package/lib/flags/normalizeFlagToken.d.ts +28 -0
- package/lib/flags/normalizeFlagToken.js +38 -0
- package/lib/flags/normalizeFlagToken.js.map +1 -0
- package/lib/flags/parseFlags.d.ts +18 -0
- package/lib/flags/parseFlags.js +288 -0
- package/lib/flags/parseFlags.js.map +1 -0
- package/lib/flags/readCompilerOptionOccurrence.d.ts +34 -0
- package/lib/flags/readCompilerOptionOccurrence.js +81 -0
- package/lib/flags/readCompilerOptionOccurrence.js.map +1 -0
- package/lib/flags/readCompilerOptionValues.d.ts +33 -0
- package/lib/flags/readCompilerOptionValues.js +58 -0
- package/lib/flags/readCompilerOptionValues.js.map +1 -0
- package/lib/flags/resolveFlagSpec.d.ts +21 -0
- package/lib/flags/resolveFlagSpec.js +32 -0
- package/lib/flags/resolveFlagSpec.js.map +1 -0
- package/lib/index.d.ts +8 -3
- package/lib/index.js +10 -3
- package/lib/index.js.map +1 -1
- package/lib/internal/CanonicalTempDirectoryOperations.d.ts +73 -0
- package/lib/internal/CanonicalTempDirectoryOperations.js +3 -0
- package/lib/internal/CanonicalTempDirectoryOperations.js.map +1 -0
- package/lib/internal/CompilerContextSnapshot.d.ts +66 -0
- package/lib/internal/CompilerContextSnapshot.js +121 -0
- package/lib/internal/CompilerContextSnapshot.js.map +1 -0
- package/lib/internal/CompilerResultAdapter.d.ts +129 -0
- package/lib/internal/CompilerResultAdapter.js +247 -0
- package/lib/internal/CompilerResultAdapter.js.map +1 -0
- package/lib/internal/E2ETrace.d.ts +219 -0
- package/lib/internal/E2ETrace.js +541 -0
- package/lib/internal/E2ETrace.js.map +1 -0
- package/lib/internal/IJavaScriptRuntimeCapabilities.d.ts +48 -0
- package/lib/internal/IJavaScriptRuntimeCapabilities.js +3 -0
- package/lib/internal/IJavaScriptRuntimeCapabilities.js.map +1 -0
- package/lib/internal/OwnedNativeProcess.d.ts +66 -0
- package/lib/internal/OwnedNativeProcess.js +317 -0
- package/lib/internal/OwnedNativeProcess.js.map +1 -0
- package/lib/internal/OwnedSynchronousProcess.d.ts +158 -0
- package/lib/internal/OwnedSynchronousProcess.js +171 -0
- package/lib/internal/OwnedSynchronousProcess.js.map +1 -0
- package/lib/internal/RetireLockDirectoryOperations.d.ts +77 -0
- package/lib/internal/RetireLockDirectoryOperations.js +3 -0
- package/lib/internal/RetireLockDirectoryOperations.js.map +1 -0
- package/lib/internal/SafeCacheCleanupTarget.d.ts +39 -0
- package/lib/internal/SafeCacheCleanupTarget.js +3 -0
- package/lib/internal/SafeCacheCleanupTarget.js.map +1 -0
- package/lib/internal/SourceNativeRetirement.d.ts +384 -0
- package/lib/internal/SourceNativeRetirement.js +892 -0
- package/lib/internal/SourceNativeRetirement.js.map +1 -0
- package/lib/internal/SpawnSyncOutputFiles.d.ts +28 -0
- package/lib/internal/SpawnSyncOutputFiles.js +3 -0
- package/lib/internal/SpawnSyncOutputFiles.js.map +1 -0
- package/lib/internal/cacheEntryExists.d.ts +13 -0
- package/lib/internal/cacheEntryExists.js +32 -0
- package/lib/internal/cacheEntryExists.js.map +1 -0
- package/lib/internal/createCanonicalTempDirectory.d.ts +23 -13
- package/lib/internal/createCanonicalTempDirectory.js +31 -12
- package/lib/internal/createCanonicalTempDirectory.js.map +1 -1
- package/lib/internal/isContendedCandidateRename.d.ts +27 -0
- package/lib/internal/isContendedCandidateRename.js +37 -0
- package/lib/internal/isContendedCandidateRename.js.map +1 -0
- package/lib/internal/isSpawnSyncFdExhaustion.d.ts +16 -0
- package/lib/internal/isSpawnSyncFdExhaustion.js +23 -0
- package/lib/internal/isSpawnSyncFdExhaustion.js.map +1 -0
- package/lib/internal/javascriptRuntimeCapabilities.d.ts +20 -0
- package/lib/internal/javascriptRuntimeCapabilities.js +142 -0
- package/lib/internal/javascriptRuntimeCapabilities.js.map +1 -0
- package/lib/internal/nativeBinary.d.ts +11 -0
- package/lib/internal/nativeBinary.js +16 -0
- package/lib/internal/nativeBinary.js.map +1 -0
- package/lib/internal/parseWindowsDirectoryCaseSensitivity.d.ts +24 -0
- package/lib/internal/parseWindowsDirectoryCaseSensitivity.js +47 -0
- package/lib/internal/parseWindowsDirectoryCaseSensitivity.js.map +1 -0
- package/lib/internal/pathIdentity/FilesystemPathIdentity.d.ts +43 -0
- package/lib/internal/pathIdentity/FilesystemPathIdentity.js +3 -0
- package/lib/internal/pathIdentity/FilesystemPathIdentity.js.map +1 -0
- package/lib/internal/pathIdentity/FilesystemPathIdentityContext.d.ts +176 -0
- package/lib/internal/pathIdentity/FilesystemPathIdentityContext.js +3 -0
- package/lib/internal/pathIdentity/FilesystemPathIdentityContext.js.map +1 -0
- package/lib/internal/pathIdentity/FilesystemPathIdentityOperations.d.ts +100 -0
- package/lib/internal/pathIdentity/FilesystemPathIdentityOperations.js +3 -0
- package/lib/internal/pathIdentity/FilesystemPathIdentityOperations.js.map +1 -0
- package/lib/internal/pathIdentity/ProjectInputPathIdentity.d.ts +20 -0
- package/lib/internal/pathIdentity/ProjectInputPathIdentity.js +3 -0
- package/lib/internal/pathIdentity/ProjectInputPathIdentity.js.map +1 -0
- package/lib/internal/pathIdentity/ProjectInputPathIdentityContext.d.ts +20 -0
- package/lib/internal/pathIdentity/ProjectInputPathIdentityContext.js +3 -0
- package/lib/internal/pathIdentity/ProjectInputPathIdentityContext.js.map +1 -0
- package/lib/internal/pathIdentity/ProjectInputPathIdentityOperations.d.ts +20 -0
- package/lib/internal/pathIdentity/ProjectInputPathIdentityOperations.js +3 -0
- package/lib/internal/pathIdentity/ProjectInputPathIdentityOperations.js.map +1 -0
- package/lib/internal/pathIdentity/createFilesystemPathIdentityContext.d.ts +25 -0
- package/lib/internal/pathIdentity/createFilesystemPathIdentityContext.js +336 -0
- package/lib/internal/pathIdentity/createFilesystemPathIdentityContext.js.map +1 -0
- package/lib/internal/pathIdentity/createProjectInputPathIdentityContext.d.ts +28 -0
- package/lib/internal/pathIdentity/createProjectInputPathIdentityContext.js +33 -0
- package/lib/internal/pathIdentity/createProjectInputPathIdentityContext.js.map +1 -0
- package/lib/internal/pathIdentity/isFilesystemPathIdentityWithin.d.ts +20 -0
- package/lib/internal/pathIdentity/isFilesystemPathIdentityWithin.js +33 -0
- package/lib/internal/pathIdentity/isFilesystemPathIdentityWithin.js.map +1 -0
- package/lib/internal/pathIdentity/isProjectInputPathIdentityWithin.d.ts +15 -0
- package/lib/internal/pathIdentity/isProjectInputPathIdentityWithin.js +22 -0
- package/lib/internal/pathIdentity/isProjectInputPathIdentityWithin.js.map +1 -0
- package/lib/internal/pathIdentity/resolveFilesystemPath.d.ts +22 -0
- package/lib/internal/pathIdentity/resolveFilesystemPath.js +44 -0
- package/lib/internal/pathIdentity/resolveFilesystemPath.js.map +1 -0
- package/lib/internal/pathIdentity/resolvePhysicalPath.d.ts +21 -0
- package/lib/internal/pathIdentity/resolvePhysicalPath.js +35 -0
- package/lib/internal/pathIdentity/resolvePhysicalPath.js.map +1 -0
- package/lib/internal/pathIdentity/resolveProjectInputPath.d.ts +14 -0
- package/lib/internal/pathIdentity/resolveProjectInputPath.js +21 -0
- package/lib/internal/pathIdentity/resolveProjectInputPath.js.map +1 -0
- package/lib/internal/pluginSource.d.ts +26 -0
- package/lib/internal/pluginSource.js +43 -0
- package/lib/internal/pluginSource.js.map +1 -0
- package/lib/internal/projectInputPathIdentity.d.ts +27 -31
- package/lib/internal/projectInputPathIdentity.js +37 -275
- package/lib/internal/projectInputPathIdentity.js.map +1 -1
- package/lib/internal/resolveNodeBinary.d.ts +9 -7
- package/lib/internal/resolveNodeBinary.js +14 -120
- package/lib/internal/resolveNodeBinary.js.map +1 -1
- package/lib/internal/resolveSafeCacheCleanupTargets.d.ts +27 -8
- package/lib/internal/resolveSafeCacheCleanupTargets.js +44 -11
- package/lib/internal/resolveSafeCacheCleanupTargets.js.map +1 -1
- package/lib/internal/restoreCompilerError.d.ts +21 -0
- package/lib/internal/restoreCompilerError.js +164 -0
- package/lib/internal/restoreCompilerError.js.map +1 -0
- package/lib/internal/retireLockDirectory.d.ts +45 -0
- package/lib/internal/retireLockDirectory.js +152 -0
- package/lib/internal/retireLockDirectory.js.map +1 -0
- package/lib/internal/runHoldingLock.d.ts +30 -0
- package/lib/internal/runHoldingLock.js +53 -0
- package/lib/internal/runHoldingLock.js.map +1 -0
- package/lib/internal/runtimeExecutableIdentity.d.ts +20 -0
- package/lib/internal/runtimeExecutableIdentity.js +171 -0
- package/lib/internal/runtimeExecutableIdentity.js.map +1 -0
- package/lib/internal/serializeCompilerError.d.ts +28 -0
- package/lib/internal/serializeCompilerError.js +138 -0
- package/lib/internal/serializeCompilerError.js.map +1 -0
- package/lib/internal/spawnSyncResilient.d.ts +31 -0
- package/lib/internal/spawnSyncResilient.js +50 -0
- package/lib/internal/spawnSyncResilient.js.map +1 -0
- package/lib/internal/spawnSyncWithLowDescriptors.d.ts +30 -0
- package/lib/internal/spawnSyncWithLowDescriptors.js +194 -0
- package/lib/internal/spawnSyncWithLowDescriptors.js.map +1 -0
- package/lib/internal/tsconfig.d.ts +16 -0
- package/lib/internal/tsconfig.js +33 -0
- package/lib/internal/tsconfig.js.map +1 -0
- package/lib/launcher/internal/PendingResidentCheckWatchChanges.d.ts +56 -0
- package/lib/launcher/internal/PendingResidentCheckWatchChanges.js +97 -0
- package/lib/launcher/internal/PendingResidentCheckWatchChanges.js.map +1 -0
- package/lib/launcher/internal/TtscBuildMode.d.ts +14 -0
- package/lib/launcher/internal/TtscBuildMode.js +3 -0
- package/lib/launcher/internal/TtscBuildMode.js.map +1 -0
- package/lib/launcher/internal/TtsxEntryOptions.d.ts +50 -0
- package/lib/launcher/internal/TtsxEntryOptions.js +94 -0
- package/lib/launcher/internal/TtsxEntryOptions.js.map +1 -0
- package/lib/launcher/internal/assertNoSolutionBuild.d.ts +17 -10
- package/lib/launcher/internal/assertNoSolutionBuild.js +16 -9
- package/lib/launcher/internal/assertNoSolutionBuild.js.map +1 -1
- package/lib/launcher/internal/assertTtsxNoWatch.d.ts +25 -0
- package/lib/launcher/internal/assertTtsxNoWatch.js +46 -0
- package/lib/launcher/internal/assertTtsxNoWatch.js.map +1 -0
- package/lib/launcher/internal/buildSingleRootProject.d.ts +108 -0
- package/lib/launcher/internal/buildSingleRootProject.js +229 -0
- package/lib/launcher/internal/buildSingleRootProject.js.map +1 -0
- package/lib/launcher/internal/getCompilerVersionText.d.ts +14 -1
- package/lib/launcher/internal/getCompilerVersionText.js +21 -6
- package/lib/launcher/internal/getCompilerVersionText.js.map +1 -1
- package/lib/launcher/internal/inlineServedSourceMap.d.ts +35 -0
- package/lib/launcher/internal/inlineServedSourceMap.js +255 -0
- package/lib/launcher/internal/inlineServedSourceMap.js.map +1 -0
- package/lib/launcher/internal/linkVirtualEntry.d.ts +31 -0
- package/lib/launcher/internal/linkVirtualEntry.js +87 -0
- package/lib/launcher/internal/linkVirtualEntry.js.map +1 -0
- package/lib/launcher/internal/parseCommonJsExports.d.ts +17 -0
- package/lib/launcher/internal/{commonJsExportMetadata.js → parseCommonJsExports.js} +13 -3
- package/lib/launcher/internal/parseCommonJsExports.js.map +1 -0
- package/lib/launcher/internal/parseTtscBuildArgs.d.ts +34 -0
- package/lib/launcher/internal/parseTtscBuildArgs.js +97 -0
- package/lib/launcher/internal/parseTtscBuildArgs.js.map +1 -0
- package/lib/launcher/internal/parseTtsxCLI.d.ts +35 -0
- package/lib/launcher/internal/parseTtsxCLI.js +187 -0
- package/lib/launcher/internal/parseTtsxCLI.js.map +1 -0
- package/lib/launcher/internal/prepareExecution.d.ts +49 -5
- package/lib/launcher/internal/prepareExecution.js +360 -324
- package/lib/launcher/internal/prepareExecution.js.map +1 -1
- package/lib/launcher/internal/prepareTtscBuildMode.d.ts +23 -0
- package/lib/launcher/internal/prepareTtscBuildMode.js +58 -0
- package/lib/launcher/internal/prepareTtscBuildMode.js.map +1 -0
- package/lib/launcher/internal/resolveCacheDir.d.ts +12 -3
- package/lib/launcher/internal/resolveCacheDir.js +12 -3
- package/lib/launcher/internal/resolveCacheDir.js.map +1 -1
- package/lib/launcher/internal/resolveSingleFileOutput.d.ts +35 -0
- package/lib/launcher/internal/resolveSingleFileOutput.js +115 -0
- package/lib/launcher/internal/resolveSingleFileOutput.js.map +1 -0
- package/lib/launcher/internal/resolveTtscserverBinary.d.ts +15 -3
- package/lib/launcher/internal/resolveTtscserverBinary.js +19 -5
- package/lib/launcher/internal/resolveTtscserverBinary.js.map +1 -1
- package/lib/launcher/internal/runTtsc.d.ts +23 -23
- package/lib/launcher/internal/runTtsc.js +336 -286
- package/lib/launcher/internal/runTtsc.js.map +1 -1
- package/lib/launcher/internal/runTtsx.d.ts +32 -4
- package/lib/launcher/internal/runTtsx.js +286 -138
- package/lib/launcher/internal/runTtsx.js.map +1 -1
- package/lib/launcher/internal/runtime/CommonJsRuntimeSource.d.ts +92 -0
- package/lib/launcher/internal/runtime/CommonJsRuntimeSource.js +354 -0
- package/lib/launcher/internal/runtime/CommonJsRuntimeSource.js.map +1 -0
- package/lib/launcher/internal/runtime/DependencyBuildAdmission.d.ts +72 -0
- package/lib/launcher/internal/runtime/DependencyBuildAdmission.js +120 -0
- package/lib/launcher/internal/runtime/DependencyBuildAdmission.js.map +1 -0
- package/lib/launcher/internal/runtime/DependencyBuildGeneration.d.ts +185 -0
- package/lib/launcher/internal/runtime/DependencyBuildGeneration.js +153 -0
- package/lib/launcher/internal/runtime/DependencyBuildGeneration.js.map +1 -0
- package/lib/launcher/internal/runtime/DependencyBuildLockFence.d.ts +22 -0
- package/lib/launcher/internal/runtime/DependencyBuildLockFence.js +3 -0
- package/lib/launcher/internal/runtime/DependencyBuildLockFence.js.map +1 -0
- package/lib/launcher/internal/runtime/DependencyBuildLockLease.d.ts +22 -0
- package/lib/launcher/internal/runtime/DependencyBuildLockLease.js +3 -0
- package/lib/launcher/internal/runtime/DependencyBuildLockLease.js.map +1 -0
- package/lib/launcher/internal/runtime/DependencyBuildLockObservation.d.ts +41 -0
- package/lib/launcher/internal/runtime/DependencyBuildLockObservation.js +3 -0
- package/lib/launcher/internal/runtime/DependencyBuildLockObservation.js.map +1 -0
- package/lib/launcher/internal/runtime/DependencyBuildLockProtocol.d.ts +83 -0
- package/lib/launcher/internal/runtime/DependencyBuildLockProtocol.js +126 -0
- package/lib/launcher/internal/runtime/DependencyBuildLockProtocol.js.map +1 -0
- package/lib/launcher/internal/runtime/OwnedProjectSource.d.ts +112 -0
- package/lib/launcher/internal/runtime/OwnedProjectSource.js +59 -0
- package/lib/launcher/internal/runtime/OwnedProjectSource.js.map +1 -0
- package/lib/launcher/internal/runtime/OwningModuleOptions.d.ts +21 -0
- package/lib/launcher/internal/runtime/OwningModuleOptions.js +3 -0
- package/lib/launcher/internal/runtime/OwningModuleOptions.js.map +1 -0
- package/lib/launcher/internal/runtime/PluginDescriptorInputObservation.d.ts +89 -0
- package/lib/launcher/internal/runtime/PluginDescriptorInputObservation.js +115 -0
- package/lib/launcher/internal/runtime/PluginDescriptorInputObservation.js.map +1 -0
- package/lib/launcher/internal/runtime/ProcessOwnedDirectory.d.ts +168 -0
- package/lib/launcher/internal/runtime/ProcessOwnedDirectory.js +251 -0
- package/lib/launcher/internal/runtime/ProcessOwnedDirectory.js.map +1 -0
- package/lib/launcher/internal/runtime/ResolveResult.d.ts +24 -0
- package/lib/launcher/internal/runtime/ResolveResult.js +3 -0
- package/lib/launcher/internal/runtime/ResolveResult.js.map +1 -0
- package/lib/launcher/internal/runtime/RuntimeEmitProvenance.d.ts +38 -0
- package/lib/launcher/internal/runtime/RuntimeEmitProvenance.js +60 -0
- package/lib/launcher/internal/runtime/RuntimeEmitProvenance.js.map +1 -0
- package/lib/launcher/internal/runtime/RuntimeEntryPreparer.d.ts +22 -0
- package/lib/launcher/internal/runtime/RuntimeEntryPreparer.js +3 -0
- package/lib/launcher/internal/runtime/RuntimeEntryPreparer.js.map +1 -0
- package/lib/launcher/internal/runtime/RuntimeFilesystem.d.ts +52 -0
- package/lib/launcher/internal/runtime/RuntimeFilesystem.js +73 -0
- package/lib/launcher/internal/runtime/RuntimeFilesystem.js.map +1 -0
- package/lib/launcher/internal/runtime/RuntimeHookOptions.d.ts +22 -0
- package/lib/launcher/internal/runtime/RuntimeHookOptions.js +3 -0
- package/lib/launcher/internal/runtime/RuntimeHookOptions.js.map +1 -0
- package/lib/launcher/internal/runtime/RuntimeIsolatedEmit.d.ts +53 -0
- package/lib/launcher/internal/runtime/RuntimeIsolatedEmit.js +88 -0
- package/lib/launcher/internal/runtime/RuntimeIsolatedEmit.js.map +1 -0
- package/lib/launcher/internal/runtime/RuntimeLoaderCapabilities.d.ts +78 -0
- package/lib/launcher/internal/runtime/RuntimeLoaderCapabilities.js +256 -0
- package/lib/launcher/internal/runtime/RuntimeLoaderCapabilities.js.map +1 -0
- package/lib/launcher/internal/runtime/RuntimeManifest.d.ts +65 -0
- package/lib/launcher/internal/runtime/RuntimeManifest.js +3 -0
- package/lib/launcher/internal/runtime/RuntimeManifest.js.map +1 -0
- package/lib/launcher/internal/runtime/RuntimeManifestRegistry.d.ts +95 -0
- package/lib/launcher/internal/runtime/RuntimeManifestRegistry.js +268 -0
- package/lib/launcher/internal/runtime/RuntimeManifestRegistry.js.map +1 -0
- package/lib/launcher/internal/runtime/RuntimeModuleFormat.d.ts +60 -0
- package/lib/launcher/internal/runtime/RuntimeModuleFormat.js +249 -0
- package/lib/launcher/internal/runtime/RuntimeModuleFormat.js.map +1 -0
- package/lib/launcher/internal/runtime/RuntimeProjectOwnership.d.ts +50 -0
- package/lib/launcher/internal/runtime/RuntimeProjectOwnership.js +134 -0
- package/lib/launcher/internal/runtime/RuntimeProjectOwnership.js.map +1 -0
- package/lib/launcher/internal/runtime/TTSX_MINIMUM_NODE_VERSION.d.ts +11 -0
- package/lib/launcher/internal/runtime/TTSX_MINIMUM_NODE_VERSION.js +15 -0
- package/lib/launcher/internal/runtime/TTSX_MINIMUM_NODE_VERSION.js.map +1 -0
- package/lib/launcher/internal/runtime/acquireDependencyBuildLock.d.ts +22 -0
- package/lib/launcher/internal/runtime/acquireDependencyBuildLock.js +74 -0
- package/lib/launcher/internal/runtime/acquireDependencyBuildLock.js.map +1 -0
- package/lib/launcher/internal/runtime/checkNodeRuntimeSupport.d.ts +30 -0
- package/lib/launcher/internal/runtime/checkNodeRuntimeSupport.js +83 -0
- package/lib/launcher/internal/runtime/checkNodeRuntimeSupport.js.map +1 -0
- package/lib/launcher/internal/runtime/claimRuntimeProjectDirectory.d.ts +30 -0
- package/lib/launcher/internal/runtime/claimRuntimeProjectDirectory.js +52 -0
- package/lib/launcher/internal/runtime/claimRuntimeProjectDirectory.js.map +1 -0
- package/lib/launcher/internal/runtime/commonJsExportNames.d.ts +21 -0
- package/lib/launcher/internal/runtime/commonJsExportNames.js +68 -0
- package/lib/launcher/internal/runtime/commonJsExportNames.js.map +1 -0
- package/lib/launcher/internal/runtime/commonJsImportFacade.d.ts +32 -0
- package/lib/launcher/internal/runtime/commonJsImportFacade.js +56 -0
- package/lib/launcher/internal/runtime/commonJsImportFacade.js.map +1 -0
- package/lib/launcher/internal/runtime/dependencyCacheKey.d.ts +36 -0
- package/lib/launcher/internal/runtime/dependencyCacheKey.js +57 -0
- package/lib/launcher/internal/runtime/dependencyCacheKey.js.map +1 -0
- package/lib/launcher/internal/runtime/dependencyCacheRoot.d.ts +32 -0
- package/lib/launcher/internal/runtime/dependencyCacheRoot.js +98 -0
- package/lib/launcher/internal/runtime/dependencyCacheRoot.js.map +1 -0
- package/lib/launcher/internal/runtime/inspectDependencyBuildLock.d.ts +23 -0
- package/lib/launcher/internal/runtime/inspectDependencyBuildLock.js +126 -0
- package/lib/launcher/internal/runtime/inspectDependencyBuildLock.js.map +1 -0
- package/lib/launcher/internal/runtime/installRuntimeHooks.d.ts +58 -0
- package/lib/launcher/internal/runtime/installRuntimeHooks.js +1988 -0
- package/lib/launcher/internal/runtime/installRuntimeHooks.js.map +1 -0
- package/lib/launcher/internal/runtime/interopProbe.d.ts +8 -0
- package/lib/launcher/internal/runtime/interopProbe.js +3 -0
- package/lib/launcher/internal/runtime/interopProbe.js.map +1 -0
- package/lib/launcher/internal/runtime/isLocalProcessGone.d.ts +33 -0
- package/lib/launcher/internal/runtime/isLocalProcessGone.js +60 -0
- package/lib/launcher/internal/runtime/isLocalProcessGone.js.map +1 -0
- package/lib/launcher/internal/runtime/observeMappedDescriptorResolution.d.ts +28 -0
- package/lib/launcher/internal/runtime/observeMappedDescriptorResolution.js +50 -0
- package/lib/launcher/internal/runtime/observeMappedDescriptorResolution.js.map +1 -0
- package/lib/launcher/internal/runtime/projectModuleOptions.d.ts +16 -0
- package/lib/launcher/internal/runtime/projectModuleOptions.js +28 -0
- package/lib/launcher/internal/runtime/projectModuleOptions.js.map +1 -0
- package/lib/launcher/internal/runtime/readDependencyCache.d.ts +28 -0
- package/lib/launcher/internal/runtime/readDependencyCache.js +83 -0
- package/lib/launcher/internal/runtime/readDependencyCache.js.map +1 -0
- package/lib/launcher/internal/runtime/realPath.d.ts +22 -0
- package/lib/launcher/internal/runtime/realPath.js +37 -0
- package/lib/launcher/internal/runtime/realPath.js.map +1 -0
- package/lib/launcher/internal/runtime/reclaimDependencyBuildLock.d.ts +17 -0
- package/lib/launcher/internal/runtime/reclaimDependencyBuildLock.js +23 -0
- package/lib/launcher/internal/runtime/reclaimDependencyBuildLock.js.map +1 -0
- package/lib/launcher/internal/runtime/releaseDependencyBuildLock.d.ts +17 -0
- package/lib/launcher/internal/runtime/releaseDependencyBuildLock.js +23 -0
- package/lib/launcher/internal/runtime/releaseDependencyBuildLock.js.map +1 -0
- package/lib/launcher/internal/runtime/resolveRuntimeCleanTargets.d.ts +34 -0
- package/lib/launcher/internal/runtime/resolveRuntimeCleanTargets.js +88 -0
- package/lib/launcher/internal/runtime/resolveRuntimeCleanTargets.js.map +1 -0
- package/lib/launcher/internal/runtime/restoreStrippedNodeBuiltinScheme.d.ts +20 -0
- package/lib/launcher/internal/runtime/restoreStrippedNodeBuiltinScheme.js +30 -0
- package/lib/launcher/internal/runtime/restoreStrippedNodeBuiltinScheme.js.map +1 -0
- package/lib/launcher/internal/runtime/runtimeRunKey.d.ts +24 -0
- package/lib/launcher/internal/runtime/runtimeRunKey.js +36 -0
- package/lib/launcher/internal/runtime/runtimeRunKey.js.map +1 -0
- package/lib/launcher/internal/runtime/selectRuntimePluginPolicy.d.ts +21 -0
- package/lib/launcher/internal/runtime/selectRuntimePluginPolicy.js +29 -0
- package/lib/launcher/internal/runtime/selectRuntimePluginPolicy.js.map +1 -0
- package/lib/launcher/internal/runtime/withRuntimeDirectoryLock.d.ts +35 -0
- package/lib/launcher/internal/runtime/withRuntimeDirectoryLock.js +76 -0
- package/lib/launcher/internal/runtime/withRuntimeDirectoryLock.js.map +1 -0
- package/lib/launcher/internal/runtimeCompilerArgs.d.ts +35 -6
- package/lib/launcher/internal/runtimeCompilerArgs.js +87 -58
- package/lib/launcher/internal/runtimeCompilerArgs.js.map +1 -1
- package/lib/launcher/internal/runtimeEmitProfile.d.ts +39 -0
- package/lib/launcher/internal/runtimeEmitProfile.js +56 -0
- package/lib/launcher/internal/runtimeEmitProfile.js.map +1 -0
- package/lib/launcher/internal/runtimeHookPreload.js +4 -4
- package/lib/launcher/internal/runtimeHookPreload.js.map +1 -1
- package/lib/launcher/internal/runtimeOwnerPreload.d.ts +1 -0
- package/lib/launcher/internal/runtimeOwnerPreload.js +43 -0
- package/lib/launcher/internal/runtimeOwnerPreload.js.map +1 -0
- package/lib/launcher/internal/singleRootProjectConfig.d.ts +34 -0
- package/lib/launcher/internal/singleRootProjectConfig.js +39 -0
- package/lib/launcher/internal/singleRootProjectConfig.js.map +1 -0
- package/lib/launcher/internal/ttscserver/ILSPPluginSelectionInputs.d.ts +61 -0
- package/lib/launcher/internal/ttscserver/ILSPPluginSelectionInputs.js +3 -0
- package/lib/launcher/internal/ttscserver/ILSPPluginSelectionInputs.js.map +1 -0
- package/lib/launcher/internal/ttscserver/LSPProjectInputDigest.d.ts +95 -0
- package/lib/launcher/internal/ttscserver/LSPProjectInputDigest.js +270 -0
- package/lib/launcher/internal/ttscserver/LSPProjectInputDigest.js.map +1 -0
- package/lib/launcher/internal/ttscserver/captureLSPPluginSelectionInputs.d.ts +46 -0
- package/lib/launcher/internal/ttscserver/captureLSPPluginSelectionInputs.js +91 -0
- package/lib/launcher/internal/ttscserver/captureLSPPluginSelectionInputs.js.map +1 -0
- package/lib/launcher/internal/ttscserver/fingerprintInitialLSPProjectInputSnapshot.d.ts +21 -0
- package/lib/launcher/internal/ttscserver/fingerprintInitialLSPProjectInputSnapshot.js +39 -0
- package/lib/launcher/internal/ttscserver/fingerprintInitialLSPProjectInputSnapshot.js.map +1 -0
- package/lib/launcher/internal/ttscserver/initialLSPProjectInputSnapshotIsCurrent.d.ts +18 -0
- package/lib/launcher/internal/ttscserver/initialLSPProjectInputSnapshotIsCurrent.js +27 -0
- package/lib/launcher/internal/ttscserver/initialLSPProjectInputSnapshotIsCurrent.js.map +1 -0
- package/lib/launcher/internal/ttscserver/materializeLSPPluginManifest.d.ts +26 -0
- package/lib/launcher/internal/ttscserver/materializeLSPPluginManifest.js +62 -0
- package/lib/launcher/internal/ttscserver/materializeLSPPluginManifest.js.map +1 -0
- package/lib/launcher/internal/ttscserver/needsStdio.d.ts +17 -0
- package/lib/launcher/internal/ttscserver/needsStdio.js +36 -0
- package/lib/launcher/internal/ttscserver/needsStdio.js.map +1 -0
- package/lib/launcher/internal/ttscserver/runTtscserver.d.ts +25 -0
- package/lib/launcher/internal/ttscserver/runTtscserver.js +439 -0
- package/lib/launcher/internal/ttscserver/runTtscserver.js.map +1 -0
- package/lib/launcher/internal/watch/CompilerDirectoryWatchEventPlan.d.ts +29 -0
- package/lib/launcher/internal/watch/CompilerDirectoryWatchEventPlan.js +3 -0
- package/lib/launcher/internal/watch/CompilerDirectoryWatchEventPlan.js.map +1 -0
- package/lib/launcher/internal/watch/DirectoryWatcher.d.ts +44 -0
- package/lib/launcher/internal/watch/DirectoryWatcher.js +3 -0
- package/lib/launcher/internal/watch/DirectoryWatcher.js.map +1 -0
- package/lib/launcher/internal/watch/FseventsStreams.d.ts +87 -0
- package/lib/launcher/internal/watch/FseventsStreams.js +266 -0
- package/lib/launcher/internal/watch/FseventsStreams.js.map +1 -0
- package/lib/launcher/internal/watch/ProjectInputWatchRules.d.ts +92 -0
- package/lib/launcher/internal/watch/ProjectInputWatchRules.js +163 -0
- package/lib/launcher/internal/watch/ProjectInputWatchRules.js.map +1 -0
- package/lib/launcher/internal/watch/WatchInputChange.d.ts +29 -0
- package/lib/launcher/internal/watch/WatchInputChange.js +3 -0
- package/lib/launcher/internal/watch/WatchInputChange.js.map +1 -0
- package/lib/launcher/internal/watch/WatchPaths.d.ts +101 -0
- package/lib/launcher/internal/watch/WatchPaths.js +150 -0
- package/lib/launcher/internal/watch/WatchPaths.js.map +1 -0
- package/lib/launcher/internal/watch/WatchTopology.d.ts +384 -0
- package/lib/launcher/internal/{watchTopology.js → watch/WatchTopology.js} +726 -799
- package/lib/launcher/internal/watch/WatchTopology.js.map +1 -0
- package/lib/launcher/internal/watch/literalGlobRoot.d.ts +22 -0
- package/lib/launcher/internal/watch/literalGlobRoot.js +45 -0
- package/lib/launcher/internal/watch/literalGlobRoot.js.map +1 -0
- package/lib/launcher/internal/watch/planCompilerDirectoryWatchEvent.d.ts +40 -0
- package/lib/launcher/internal/watch/planCompilerDirectoryWatchEvent.js +69 -0
- package/lib/launcher/internal/watch/planCompilerDirectoryWatchEvent.js.map +1 -0
- package/lib/launcher/internal/watch/projectInputActiveWatchDirectories.d.ts +19 -0
- package/lib/launcher/internal/watch/projectInputActiveWatchDirectories.js +52 -0
- package/lib/launcher/internal/watch/projectInputActiveWatchDirectories.js.map +1 -0
- package/lib/launcher/internal/watch/projectInputAvailableWatchDirectory.d.ts +21 -0
- package/lib/launcher/internal/watch/projectInputAvailableWatchDirectory.js +55 -0
- package/lib/launcher/internal/watch/projectInputAvailableWatchDirectory.js.map +1 -0
- package/lib/launcher/internal/watch/projectInputEventShouldNotify.d.ts +21 -0
- package/lib/launcher/internal/watch/projectInputEventShouldNotify.js +23 -0
- package/lib/launcher/internal/watch/projectInputEventShouldNotify.js.map +1 -0
- package/lib/launcher/internal/watch/projectInputMembershipInvalidatesProgram.d.ts +27 -0
- package/lib/launcher/internal/watch/projectInputMembershipInvalidatesProgram.js +54 -0
- package/lib/launcher/internal/watch/projectInputMembershipInvalidatesProgram.js.map +1 -0
- package/lib/launcher/internal/watch/projectInputReloadEventShouldNotify.d.ts +26 -0
- package/lib/launcher/internal/watch/projectInputReloadEventShouldNotify.js +100 -0
- package/lib/launcher/internal/watch/projectInputReloadEventShouldNotify.js.map +1 -0
- package/lib/launcher/internal/watch/projectInputReplacementStrandsWatchers.d.ts +37 -0
- package/lib/launcher/internal/watch/projectInputReplacementStrandsWatchers.js +54 -0
- package/lib/launcher/internal/watch/projectInputReplacementStrandsWatchers.js.map +1 -0
- package/lib/launcher/internal/watch/projectInputTopologyMayAffect.d.ts +23 -0
- package/lib/launcher/internal/watch/projectInputTopologyMayAffect.js +67 -0
- package/lib/launcher/internal/watch/projectInputTopologyMayAffect.js.map +1 -0
- package/lib/launcher/internal/watch/projectInputWatchDirectories.d.ts +22 -0
- package/lib/launcher/internal/watch/projectInputWatchDirectories.js +30 -0
- package/lib/launcher/internal/watch/projectInputWatchDirectories.js.map +1 -0
- package/lib/launcher/internal/watch/reloadInputsForFailedTopologyRefresh.d.ts +22 -0
- package/lib/launcher/internal/watch/reloadInputsForFailedTopologyRefresh.js +45 -0
- package/lib/launcher/internal/watch/reloadInputsForFailedTopologyRefresh.js.map +1 -0
- package/lib/launcher/internal/watch/syncWatchers.d.ts +25 -0
- package/lib/launcher/internal/watch/syncWatchers.js +61 -0
- package/lib/launcher/internal/watch/syncWatchers.js.map +1 -0
- package/lib/launcher/internal/watch/watchDirectory.d.ts +28 -0
- package/lib/launcher/internal/watch/watchDirectory.js +46 -0
- package/lib/launcher/internal/watch/watchDirectory.js.map +1 -0
- package/lib/launcher/internal/watch/watchDirectoryThroughFsWatch.d.ts +28 -0
- package/lib/launcher/internal/watch/watchDirectoryThroughFsWatch.js +38 -0
- package/lib/launcher/internal/watch/watchDirectoryThroughFsWatch.js.map +1 -0
- package/lib/launcher/ttscserver.js +1 -1
- package/lib/launcher/ttscserver.js.map +1 -1
- package/lib/launcher/ttsx.js +2 -3
- package/lib/launcher/ttsx.js.map +1 -1
- package/lib/plugin/CapabilityPluginResolver.d.ts +140 -0
- package/lib/plugin/CapabilityPluginResolver.js +400 -0
- package/lib/plugin/CapabilityPluginResolver.js.map +1 -0
- package/lib/plugin/ITtscCapabilityPlugin.d.ts +87 -0
- package/lib/plugin/ITtscCapabilityPlugin.js +3 -0
- package/lib/plugin/ITtscCapabilityPlugin.js.map +1 -0
- package/lib/plugin/internal/CapabilityPluginResult.d.ts +66 -0
- package/lib/plugin/internal/CapabilityPluginResult.js +86 -0
- package/lib/plugin/internal/CapabilityPluginResult.js.map +1 -0
- package/lib/plugin/internal/CapabilityResolutionFormat.d.ts +114 -0
- package/lib/plugin/internal/CapabilityResolutionFormat.js +229 -0
- package/lib/plugin/internal/CapabilityResolutionFormat.js.map +1 -0
- package/lib/plugin/internal/ITtscCapabilityPluginSource.d.ts +35 -0
- package/lib/plugin/internal/ITtscCapabilityPluginSource.js +3 -0
- package/lib/plugin/internal/ITtscCapabilityPluginSource.js.map +1 -0
- package/lib/plugin/internal/ITtscCapabilityResolutionEntry.d.ts +49 -0
- package/lib/plugin/internal/ITtscCapabilityResolutionEntry.js +3 -0
- package/lib/plugin/internal/ITtscCapabilityResolutionEntry.js.map +1 -0
- package/lib/plugin/internal/ITtscCapabilityResolutionPlugin.d.ts +21 -0
- package/lib/plugin/internal/ITtscCapabilityResolutionPlugin.js +3 -0
- package/lib/plugin/internal/ITtscCapabilityResolutionPlugin.js.map +1 -0
- package/lib/plugin/internal/capabilityPluginWorker.d.ts +1 -0
- package/lib/plugin/internal/capabilityPluginWorker.js +178 -0
- package/lib/plugin/internal/capabilityPluginWorker.js.map +1 -0
- package/lib/plugin/internal/decodeCapabilityCommandReply.d.ts +23 -0
- package/lib/plugin/internal/decodeCapabilityCommandReply.js +25 -0
- package/lib/plugin/internal/decodeCapabilityCommandReply.js.map +1 -0
- package/lib/plugin/internal/load/COMMONJS_PLUGIN_DESCRIPTOR_SHIM_SOURCE.d.ts +15 -0
- package/lib/plugin/internal/load/COMMONJS_PLUGIN_DESCRIPTOR_SHIM_SOURCE.js +182 -0
- package/lib/plugin/internal/load/COMMONJS_PLUGIN_DESCRIPTOR_SHIM_SOURCE.js.map +1 -0
- package/lib/plugin/internal/load/PLUGIN_DESCRIPTOR_SHIM_SOURCE.d.ts +11 -0
- package/lib/plugin/internal/load/PLUGIN_DESCRIPTOR_SHIM_SOURCE.js +62 -0
- package/lib/plugin/internal/load/PLUGIN_DESCRIPTOR_SHIM_SOURCE.js.map +1 -0
- package/lib/plugin/internal/load/PluginDescriptorAdmission.d.ts +46 -0
- package/lib/plugin/internal/load/PluginDescriptorAdmission.js +72 -0
- package/lib/plugin/internal/load/PluginDescriptorAdmission.js.map +1 -0
- package/lib/plugin/internal/load/PluginDescriptorEvaluationCache.d.ts +154 -0
- package/lib/plugin/internal/load/PluginDescriptorEvaluationCache.js +317 -0
- package/lib/plugin/internal/load/PluginDescriptorEvaluationCache.js.map +1 -0
- package/lib/plugin/internal/load/PluginPackageResolution.d.ts +208 -0
- package/lib/plugin/internal/load/PluginPackageResolution.js +593 -0
- package/lib/plugin/internal/load/PluginPackageResolution.js.map +1 -0
- package/lib/plugin/internal/load/ProjectPluginEntries.d.ts +60 -0
- package/lib/plugin/internal/load/ProjectPluginEntries.js +164 -0
- package/lib/plugin/internal/load/ProjectPluginEntries.js.map +1 -0
- package/lib/plugin/internal/load/RESOLUTION_INPUT_RECORDER_PATH.d.ts +13 -0
- package/lib/plugin/internal/load/RESOLUTION_INPUT_RECORDER_PATH.js +21 -0
- package/lib/plugin/internal/load/RESOLUTION_INPUT_RECORDER_PATH.js.map +1 -0
- package/lib/plugin/internal/load/collectProjectHostInputs.d.ts +16 -0
- package/lib/plugin/internal/load/collectProjectHostInputs.js +66 -0
- package/lib/plugin/internal/load/collectProjectHostInputs.js.map +1 -0
- package/lib/plugin/internal/load/composePluginSources.d.ts +20 -0
- package/lib/plugin/internal/load/composePluginSources.js +95 -0
- package/lib/plugin/internal/load/composePluginSources.js.map +1 -0
- package/lib/plugin/internal/load/declaresHostInputReads.d.ts +24 -0
- package/lib/plugin/internal/load/declaresHostInputReads.js +48 -0
- package/lib/plugin/internal/load/declaresHostInputReads.js.map +1 -0
- package/lib/plugin/internal/load/hasProjectPluginEntries.d.ts +21 -0
- package/lib/plugin/internal/load/hasProjectPluginEntries.js +29 -0
- package/lib/plugin/internal/load/hasProjectPluginEntries.js.map +1 -0
- package/lib/plugin/internal/load/hashHostInputPaths.d.ts +17 -0
- package/lib/plugin/internal/load/hashHostInputPaths.js +46 -0
- package/lib/plugin/internal/load/hashHostInputPaths.js.map +1 -0
- package/lib/plugin/internal/load/isRelativePluginSpecifier.d.ts +22 -0
- package/lib/plugin/internal/load/isRelativePluginSpecifier.js +33 -0
- package/lib/plugin/internal/load/isRelativePluginSpecifier.js.map +1 -0
- package/lib/plugin/internal/load/loadProjectPlugins.d.ts +113 -0
- package/lib/plugin/internal/load/loadProjectPlugins.js +1615 -0
- package/lib/plugin/internal/load/loadProjectPlugins.js.map +1 -0
- package/lib/plugin/internal/load/moduleResolutionBaseSelects.d.ts +42 -0
- package/lib/plugin/internal/load/moduleResolutionBaseSelects.js +51 -0
- package/lib/plugin/internal/load/moduleResolutionBaseSelects.js.map +1 -0
- package/lib/plugin/internal/load/observeImportSearchRoots.d.ts +29 -0
- package/lib/plugin/internal/load/observeImportSearchRoots.js +38 -0
- package/lib/plugin/internal/load/observeImportSearchRoots.js.map +1 -0
- package/lib/plugin/internal/load/pluginLabel.d.ts +15 -0
- package/lib/plugin/internal/load/pluginLabel.js +25 -0
- package/lib/plugin/internal/load/pluginLabel.js.map +1 -0
- package/lib/plugin/internal/load/realpathHostInput.d.ts +14 -0
- package/lib/plugin/internal/load/realpathHostInput.js +29 -0
- package/lib/plugin/internal/load/realpathHostInput.js.map +1 -0
- package/lib/plugin/internal/load/realpathHostInputPaths.d.ts +17 -0
- package/lib/plugin/internal/load/realpathHostInputPaths.js +28 -0
- package/lib/plugin/internal/load/realpathHostInputPaths.js.map +1 -0
- package/lib/plugin/internal/load/rejectJsTransformFunctions.d.ts +13 -0
- package/lib/plugin/internal/load/rejectJsTransformFunctions.js +22 -0
- package/lib/plugin/internal/load/rejectJsTransformFunctions.js.map +1 -0
- package/lib/plugin/internal/load/requirePluginSource.d.ts +14 -0
- package/lib/plugin/internal/load/requirePluginSource.js +38 -0
- package/lib/plugin/internal/load/requirePluginSource.js.map +1 -0
- package/lib/plugin/internal/load/resolveNativeSource.d.ts +29 -0
- package/lib/plugin/internal/load/resolveNativeSource.js +37 -0
- package/lib/plugin/internal/load/resolveNativeSource.js.map +1 -0
- package/lib/plugin/internal/load/validatePluginContributors.d.ts +22 -0
- package/lib/plugin/internal/load/validatePluginContributors.js +86 -0
- package/lib/plugin/internal/load/validatePluginContributors.js.map +1 -0
- package/lib/plugin/internal/load/validatePluginSource.d.ts +14 -0
- package/lib/plugin/internal/load/validatePluginSource.js +21 -0
- package/lib/plugin/internal/load/validatePluginSource.js.map +1 -0
- package/lib/plugin/internal/load/visitImportMappedCandidates.d.ts +36 -0
- package/lib/plugin/internal/load/visitImportMappedCandidates.js +45 -0
- package/lib/plugin/internal/load/visitImportMappedCandidates.js.map +1 -0
- package/lib/plugin/internal/pluginDescriptorFailureReason.d.ts +23 -0
- package/lib/plugin/internal/pluginDescriptorFailureReason.js +43 -0
- package/lib/plugin/internal/pluginDescriptorFailureReason.js.map +1 -0
- package/lib/plugin/internal/pluginDescriptorProcessFailure.d.ts +28 -0
- package/lib/plugin/internal/pluginDescriptorProcessFailure.js +37 -0
- package/lib/plugin/internal/pluginDescriptorProcessFailure.js.map +1 -0
- package/lib/plugin/internal/readCapabilityResolution.d.ts +42 -0
- package/lib/plugin/internal/readCapabilityResolution.js +158 -0
- package/lib/plugin/internal/readCapabilityResolution.js.map +1 -0
- package/lib/plugin/internal/receiveCapabilityFailure.d.ts +21 -0
- package/lib/plugin/internal/receiveCapabilityFailure.js +28 -0
- package/lib/plugin/internal/receiveCapabilityFailure.js.map +1 -0
- package/lib/plugin/internal/source/CachePrunePolicy.d.ts +42 -0
- package/lib/plugin/internal/source/CachePrunePolicy.js +47 -0
- package/lib/plugin/internal/source/CachePrunePolicy.js.map +1 -0
- package/lib/plugin/internal/source/GoBuildCacheCoordination.d.ts +159 -0
- package/lib/plugin/internal/source/GoBuildCacheCoordination.js +475 -0
- package/lib/plugin/internal/source/GoBuildCacheCoordination.js.map +1 -0
- package/lib/plugin/internal/source/GoSourceInputs.d.ts +124 -0
- package/lib/plugin/internal/source/GoSourceInputs.js +180 -0
- package/lib/plugin/internal/source/GoSourceInputs.js.map +1 -0
- package/lib/plugin/internal/source/GoToolResolution.d.ts +125 -0
- package/lib/plugin/internal/source/GoToolResolution.js +278 -0
- package/lib/plugin/internal/source/GoToolResolution.js.map +1 -0
- package/lib/plugin/internal/source/IGoBuildCachePruneOptions.d.ts +30 -0
- package/lib/plugin/internal/source/IGoBuildCachePruneOptions.js +3 -0
- package/lib/plugin/internal/source/IGoBuildCachePruneOptions.js.map +1 -0
- package/lib/plugin/internal/source/IPluginCachePruneOptions.d.ts +33 -0
- package/lib/plugin/internal/source/IPluginCachePruneOptions.js +3 -0
- package/lib/plugin/internal/source/IPluginCachePruneOptions.js.map +1 -0
- package/lib/plugin/internal/source/IPluginModuleReplaceDirectory.d.ts +27 -0
- package/lib/plugin/internal/source/IPluginModuleReplaceDirectory.js +3 -0
- package/lib/plugin/internal/source/IPluginModuleReplaceDirectory.js.map +1 -0
- package/lib/plugin/internal/source/ITtscBuildContributor.d.ts +18 -0
- package/lib/plugin/internal/source/ITtscBuildContributor.js +3 -0
- package/lib/plugin/internal/source/ITtscBuildContributor.js.map +1 -0
- package/lib/plugin/internal/source/ITtscSourceBuildCachePaths.d.ts +25 -0
- package/lib/plugin/internal/source/ITtscSourceBuildCachePaths.js +3 -0
- package/lib/plugin/internal/source/ITtscSourceBuildCachePaths.js.map +1 -0
- package/lib/plugin/internal/source/NativeSourcePackages.d.ts +155 -0
- package/lib/plugin/internal/source/NativeSourcePackages.js +317 -0
- package/lib/plugin/internal/source/NativeSourcePackages.js.map +1 -0
- package/lib/plugin/internal/source/PluginBinaryUse.d.ts +66 -0
- package/lib/plugin/internal/source/PluginBinaryUse.js +163 -0
- package/lib/plugin/internal/source/PluginBinaryUse.js.map +1 -0
- package/lib/plugin/internal/source/PluginBinaryWaitResult.d.ts +34 -0
- package/lib/plugin/internal/source/PluginBinaryWaitResult.js +3 -0
- package/lib/plugin/internal/source/PluginBinaryWaitResult.js.map +1 -0
- package/lib/plugin/internal/source/PluginBuildEnvironmentReadings.d.ts +90 -0
- package/lib/plugin/internal/source/PluginBuildEnvironmentReadings.js +207 -0
- package/lib/plugin/internal/source/PluginBuildEnvironmentReadings.js.map +1 -0
- package/lib/plugin/internal/source/PluginBuildEnvironmentWitness.d.ts +128 -0
- package/lib/plugin/internal/source/PluginBuildEnvironmentWitness.js +209 -0
- package/lib/plugin/internal/source/PluginBuildEnvironmentWitness.js.map +1 -0
- package/lib/plugin/internal/source/PluginBuildLockFence.d.ts +25 -0
- package/lib/plugin/internal/source/PluginBuildLockFence.js +3 -0
- package/lib/plugin/internal/source/PluginBuildLockFence.js.map +1 -0
- package/lib/plugin/internal/source/PluginBuildLockLease.d.ts +29 -0
- package/lib/plugin/internal/source/PluginBuildLockLease.js +3 -0
- package/lib/plugin/internal/source/PluginBuildLockLease.js.map +1 -0
- package/lib/plugin/internal/source/PluginBuildLockObservation.d.ts +42 -0
- package/lib/plugin/internal/source/PluginBuildLockObservation.js +3 -0
- package/lib/plugin/internal/source/PluginBuildLockObservation.js.map +1 -0
- package/lib/plugin/internal/source/PluginBuildLockOwner.d.ts +126 -0
- package/lib/plugin/internal/source/PluginBuildLockOwner.js +165 -0
- package/lib/plugin/internal/source/PluginBuildLockOwner.js.map +1 -0
- package/lib/plugin/internal/source/PluginBuildLockProtocol.d.ts +234 -0
- package/lib/plugin/internal/source/PluginBuildLockProtocol.js +287 -0
- package/lib/plugin/internal/source/PluginBuildLockProtocol.js.map +1 -0
- package/lib/plugin/internal/source/SourceBuildCacheLayout.d.ts +183 -0
- package/lib/plugin/internal/source/SourceBuildCacheLayout.js +291 -0
- package/lib/plugin/internal/source/SourceBuildCacheLayout.js.map +1 -0
- package/lib/plugin/internal/source/SourceBuildFilesystemOperations.d.ts +32 -0
- package/lib/plugin/internal/source/SourceBuildFilesystemOperations.js +3 -0
- package/lib/plugin/internal/source/SourceBuildFilesystemOperations.js.map +1 -0
- package/lib/plugin/internal/source/SourcePluginAdmission.d.ts +80 -0
- package/lib/plugin/internal/source/SourcePluginAdmission.js +114 -0
- package/lib/plugin/internal/source/SourcePluginAdmission.js.map +1 -0
- package/lib/plugin/internal/source/SourcePluginWorkspace.d.ts +122 -0
- package/lib/plugin/internal/source/SourcePluginWorkspace.js +307 -0
- package/lib/plugin/internal/source/SourcePluginWorkspace.js.map +1 -0
- package/lib/plugin/internal/source/acquirePluginBuildLock.d.ts +35 -0
- package/lib/plugin/internal/source/acquirePluginBuildLock.js +176 -0
- package/lib/plugin/internal/source/acquirePluginBuildLock.js.map +1 -0
- package/lib/plugin/internal/source/autoQuoteGoModToken.d.ts +24 -0
- package/lib/plugin/internal/source/autoQuoteGoModToken.js +110 -0
- package/lib/plugin/internal/source/autoQuoteGoModToken.js.map +1 -0
- package/lib/plugin/internal/source/buildSourcePlugin.d.ts +86 -0
- package/lib/plugin/internal/source/buildSourcePlugin.js +857 -0
- package/lib/plugin/internal/source/buildSourcePlugin.js.map +1 -0
- package/lib/plugin/internal/source/collectPluginSourceDirectories.d.ts +30 -0
- package/lib/plugin/internal/source/collectPluginSourceDirectories.js +77 -0
- package/lib/plugin/internal/source/collectPluginSourceDirectories.js.map +1 -0
- package/lib/plugin/internal/source/collectPluginSourceFiles.d.ts +40 -0
- package/lib/plugin/internal/source/collectPluginSourceFiles.js +95 -0
- package/lib/plugin/internal/source/collectPluginSourceFiles.js.map +1 -0
- package/lib/plugin/internal/source/computeCacheKey.d.ts +73 -0
- package/lib/plugin/internal/source/computeCacheKey.js +113 -0
- package/lib/plugin/internal/source/computeCacheKey.js.map +1 -0
- package/lib/plugin/internal/source/copiesPluginSourceEntry.d.ts +33 -0
- package/lib/plugin/internal/source/copiesPluginSourceEntry.js +57 -0
- package/lib/plugin/internal/source/copiesPluginSourceEntry.js.map +1 -0
- package/lib/plugin/internal/source/createExternalSourceSnapshotLayout.d.ts +22 -0
- package/lib/plugin/internal/source/createExternalSourceSnapshotLayout.js +60 -0
- package/lib/plugin/internal/source/createExternalSourceSnapshotLayout.js.map +1 -0
- package/lib/plugin/internal/source/ensureExecutableGoToolchain.d.ts +25 -0
- package/lib/plugin/internal/source/ensureExecutableGoToolchain.js +96 -0
- package/lib/plugin/internal/source/ensureExecutableGoToolchain.js.map +1 -0
- package/lib/plugin/internal/source/formatDuration.d.ts +18 -0
- package/lib/plugin/internal/source/formatDuration.js +36 -0
- package/lib/plugin/internal/source/formatDuration.js.map +1 -0
- package/lib/plugin/internal/source/formatGoWorkPath.d.ts +35 -0
- package/lib/plugin/internal/source/formatGoWorkPath.js +42 -0
- package/lib/plugin/internal/source/formatGoWorkPath.js.map +1 -0
- package/lib/plugin/internal/source/hashPluginBuildEnvironment.d.ts +47 -0
- package/lib/plugin/internal/source/hashPluginBuildEnvironment.js +663 -0
- package/lib/plugin/internal/source/hashPluginBuildEnvironment.js.map +1 -0
- package/lib/plugin/internal/source/inspectPluginBuildLock.d.ts +29 -0
- package/lib/plugin/internal/source/inspectPluginBuildLock.js +285 -0
- package/lib/plugin/internal/source/inspectPluginBuildLock.js.map +1 -0
- package/lib/plugin/internal/source/isPathWithin.d.ts +16 -0
- package/lib/plugin/internal/source/isPathWithin.js +28 -0
- package/lib/plugin/internal/source/isPathWithin.js.map +1 -0
- package/lib/plugin/internal/source/legacyGlobalCacheTargets.d.ts +24 -0
- package/lib/plugin/internal/source/legacyGlobalCacheTargets.js +60 -0
- package/lib/plugin/internal/source/legacyGlobalCacheTargets.js.map +1 -0
- package/lib/plugin/internal/source/pluginBuildEnvironment.d.ts +31 -0
- package/lib/plugin/internal/source/pluginBuildEnvironment.js +47 -0
- package/lib/plugin/internal/source/pluginBuildEnvironment.js.map +1 -0
- package/lib/plugin/internal/source/pluginBuildEnvironmentWorker.d.ts +1 -0
- package/lib/plugin/internal/source/pluginBuildEnvironmentWorker.js +24 -0
- package/lib/plugin/internal/source/pluginBuildEnvironmentWorker.js.map +1 -0
- package/lib/plugin/internal/source/pluginBuildVersions.d.ts +31 -0
- package/lib/plugin/internal/source/pluginBuildVersions.js +65 -0
- package/lib/plugin/internal/source/pluginBuildVersions.js.map +1 -0
- package/lib/plugin/internal/source/pluginModuleReplaceDirectories.d.ts +40 -0
- package/lib/plugin/internal/source/pluginModuleReplaceDirectories.js +81 -0
- package/lib/plugin/internal/source/pluginModuleReplaceDirectories.js.map +1 -0
- package/lib/plugin/internal/source/pluginSourceCovers.d.ts +32 -0
- package/lib/plugin/internal/source/pluginSourceCovers.js +54 -0
- package/lib/plugin/internal/source/pluginSourceCovers.js.map +1 -0
- package/lib/plugin/internal/source/pluginSourceDigest.d.ts +40 -0
- package/lib/plugin/internal/source/pluginSourceDigest.js +60 -0
- package/lib/plugin/internal/source/pluginSourceDigest.js.map +1 -0
- package/lib/plugin/internal/source/pluginSourceFilesSignature.d.ts +38 -0
- package/lib/plugin/internal/source/pluginSourceFilesSignature.js +53 -0
- package/lib/plugin/internal/source/pluginSourceFilesSignature.js.map +1 -0
- package/lib/plugin/internal/source/pluginSourceState.d.ts +47 -0
- package/lib/plugin/internal/source/pluginSourceState.js +63 -0
- package/lib/plugin/internal/source/pluginSourceState.js.map +1 -0
- package/lib/plugin/internal/source/pluginSourceStateHolds.d.ts +34 -0
- package/lib/plugin/internal/source/pluginSourceStateHolds.js +45 -0
- package/lib/plugin/internal/source/pluginSourceStateHolds.js.map +1 -0
- package/lib/plugin/internal/source/processPluginBuildEnvironment.d.ts +33 -0
- package/lib/plugin/internal/source/processPluginBuildEnvironment.js +40 -0
- package/lib/plugin/internal/source/processPluginBuildEnvironment.js.map +1 -0
- package/lib/plugin/internal/source/pruneCacheFileRoot.d.ts +34 -0
- package/lib/plugin/internal/source/pruneCacheFileRoot.js +120 -0
- package/lib/plugin/internal/source/pruneCacheFileRoot.js.map +1 -0
- package/lib/plugin/internal/source/pruneGoBuildCacheRoot.d.ts +28 -0
- package/lib/plugin/internal/source/pruneGoBuildCacheRoot.js +185 -0
- package/lib/plugin/internal/source/pruneGoBuildCacheRoot.js.map +1 -0
- package/lib/plugin/internal/source/prunePluginCacheRoot.d.ts +46 -0
- package/lib/plugin/internal/source/prunePluginCacheRoot.js +446 -0
- package/lib/plugin/internal/source/prunePluginCacheRoot.js.map +1 -0
- package/lib/plugin/internal/source/prunesPluginSourceDirectory.d.ts +21 -0
- package/lib/plugin/internal/source/prunesPluginSourceDirectory.js +28 -0
- package/lib/plugin/internal/source/prunesPluginSourceDirectory.js.map +1 -0
- package/lib/plugin/internal/source/reclaimPluginBuildLock.d.ts +23 -0
- package/lib/plugin/internal/source/reclaimPluginBuildLock.js +48 -0
- package/lib/plugin/internal/source/reclaimPluginBuildLock.js.map +1 -0
- package/lib/plugin/internal/source/recordCacheFileUse.d.ts +22 -0
- package/lib/plugin/internal/source/recordCacheFileUse.js +43 -0
- package/lib/plugin/internal/source/recordCacheFileUse.js.map +1 -0
- package/lib/plugin/internal/source/releasePluginBuildLock.d.ts +33 -0
- package/lib/plugin/internal/source/releasePluginBuildLock.js +100 -0
- package/lib/plugin/internal/source/releasePluginBuildLock.js.map +1 -0
- package/lib/plugin/internal/source/resolveCleanTargets.d.ts +26 -0
- package/lib/plugin/internal/source/resolveCleanTargets.js +73 -0
- package/lib/plugin/internal/source/resolveCleanTargets.js.map +1 -0
- package/lib/plugin/internal/source/resolveGoCompiler.d.ts +29 -0
- package/lib/plugin/internal/source/resolveGoCompiler.js +62 -0
- package/lib/plugin/internal/source/resolveGoCompiler.js.map +1 -0
- package/lib/plugin/internal/source/resolvePluginCacheRoot.d.ts +21 -0
- package/lib/plugin/internal/source/resolvePluginCacheRoot.js +31 -0
- package/lib/plugin/internal/source/resolvePluginCacheRoot.js.map +1 -0
- package/lib/plugin/internal/source/resolvePluginGoModule.d.ts +34 -0
- package/lib/plugin/internal/source/resolvePluginGoModule.js +65 -0
- package/lib/plugin/internal/source/resolvePluginGoModule.js.map +1 -0
- package/lib/plugin/internal/source/resolveSourceBuildCachePaths.d.ts +21 -0
- package/lib/plugin/internal/source/resolveSourceBuildCachePaths.js +236 -0
- package/lib/plugin/internal/source/resolveSourceBuildCachePaths.js.map +1 -0
- package/lib/plugin/internal/source/selectPluginModuleReplaceDirectories.d.ts +29 -0
- package/lib/plugin/internal/source/selectPluginModuleReplaceDirectories.js +68 -0
- package/lib/plugin/internal/source/selectPluginModuleReplaceDirectories.js.map +1 -0
- package/lib/plugin/internal/source/spawnGoTool.d.ts +22 -0
- package/lib/plugin/internal/source/spawnGoTool.js +164 -0
- package/lib/plugin/internal/source/spawnGoTool.js.map +1 -0
- package/lib/plugin/internal/source/touchPluginCacheEntryInUse.d.ts +27 -0
- package/lib/plugin/internal/source/touchPluginCacheEntryInUse.js +48 -0
- package/lib/plugin/internal/source/touchPluginCacheEntryInUse.js.map +1 -0
- package/lib/plugin/internal/source/waitForPluginBinary.d.ts +36 -0
- package/lib/plugin/internal/source/waitForPluginBinary.js +94 -0
- package/lib/plugin/internal/source/waitForPluginBinary.js.map +1 -0
- package/lib/plugin/internal/source/windowsGoCommandArgs.d.ts +17 -0
- package/lib/plugin/internal/source/windowsGoCommandArgs.js +23 -0
- package/lib/plugin/internal/source/windowsGoCommandArgs.js.map +1 -0
- package/lib/plugin/internal/source/withGoBuildCacheLease.d.ts +37 -0
- package/lib/plugin/internal/source/withGoBuildCacheLease.js +87 -0
- package/lib/plugin/internal/source/withGoBuildCacheLease.js.map +1 -0
- package/lib/plugin/internal/writeCapabilityResolution.d.ts +80 -0
- package/lib/plugin/internal/writeCapabilityResolution.js +196 -0
- package/lib/plugin/internal/writeCapabilityResolution.js.map +1 -0
- package/lib/plugin/resolveCapabilityPlugins.d.ts +53 -32
- package/lib/plugin/resolveCapabilityPlugins.js +209 -38
- package/lib/plugin/resolveCapabilityPlugins.js.map +1 -1
- package/lib/register.js +20 -5
- package/lib/register.js.map +1 -1
- package/lib/structures/ITtscCompilerContext.d.ts +29 -11
- package/lib/structures/ITtscCompilerDiagnostic.d.ts +24 -7
- package/lib/structures/ITtscCompilerResult.d.ts +75 -25
- package/lib/structures/ITtscCompilerTransformation.d.ts +287 -64
- package/lib/structures/ITtscPlugin.d.ts +24 -8
- package/lib/structures/ITtscPluginCapabilities.d.ts +55 -5
- package/lib/structures/ITtscPluginContributor.d.ts +19 -8
- package/lib/structures/ITtscPluginFactoryContext.d.ts +12 -3
- package/lib/structures/ITtscProjectPluginConfig.d.ts +35 -10
- package/lib/structures/TtscPluginStage.d.ts +9 -0
- package/lib/structures/internal/ITtscLoadedNativePlugin.d.ts +19 -5
- package/lib/structures/internal/ITtscParsedProjectConfig.d.ts +29 -3
- package/lib/structures/internal/ITtscProjectIdentity.d.ts +21 -6
- package/lib/structures/internal/ITtscProjectInputSnapshot.d.ts +23 -8
- package/lib/structures/internal/ITtscProjectLocatorOptions.d.ts +18 -4
- package/lib/structures/internal/TtscBuildOptions.d.ts +33 -14
- package/lib/structures/internal/TtscBuildResult.d.ts +63 -4
- package/lib/structures/internal/TtscCommonOptions.d.ts +47 -14
- package/lib/structures/internal/TtscSingleFileEmitOptions.d.ts +46 -5
- package/package.json +26 -12
- package/shim/ast/enums_gen.go +4 -2
- package/shim/ast/go.mod +5 -5
- package/shim/ast/go.sum +10 -10
- package/shim/ast/lint.go +1088 -20
- package/shim/ast/parent.go +38 -22
- package/shim/ast/safe_text.go +48 -26
- package/shim/ast/shim.go +1307 -20
- package/shim/ast/test/next_jsdoc_comment_location_reaches_variable_statement_test.go +51 -0
- package/shim/ast/test/node_text_joins_multi_hop_qualified_name_test.go +24 -9
- package/shim/ast/test/node_text_joins_one_hop_qualified_name_test.go +9 -5
- package/shim/ast/test/node_text_returns_empty_for_nil_test.go +13 -5
- package/shim/ast/test/node_text_returns_identifier_text_test.go +12 -5
- package/shim/ast/test/node_text_skips_empty_qualified_left_test.go +35 -5
- package/shim/astnav/go.mod +5 -5
- package/shim/astnav/go.sum +12 -10
- package/shim/astnav/shim.go +9 -0
- package/shim/bundled/go.mod +7 -1
- package/shim/bundled/go.sum +12 -0
- package/shim/checker/enums_gen.go +4 -2
- package/shim/checker/extra-shim.json +6 -0
- package/shim/checker/go.mod +5 -5
- package/shim/checker/go.sum +10 -10
- package/shim/checker/node_builder_fields_gen.go +19 -0
- package/shim/checker/shim.go +827 -114
- package/shim/compiler/emit_sourcemap.go +68 -29
- package/shim/compiler/emitassemble.go +36 -2
- package/shim/compiler/emithook.go +13 -3
- package/shim/compiler/go.mod +5 -5
- package/shim/compiler/go.sum +10 -10
- package/shim/compiler/incremental.go +56 -20
- package/shim/compiler/resolution.go +92 -9
- package/shim/core/enums_gen.go +2 -2
- package/shim/core/go.mod +6 -1
- package/shim/core/go.sum +10 -0
- package/shim/core/modulekind.go +9 -0
- package/shim/core/shim.go +157 -6
- package/shim/diagnosticwriter/go.mod +10 -1
- package/shim/diagnosticwriter/go.sum +20 -0
- package/shim/diagnosticwriter/lint.go +188 -10
- package/shim/diagnosticwriter/shim.go +14 -0
- package/shim/lsp/go.mod +5 -5
- package/shim/lsp/go.sum +10 -10
- package/shim/lsp/shim.go +78 -2
- package/shim/parser/go.mod +10 -1
- package/shim/parser/go.sum +22 -0
- package/shim/printer/emithost.go +46 -1
- package/shim/printer/go.mod +5 -5
- package/shim/printer/go.sum +10 -10
- package/shim/printer/shim.go +114 -7
- package/shim/printer/sourcemap.go +55 -0
- package/shim/scanner/go.mod +10 -1
- package/shim/scanner/go.sum +20 -0
- package/shim/scanner/regexp.go +19 -4
- package/shim/scanner/shim.go +3 -0
- package/shim/stringutil/extra-shim.json +1 -0
- package/shim/stringutil/go.mod +5 -0
- package/shim/stringutil/go.sum +2 -0
- package/shim/stringutil/shim.go +119 -0
- package/shim/transformers/go.mod +5 -5
- package/shim/transformers/go.sum +12 -10
- package/shim/transformers/shim.go +12 -3
- package/shim/tsoptions/command_line_raw.go +44 -0
- package/shim/tsoptions/go.mod +10 -1
- package/shim/tsoptions/go.sum +22 -0
- package/shim/tsoptions/shim.go +1 -1
- package/shim/tspath/go.mod +1 -1
- package/shim/tspath/go.sum +6 -0
- package/shim/vfs/cachedvfs/go.mod +3 -1
- package/shim/vfs/cachedvfs/go.sum +12 -0
- package/shim/vfs/decode.go +26 -0
- package/shim/vfs/decode_test.go +42 -0
- package/shim/vfs/go.mod +7 -1
- package/shim/vfs/go.sum +12 -0
- package/shim/vfs/osvfs/go.mod +7 -1
- package/shim/vfs/osvfs/go.sum +12 -0
- package/src/TtscCompiler.ts +223 -234
- package/src/TtscService.ts +87 -31
- package/src/TtscServiceRequestOptions.ts +21 -0
- package/src/compiler/internal/CapturedProcessOutput.ts +69 -0
- package/src/compiler/internal/CompilerArgumentsInspection.ts +184 -0
- package/src/compiler/internal/EmitOwnershipIndex.ts +254 -0
- package/src/compiler/internal/PrivateCompilerOutput.ts +330 -0
- package/src/compiler/internal/ResidentCheckProcess.ts +445 -0
- package/src/compiler/internal/ResidentCheckProcessOptions.ts +32 -0
- package/src/compiler/internal/ResidentCheckRequest.ts +39 -0
- package/src/compiler/internal/ResidentCheckResult.ts +24 -0
- package/src/compiler/internal/ResidentCheckTelemetry.ts +36 -0
- package/src/compiler/internal/ResidentReplyKind.ts +18 -0
- package/src/compiler/internal/ResidentTransformProcess.ts +299 -0
- package/src/compiler/internal/ResidentTransformProcessOptions.ts +30 -0
- package/src/compiler/internal/ResidentTransformReply.ts +79 -0
- package/src/compiler/internal/ResidentTransformRequestOptions.ts +16 -0
- package/src/compiler/internal/ResidentTransformRequests.ts +198 -0
- package/src/compiler/internal/StartedResidentTransform.ts +29 -0
- package/src/compiler/internal/TransformProjectWorkerReply.ts +37 -0
- package/src/compiler/internal/TransformProjectWorkerRequest.ts +42 -0
- package/src/compiler/internal/build/BuildExecution.ts +1261 -0
- package/src/compiler/internal/build/BuildTiming.ts +145 -0
- package/src/compiler/internal/build/CompilerDiagnostics.ts +307 -0
- package/src/compiler/internal/build/NativePluginArguments.ts +302 -0
- package/src/compiler/internal/build/PassthroughFlags.ts +229 -0
- package/src/compiler/internal/build/PluginFailureDiagnostics.ts +70 -0
- package/src/compiler/internal/build/ResidentCheckEntryPlan.ts +42 -0
- package/src/compiler/internal/build/ResidentCheckWatchChange.ts +33 -0
- package/src/compiler/internal/build/ResidentCheckWatchSession.ts +501 -0
- package/src/compiler/internal/build/RunBuildOptions.ts +145 -0
- package/src/compiler/internal/build/TsgoArguments.ts +349 -0
- package/src/compiler/internal/build/appendBuildOutput.ts +218 -0
- package/src/compiler/internal/build/bufferResidentCheckEntryRequests.ts +52 -0
- package/src/compiler/internal/build/createProcessDiagnostic.ts +32 -0
- package/src/compiler/internal/build/isAbsoluteLocalProjectInputPath.ts +55 -0
- package/src/compiler/internal/build/mergeProjectInputSnapshots.ts +147 -0
- package/src/compiler/internal/build/normalizeBuildOutput.ts +89 -0
- package/src/compiler/internal/build/parseProjectInputSnapshot.ts +91 -0
- package/src/compiler/internal/build/planResidentCheckEntries.ts +55 -0
- package/src/compiler/internal/build/privateRuntimeRootDir.ts +33 -0
- package/src/compiler/internal/build/residentCheckRequest.ts +41 -0
- package/src/compiler/internal/build/runBuild.ts +61 -0
- package/src/compiler/internal/build/runExternalEmitProvenance.ts +566 -0
- package/src/compiler/internal/build/takeResidentCheckEntryRequest.ts +31 -0
- package/src/compiler/internal/buildNativeCompiler.ts +19 -2
- package/src/compiler/internal/captureProcessOutput.ts +39 -37
- package/src/compiler/internal/compileProjectInMemory.ts +139 -92
- package/src/compiler/internal/ensureExecutable.ts +32 -0
- package/src/compiler/internal/findNearestGoMod.ts +43 -0
- package/src/compiler/internal/isOutsideRelativePath.ts +26 -0
- package/src/compiler/internal/outputText.ts +21 -0
- package/src/compiler/internal/packageRootDir.ts +43 -0
- package/src/compiler/internal/parseNativeTransformOutput.ts +722 -0
- package/src/compiler/internal/project/CompilerProjectSelection.ts +204 -0
- package/src/compiler/internal/project/ConfigJsonText.ts +55 -0
- package/src/compiler/internal/project/compilerUsesCaseSensitiveFileNames.ts +124 -0
- package/src/compiler/internal/project/createNativeProjectContextArgs.ts +14 -19
- package/src/compiler/internal/project/createNativeProjectContextJson.ts +28 -0
- package/src/compiler/internal/project/parseJsonc.ts +318 -0
- package/src/compiler/internal/project/readJsonFile.ts +34 -0
- package/src/compiler/internal/project/readJsoncFile.ts +46 -0
- package/src/compiler/internal/project/readProjectConfig.ts +137 -200
- package/src/compiler/internal/project/resolveOwningProjectConfig.ts +278 -0
- package/src/compiler/internal/project/resolveProjectConfig.ts +18 -127
- package/src/compiler/internal/project/resolveProjectIdentity.ts +153 -0
- package/src/compiler/internal/project/resolveTsconfigExtends.ts +175 -0
- package/src/compiler/internal/project/selectReferencedProject.ts +54 -0
- package/src/compiler/internal/project/tsconfigExtendsFileCandidates.ts +54 -0
- package/src/compiler/internal/readEffectiveCompilerOptions.ts +126 -0
- package/src/compiler/internal/resolveBinary.ts +25 -9
- package/src/compiler/internal/resolveTsgo.ts +31 -11
- package/src/compiler/internal/runNativeCheckWithObservations.ts +211 -0
- package/src/compiler/internal/runSingleFileEmit.ts +92 -27
- package/src/compiler/internal/sharedHost/SEMANTIC_CONFIG_PATH_ENV.ts +2 -0
- package/src/compiler/internal/sharedHost/SidecarEnvironment.ts +151 -0
- package/src/compiler/internal/sharedHost/TSGO_ARGS_CWD_ENV.ts +7 -0
- package/src/compiler/internal/sharedHost/TSGO_ARGS_ENV.ts +7 -0
- package/src/compiler/internal/sharedHost/assertSharedHostCompatibility.ts +48 -0
- package/src/compiler/internal/sharedHost/clearInheritedSemanticConfigPath.ts +27 -0
- package/src/compiler/internal/sharedHost/clearInheritedTsgoArgs.ts +41 -0
- package/src/compiler/internal/sharedHost/inheritedSidecarEnv.ts +45 -0
- package/src/compiler/internal/sharedHost/isLinkedTransform.ts +19 -0
- package/src/compiler/internal/sharedHost/linkedTransformPlugins.ts +25 -0
- package/src/compiler/internal/sharedHost/publishLinkedTransformPlugins.ts +42 -0
- package/src/compiler/internal/sharedHost/resolvePluginConfigDir.ts +33 -0
- package/src/compiler/internal/sharedHost/selectSharedHostPlugin.ts +35 -0
- package/src/compiler/internal/spawnNative.ts +20 -41
- package/src/compiler/internal/startResidentTransform.ts +66 -53
- package/src/compiler/internal/transformProjectInMemory.ts +356 -634
- package/src/compiler/internal/transformProjectInWorker.ts +170 -0
- package/src/compiler/internal/transformProjectWorker.ts +43 -0
- package/src/flags/AnySubcommand.ts +19 -0
- package/src/flags/COMPILER_ENUM_WHITESPACE.ts +35 -0
- package/src/flags/COMPILER_OPTIONS.ts +512 -0
- package/src/flags/COMPILER_OPTION_ASCII_FOLDS.ts +13 -0
- package/src/flags/COMPILER_OPTION_KINDS.ts +14 -0
- package/src/flags/CompilerOptionSpec.ts +30 -0
- package/src/flags/FLAG_BY_TOKEN.ts +40 -0
- package/src/flags/{schema.ts → FLAG_SCHEMA.ts} +43 -318
- package/src/flags/FlagKind.ts +22 -0
- package/src/flags/FlagLayer.ts +24 -0
- package/src/flags/FlagSpec.ts +118 -0
- package/src/flags/ParseOptions.ts +103 -0
- package/src/flags/ParseResult.ts +44 -0
- package/src/flags/TtscSubcommand.ts +22 -0
- package/src/flags/TtsxSubcommand.ts +13 -0
- package/src/flags/ValueValidator.ts +14 -0
- package/src/flags/buildGoAllowList.ts +43 -0
- package/src/flags/flagsForSubcommand.ts +22 -0
- package/src/flags/getBoolean.ts +27 -0
- package/src/flags/getNumber.ts +24 -0
- package/src/flags/getString.ts +24 -0
- package/src/flags/getStringList.ts +24 -0
- package/src/flags/normalizeCompilerEnumValue.ts +41 -0
- package/src/flags/normalizeFlagToken.ts +38 -0
- package/src/flags/parseFlags.ts +371 -0
- package/src/flags/readCompilerOptionOccurrence.ts +107 -0
- package/src/flags/readCompilerOptionValues.ts +68 -0
- package/src/flags/resolveFlagSpec.ts +29 -0
- package/src/index.ts +9 -3
- package/src/internal/CanonicalTempDirectoryOperations.ts +73 -0
- package/src/internal/CompilerContextSnapshot.ts +139 -0
- package/src/internal/CompilerResultAdapter.ts +320 -0
- package/src/internal/E2ETrace.ts +674 -0
- package/src/internal/IJavaScriptRuntimeCapabilities.ts +50 -0
- package/src/internal/OwnedNativeProcess.ts +417 -0
- package/src/internal/OwnedSynchronousProcess.ts +220 -0
- package/src/internal/RetireLockDirectoryOperations.ts +81 -0
- package/src/internal/SafeCacheCleanupTarget.ts +41 -0
- package/src/internal/SourceNativeRetirement.ts +1109 -0
- package/src/internal/SpawnSyncOutputFiles.ts +29 -0
- package/src/internal/cacheEntryExists.ts +24 -0
- package/src/internal/createCanonicalTempDirectory.ts +35 -18
- package/src/internal/isContendedCandidateRename.ts +35 -0
- package/src/internal/isSpawnSyncFdExhaustion.ts +19 -0
- package/src/internal/javascriptRuntimeCapabilities.ts +166 -0
- package/src/internal/nativeBinary.ts +11 -0
- package/src/internal/parseWindowsDirectoryCaseSensitivity.ts +50 -0
- package/src/internal/pathIdentity/FilesystemPathIdentity.ts +44 -0
- package/src/internal/pathIdentity/FilesystemPathIdentityContext.ts +182 -0
- package/src/internal/pathIdentity/FilesystemPathIdentityOperations.ts +106 -0
- package/src/internal/pathIdentity/ProjectInputPathIdentity.ts +21 -0
- package/src/internal/pathIdentity/ProjectInputPathIdentityContext.ts +21 -0
- package/src/internal/pathIdentity/ProjectInputPathIdentityOperations.ts +22 -0
- package/src/internal/pathIdentity/createFilesystemPathIdentityContext.ts +437 -0
- package/src/internal/pathIdentity/createProjectInputPathIdentityContext.ts +34 -0
- package/src/internal/pathIdentity/isFilesystemPathIdentityWithin.ts +32 -0
- package/src/internal/pathIdentity/isProjectInputPathIdentityWithin.ts +22 -0
- package/src/internal/pathIdentity/resolveFilesystemPath.ts +43 -0
- package/src/internal/pathIdentity/resolvePhysicalPath.ts +31 -0
- package/src/internal/pathIdentity/resolveProjectInputPath.ts +18 -0
- package/src/internal/pluginSource.ts +26 -0
- package/src/internal/projectInputPathIdentity.ts +26 -387
- package/src/internal/resolveNodeBinary.ts +13 -142
- package/src/internal/resolveSafeCacheCleanupTargets.ts +51 -19
- package/src/internal/restoreCompilerError.ts +175 -0
- package/src/internal/retireLockDirectory.ts +166 -0
- package/src/internal/runHoldingLock.ts +55 -0
- package/src/internal/runtimeExecutableIdentity.ts +212 -0
- package/src/internal/serializeCompilerError.ts +145 -0
- package/src/internal/spawnSyncResilient.ts +62 -0
- package/src/internal/spawnSyncWithLowDescriptors.ts +227 -0
- package/src/internal/tsconfig.ts +16 -0
- package/src/launcher/internal/PendingResidentCheckWatchChanges.ts +94 -0
- package/src/launcher/internal/TtscBuildMode.ts +14 -0
- package/src/launcher/internal/TtsxEntryOptions.ts +92 -0
- package/src/launcher/internal/assertNoSolutionBuild.ts +17 -10
- package/src/launcher/internal/assertTtsxNoWatch.ts +49 -0
- package/src/launcher/internal/buildSingleRootProject.ts +303 -0
- package/src/launcher/internal/getCompilerVersionText.ts +20 -5
- package/src/launcher/internal/inlineServedSourceMap.ts +294 -0
- package/src/launcher/internal/linkVirtualEntry.ts +88 -0
- package/src/launcher/internal/{commonJsExportMetadata.ts → parseCommonJsExports.ts} +12 -2
- package/src/launcher/internal/parseTtscBuildArgs.ts +103 -0
- package/src/launcher/internal/parseTtsxCLI.ts +183 -0
- package/src/launcher/internal/prepareExecution.ts +474 -362
- package/src/launcher/internal/prepareTtscBuildMode.ts +64 -0
- package/src/launcher/internal/resolveCacheDir.ts +12 -3
- package/src/launcher/internal/resolveSingleFileOutput.ts +145 -0
- package/src/launcher/internal/resolveTtscserverBinary.ts +20 -5
- package/src/launcher/internal/runTtsc.ts +394 -326
- package/src/launcher/internal/runTtsx.ts +349 -151
- package/src/launcher/internal/runtime/CommonJsRuntimeSource.ts +365 -0
- package/src/launcher/internal/runtime/DependencyBuildAdmission.ts +159 -0
- package/src/launcher/internal/runtime/DependencyBuildGeneration.ts +236 -0
- package/src/launcher/internal/runtime/DependencyBuildLockFence.ts +22 -0
- package/src/launcher/internal/runtime/DependencyBuildLockLease.ts +22 -0
- package/src/launcher/internal/runtime/DependencyBuildLockObservation.ts +49 -0
- package/src/launcher/internal/runtime/DependencyBuildLockProtocol.ts +137 -0
- package/src/launcher/internal/runtime/OwnedProjectSource.ts +140 -0
- package/src/launcher/internal/runtime/OwningModuleOptions.ts +22 -0
- package/src/launcher/internal/runtime/PluginDescriptorInputObservation.ts +112 -0
- package/src/launcher/internal/runtime/ProcessOwnedDirectory.ts +325 -0
- package/src/launcher/internal/runtime/ResolveResult.ts +26 -0
- package/src/launcher/internal/runtime/RuntimeEmitProvenance.ts +58 -0
- package/src/launcher/internal/runtime/RuntimeEntryPreparer.ts +23 -0
- package/src/launcher/internal/runtime/RuntimeFilesystem.ts +64 -0
- package/src/launcher/internal/runtime/RuntimeHookOptions.ts +23 -0
- package/src/launcher/internal/runtime/RuntimeIsolatedEmit.ts +88 -0
- package/src/launcher/internal/runtime/RuntimeLoaderCapabilities.ts +256 -0
- package/src/launcher/internal/runtime/RuntimeManifest.ts +77 -0
- package/src/launcher/internal/runtime/RuntimeManifestRegistry.ts +309 -0
- package/src/launcher/internal/runtime/RuntimeModuleFormat.ts +275 -0
- package/src/launcher/internal/runtime/RuntimeProjectOwnership.ts +139 -0
- package/src/launcher/internal/runtime/TTSX_MINIMUM_NODE_VERSION.ts +11 -0
- package/src/launcher/internal/runtime/acquireDependencyBuildLock.ts +97 -0
- package/src/launcher/internal/runtime/checkNodeRuntimeSupport.ts +94 -0
- package/src/launcher/internal/runtime/claimRuntimeProjectDirectory.ts +54 -0
- package/src/launcher/internal/runtime/commonJsExportNames.ts +57 -0
- package/src/launcher/internal/runtime/commonJsImportFacade.ts +62 -0
- package/src/launcher/internal/runtime/dependencyCacheKey.ts +82 -0
- package/src/launcher/internal/runtime/dependencyCacheRoot.ts +112 -0
- package/src/launcher/internal/runtime/inspectDependencyBuildLock.ts +162 -0
- package/src/launcher/internal/runtime/installRuntimeHooks.ts +2442 -0
- package/src/launcher/internal/runtime/interopProbe.ts +8 -0
- package/src/launcher/internal/runtime/isLocalProcessGone.ts +67 -0
- package/src/launcher/internal/runtime/observeMappedDescriptorResolution.ts +74 -0
- package/src/launcher/internal/runtime/projectModuleOptions.ts +28 -0
- package/src/launcher/internal/runtime/readDependencyCache.ts +89 -0
- package/src/launcher/internal/runtime/realPath.ts +30 -0
- package/src/launcher/internal/runtime/reclaimDependencyBuildLock.ts +27 -0
- package/src/launcher/internal/runtime/releaseDependencyBuildLock.ts +27 -0
- package/src/launcher/internal/runtime/resolveRuntimeCleanTargets.ts +93 -0
- package/src/launcher/internal/runtime/restoreStrippedNodeBuiltinScheme.ts +32 -0
- package/src/launcher/internal/runtime/runtimeRunKey.ts +31 -0
- package/src/launcher/internal/runtime/selectRuntimePluginPolicy.ts +28 -0
- package/src/launcher/internal/runtime/withRuntimeDirectoryLock.ts +92 -0
- package/src/launcher/internal/runtimeCompilerArgs.ts +91 -62
- package/src/launcher/internal/runtimeEmitProfile.ts +70 -0
- package/src/launcher/internal/runtimeHookPreload.ts +3 -3
- package/src/launcher/internal/runtimeOwnerPreload.ts +43 -0
- package/src/launcher/internal/singleRootProjectConfig.ts +38 -0
- package/src/launcher/internal/ttscserver/ILSPPluginSelectionInputs.ts +65 -0
- package/src/launcher/internal/ttscserver/LSPProjectInputDigest.ts +331 -0
- package/src/launcher/internal/ttscserver/captureLSPPluginSelectionInputs.ts +107 -0
- package/src/launcher/internal/ttscserver/fingerprintInitialLSPProjectInputSnapshot.ts +41 -0
- package/src/launcher/internal/ttscserver/initialLSPProjectInputSnapshotIsCurrent.ts +36 -0
- package/src/launcher/internal/ttscserver/materializeLSPPluginManifest.ts +60 -0
- package/src/launcher/internal/ttscserver/needsStdio.ts +32 -0
- package/src/launcher/internal/ttscserver/runTtscserver.ts +592 -0
- package/src/launcher/internal/watch/CompilerDirectoryWatchEventPlan.ts +31 -0
- package/src/launcher/internal/watch/DirectoryWatcher.ts +45 -0
- package/src/launcher/internal/watch/FseventsStreams.ts +303 -0
- package/src/launcher/internal/watch/ProjectInputWatchRules.ts +179 -0
- package/src/launcher/internal/watch/WatchInputChange.ts +31 -0
- package/src/launcher/internal/watch/WatchPaths.ts +156 -0
- package/src/launcher/internal/{watchTopology.ts → watch/WatchTopology.ts} +867 -962
- package/src/launcher/internal/watch/literalGlobRoot.ts +40 -0
- package/src/launcher/internal/watch/planCompilerDirectoryWatchEvent.ts +83 -0
- package/src/launcher/internal/watch/projectInputActiveWatchDirectories.ts +47 -0
- package/src/launcher/internal/watch/projectInputAvailableWatchDirectory.ts +56 -0
- package/src/launcher/internal/watch/projectInputEventShouldNotify.ts +23 -0
- package/src/launcher/internal/watch/projectInputMembershipInvalidatesProgram.ts +63 -0
- package/src/launcher/internal/watch/projectInputReloadEventShouldNotify.ts +127 -0
- package/src/launcher/internal/watch/projectInputReplacementStrandsWatchers.ts +57 -0
- package/src/launcher/internal/watch/projectInputTopologyMayAffect.ts +73 -0
- package/src/launcher/internal/watch/projectInputWatchDirectories.ts +33 -0
- package/src/launcher/internal/watch/reloadInputsForFailedTopologyRefresh.ts +49 -0
- package/src/launcher/internal/watch/syncWatchers.ts +64 -0
- package/src/launcher/internal/watch/watchDirectory.ts +53 -0
- package/src/launcher/internal/watch/watchDirectoryThroughFsWatch.ts +47 -0
- package/src/launcher/ttscserver.ts +1 -1
- package/src/launcher/ttsx.ts +2 -3
- package/src/plugin/CapabilityPluginResolver.ts +549 -0
- package/src/plugin/ITtscCapabilityPlugin.ts +93 -0
- package/src/plugin/internal/CapabilityPluginResult.ts +99 -0
- package/src/plugin/internal/CapabilityResolutionFormat.ts +248 -0
- package/src/plugin/internal/ITtscCapabilityPluginSource.ts +37 -0
- package/src/plugin/internal/ITtscCapabilityResolutionEntry.ts +57 -0
- package/src/plugin/internal/ITtscCapabilityResolutionPlugin.ts +22 -0
- package/src/plugin/internal/capabilityPluginWorker.ts +216 -0
- package/src/plugin/internal/decodeCapabilityCommandReply.ts +27 -0
- package/src/plugin/internal/load/COMMONJS_PLUGIN_DESCRIPTOR_SHIM_SOURCE.ts +182 -0
- package/src/plugin/internal/load/PLUGIN_DESCRIPTOR_SHIM_SOURCE.ts +59 -0
- package/src/plugin/internal/load/PluginDescriptorAdmission.ts +75 -0
- package/src/plugin/internal/load/PluginDescriptorEvaluationCache.ts +432 -0
- package/src/plugin/internal/load/PluginPackageResolution.ts +711 -0
- package/src/plugin/internal/load/ProjectPluginEntries.ts +232 -0
- package/src/plugin/internal/load/RESOLUTION_INPUT_RECORDER_PATH.ts +34 -0
- package/src/plugin/internal/load/collectProjectHostInputs.ts +88 -0
- package/src/plugin/internal/load/composePluginSources.ts +121 -0
- package/src/plugin/internal/load/declaresHostInputReads.ts +52 -0
- package/src/plugin/internal/load/hasProjectPluginEntries.ts +33 -0
- package/src/plugin/internal/load/hashHostInputPaths.ts +44 -0
- package/src/plugin/internal/load/isRelativePluginSpecifier.ts +31 -0
- package/src/plugin/internal/load/loadProjectPlugins.ts +2242 -0
- package/src/plugin/internal/load/moduleResolutionBaseSelects.ts +59 -0
- package/src/plugin/internal/load/observeImportSearchRoots.ts +42 -0
- package/src/plugin/internal/load/pluginLabel.ts +28 -0
- package/src/plugin/internal/load/realpathHostInput.ts +22 -0
- package/src/plugin/internal/load/realpathHostInputPaths.ts +27 -0
- package/src/plugin/internal/load/rejectJsTransformFunctions.ts +23 -0
- package/src/plugin/internal/load/requirePluginSource.ts +34 -0
- package/src/plugin/internal/load/resolveNativeSource.ts +42 -0
- package/src/plugin/internal/load/validatePluginContributors.ts +102 -0
- package/src/plugin/internal/load/validatePluginSource.ts +19 -0
- package/src/plugin/internal/load/visitImportMappedCandidates.ts +63 -0
- package/src/plugin/internal/pluginDescriptorFailureReason.ts +35 -0
- package/src/plugin/internal/pluginDescriptorProcessFailure.ts +48 -0
- package/src/plugin/internal/readCapabilityResolution.ts +193 -0
- package/src/plugin/internal/receiveCapabilityFailure.ts +27 -0
- package/src/plugin/internal/source/CachePrunePolicy.ts +47 -0
- package/src/plugin/internal/source/GoBuildCacheCoordination.ts +588 -0
- package/src/plugin/internal/source/GoSourceInputs.ts +182 -0
- package/src/plugin/internal/source/GoToolResolution.ts +312 -0
- package/src/plugin/internal/source/IGoBuildCachePruneOptions.ts +34 -0
- package/src/plugin/internal/source/IPluginCachePruneOptions.ts +38 -0
- package/src/plugin/internal/source/IPluginModuleReplaceDirectory.ts +30 -0
- package/src/plugin/internal/source/ITtscBuildContributor.ts +19 -0
- package/src/plugin/internal/source/ITtscSourceBuildCachePaths.ts +28 -0
- package/src/plugin/internal/source/NativeSourcePackages.ts +368 -0
- package/src/plugin/internal/source/PluginBinaryUse.ts +159 -0
- package/src/plugin/internal/source/PluginBinaryWaitResult.ts +34 -0
- package/src/plugin/internal/source/PluginBuildEnvironmentReadings.ts +231 -0
- package/src/plugin/internal/source/PluginBuildEnvironmentWitness.ts +233 -0
- package/src/plugin/internal/source/PluginBuildLockFence.ts +26 -0
- package/src/plugin/internal/source/PluginBuildLockLease.ts +31 -0
- package/src/plugin/internal/source/PluginBuildLockObservation.ts +48 -0
- package/src/plugin/internal/source/PluginBuildLockOwner.ts +225 -0
- package/src/plugin/internal/source/PluginBuildLockProtocol.ts +342 -0
- package/src/plugin/internal/source/SourceBuildCacheLayout.ts +303 -0
- package/src/plugin/internal/source/SourceBuildFilesystemOperations.ts +32 -0
- package/src/plugin/internal/source/SourcePluginAdmission.ts +127 -0
- package/src/plugin/internal/source/SourcePluginWorkspace.ts +446 -0
- package/src/plugin/internal/source/acquirePluginBuildLock.ts +222 -0
- package/src/plugin/internal/source/autoQuoteGoModToken.ts +113 -0
- package/src/plugin/internal/source/buildSourcePlugin.ts +1197 -0
- package/src/plugin/internal/source/collectPluginSourceDirectories.ts +70 -0
- package/src/plugin/internal/source/collectPluginSourceFiles.ts +90 -0
- package/src/plugin/internal/source/computeCacheKey.ts +190 -0
- package/src/plugin/internal/source/copiesPluginSourceEntry.ts +52 -0
- package/src/plugin/internal/source/createExternalSourceSnapshotLayout.ts +66 -0
- package/src/plugin/internal/source/ensureExecutableGoToolchain.ts +87 -0
- package/src/plugin/internal/source/formatDuration.ts +32 -0
- package/src/plugin/internal/source/formatGoWorkPath.ts +42 -0
- package/src/plugin/internal/source/hashPluginBuildEnvironment.ts +803 -0
- package/src/plugin/internal/source/inspectPluginBuildLock.ts +330 -0
- package/src/plugin/internal/source/isPathWithin.ts +24 -0
- package/src/plugin/internal/source/legacyGlobalCacheTargets.ts +71 -0
- package/src/plugin/internal/source/pluginBuildEnvironment.ts +59 -0
- package/src/plugin/internal/source/pluginBuildEnvironmentWorker.ts +30 -0
- package/src/plugin/internal/source/pluginBuildVersions.ts +75 -0
- package/src/plugin/internal/source/pluginModuleReplaceDirectories.ts +96 -0
- package/src/plugin/internal/source/pluginSourceCovers.ts +54 -0
- package/src/plugin/internal/source/pluginSourceDigest.ts +55 -0
- package/src/plugin/internal/source/pluginSourceFilesSignature.ts +54 -0
- package/src/plugin/internal/source/pluginSourceState.ts +69 -0
- package/src/plugin/internal/source/pluginSourceStateHolds.ts +45 -0
- package/src/plugin/internal/source/processPluginBuildEnvironment.ts +40 -0
- package/src/plugin/internal/source/pruneCacheFileRoot.ts +134 -0
- package/src/plugin/internal/source/pruneGoBuildCacheRoot.ts +228 -0
- package/src/plugin/internal/source/prunePluginCacheRoot.ts +507 -0
- package/src/plugin/internal/source/prunesPluginSourceDirectory.ts +25 -0
- package/src/plugin/internal/source/reclaimPluginBuildLock.ts +63 -0
- package/src/plugin/internal/source/recordCacheFileUse.ts +35 -0
- package/src/plugin/internal/source/releasePluginBuildLock.ts +125 -0
- package/src/plugin/internal/source/resolveCleanTargets.ts +84 -0
- package/src/plugin/internal/source/resolveGoCompiler.ts +92 -0
- package/src/plugin/internal/source/resolvePluginCacheRoot.ts +32 -0
- package/src/plugin/internal/source/resolvePluginGoModule.ts +69 -0
- package/src/plugin/internal/source/resolveSourceBuildCachePaths.ts +276 -0
- package/src/plugin/internal/source/selectPluginModuleReplaceDirectories.ts +80 -0
- package/src/plugin/internal/source/spawnGoTool.ts +204 -0
- package/src/plugin/internal/source/touchPluginCacheEntryInUse.ts +44 -0
- package/src/plugin/internal/source/waitForPluginBinary.ts +123 -0
- package/src/plugin/internal/source/windowsGoCommandArgs.ts +19 -0
- package/src/plugin/internal/source/withGoBuildCacheLease.ts +101 -0
- package/src/plugin/internal/writeCapabilityResolution.ts +266 -0
- package/src/plugin/resolveCapabilityPlugins.ts +242 -77
- package/src/register.ts +20 -7
- package/src/structures/ITtscCompilerContext.ts +29 -11
- package/src/structures/ITtscCompilerDiagnostic.ts +24 -7
- package/src/structures/ITtscCompilerResult.ts +75 -25
- package/src/structures/ITtscCompilerTransformation.ts +304 -64
- package/src/structures/ITtscPlugin.ts +24 -8
- package/src/structures/ITtscPluginCapabilities.ts +58 -5
- package/src/structures/ITtscPluginContributor.ts +19 -8
- package/src/structures/ITtscPluginFactoryContext.ts +12 -3
- package/src/structures/ITtscProjectPluginConfig.ts +35 -10
- package/src/structures/TtscPluginStage.ts +9 -0
- package/src/structures/internal/ITtscLoadedNativePlugin.ts +27 -5
- package/src/structures/internal/ITtscParsedProjectConfig.ts +37 -3
- package/src/structures/internal/ITtscProjectIdentity.ts +27 -6
- package/src/structures/internal/ITtscProjectInputSnapshot.ts +31 -8
- package/src/structures/internal/ITtscProjectLocatorOptions.ts +21 -4
- package/src/structures/internal/TtscBuildOptions.ts +38 -14
- package/src/structures/internal/TtscBuildResult.ts +74 -4
- package/src/structures/internal/TtscCommonOptions.ts +59 -14
- package/src/structures/internal/TtscSingleFileEmitOptions.ts +55 -5
- package/tools/gen_shims/main.go +124 -11
- package/tools/gen_shims/package_load_admission_rejects_incomplete_results_test.go +61 -0
- package/tools/gen_shims/private_field_support_preserves_upstream_layout_test.go +104 -0
- package/tools/shim_audit/enum_generation_preserves_existing_family_members_test.go +182 -0
- package/tools/shim_audit/enum_generation_refuses_removed_public_members_test.go +93 -0
- package/tools/shim_audit/main.go +166 -31
- package/tools/shim_audit/main_test.go +35 -0
- package/tools/shim_audit/producer_exemptions_require_rationale_test.go +5 -0
- package/tools/shim_audit/producer_surface_includes_exposed_methods_test.go +5 -0
- package/tools/shim_audit/producer_surface_rejects_unproducible_reference_test.go +5 -0
- package/tools/shim_audit/shim_dir_coverage_rejects_unregistered_shims_test.go +71 -0
- package/utility/command.go +48 -0
- package/utility/flags_gen.go +2 -2
- package/utility/host.go +282 -66
- package/utility/preamble_output.go +245 -0
- package/utility/preamble_output_test.go +90 -0
- package/utility/serve.go +61 -18
- package/cmd/ttscgraph/serve_graph_snapshot_version_matches_typescript_client_test.go +0 -32
- package/cmd/ttscgraph/serve_protocol_version_matches_the_typescript_client_test.go +0 -48
- package/cmd/ttscgraph/serve_session_retries_failed_dump_test.go +0 -103
- package/internal/graph/dump_schema_version_matches_the_typescript_client_test.go +0 -48
- package/internal/graph/edge_kinds_names_every_declared_kind_test.go +0 -49
- package/internal/graph/graph_kind_contracts_match_their_producers_test.go +0 -121
- package/internal/lspserver/lsp_launcher_reload_directory_fingerprint_parity_windows_test.go +0 -94
- package/internal/lspserver/lsp_project_diagnostics_resident_unsupported_falls_back_test.go +0 -123
- package/lib/compiler/internal/paths.d.ts +0 -27
- package/lib/compiler/internal/paths.js +0 -70
- package/lib/compiler/internal/paths.js.map +0 -1
- package/lib/compiler/internal/project/readConfigJson.d.ts +0 -30
- package/lib/compiler/internal/project/readConfigJson.js +0 -208
- package/lib/compiler/internal/project/readConfigJson.js.map +0 -1
- package/lib/compiler/internal/residentCheckProcess.d.ts +0 -44
- package/lib/compiler/internal/residentCheckProcess.js +0 -213
- package/lib/compiler/internal/residentCheckProcess.js.map +0 -1
- package/lib/compiler/internal/residentTransformProcess.d.ts +0 -65
- package/lib/compiler/internal/residentTransformProcess.js +0 -330
- package/lib/compiler/internal/residentTransformProcess.js.map +0 -1
- package/lib/compiler/internal/resolveEmittedJavaScript.d.ts +0 -25
- package/lib/compiler/internal/resolveEmittedJavaScript.js +0 -165
- package/lib/compiler/internal/resolveEmittedJavaScript.js.map +0 -1
- package/lib/compiler/internal/runBuild.d.ts +0 -152
- package/lib/compiler/internal/runBuild.js +0 -1694
- package/lib/compiler/internal/runBuild.js.map +0 -1
- package/lib/compiler/internal/sharedHostHelpers.d.ts +0 -79
- package/lib/compiler/internal/sharedHostHelpers.js +0 -134
- package/lib/compiler/internal/sharedHostHelpers.js.map +0 -1
- package/lib/flags/parser.d.ts +0 -97
- package/lib/flags/parser.js +0 -293
- package/lib/flags/parser.js.map +0 -1
- package/lib/flags/schema.d.ts +0 -191
- package/lib/flags/schema.js.map +0 -1
- package/lib/internal/windowsDirectoryCaseSensitivity.d.ts +0 -10
- package/lib/internal/windowsDirectoryCaseSensitivity.js +0 -34
- package/lib/internal/windowsDirectoryCaseSensitivity.js.map +0 -1
- package/lib/launcher/internal/commonJsExportMetadata.d.ts +0 -7
- package/lib/launcher/internal/commonJsExportMetadata.js.map +0 -1
- package/lib/launcher/internal/registerRuntimeHooks.js +0 -59
- package/lib/launcher/internal/registerRuntimeHooks.js.map +0 -1
- package/lib/launcher/internal/runTtscserver.d.ts +0 -35
- package/lib/launcher/internal/runTtscserver.js +0 -660
- package/lib/launcher/internal/runTtscserver.js.map +0 -1
- package/lib/launcher/internal/runtimeHooks.d.ts +0 -198
- package/lib/launcher/internal/runtimeHooks.js +0 -2579
- package/lib/launcher/internal/runtimeHooks.js.map +0 -1
- package/lib/launcher/internal/servedSourceMap.d.ts +0 -25
- package/lib/launcher/internal/servedSourceMap.js +0 -164
- package/lib/launcher/internal/servedSourceMap.js.map +0 -1
- package/lib/launcher/internal/singleFileOutput.d.ts +0 -16
- package/lib/launcher/internal/singleFileOutput.js +0 -103
- package/lib/launcher/internal/singleFileOutput.js.map +0 -1
- package/lib/launcher/internal/watchTopology.d.ts +0 -329
- package/lib/launcher/internal/watchTopology.js.map +0 -1
- package/lib/plugin/internal/buildSourcePlugin.d.ts +0 -298
- package/lib/plugin/internal/buildSourcePlugin.js +0 -3086
- package/lib/plugin/internal/buildSourcePlugin.js.map +0 -1
- package/lib/plugin/internal/capabilityResolutionCache.d.ts +0 -76
- package/lib/plugin/internal/capabilityResolutionCache.js +0 -224
- package/lib/plugin/internal/capabilityResolutionCache.js.map +0 -1
- package/lib/plugin/internal/descriptorProcessFailure.d.ts +0 -36
- package/lib/plugin/internal/descriptorProcessFailure.js +0 -62
- package/lib/plugin/internal/descriptorProcessFailure.js.map +0 -1
- package/lib/plugin/internal/loadProjectPlugins.d.ts +0 -74
- package/lib/plugin/internal/loadProjectPlugins.js +0 -2379
- package/lib/plugin/internal/loadProjectPlugins.js.map +0 -1
- package/src/compiler/internal/paths.ts +0 -68
- package/src/compiler/internal/project/readConfigJson.ts +0 -209
- package/src/compiler/internal/residentCheckProcess.ts +0 -259
- package/src/compiler/internal/residentTransformProcess.ts +0 -406
- package/src/compiler/internal/resolveEmittedJavaScript.ts +0 -197
- package/src/compiler/internal/runBuild.ts +0 -2345
- package/src/compiler/internal/sharedHostHelpers.ts +0 -154
- package/src/flags/parser.ts +0 -459
- package/src/internal/windowsDirectoryCaseSensitivity.ts +0 -33
- package/src/launcher/internal/registerRuntimeHooks.ts +0 -68
- package/src/launcher/internal/runTtscserver.ts +0 -841
- package/src/launcher/internal/runtimeHooks.ts +0 -3197
- package/src/launcher/internal/servedSourceMap.ts +0 -183
- package/src/launcher/internal/singleFileOutput.ts +0 -133
- package/src/plugin/internal/buildSourcePlugin.ts +0 -3990
- package/src/plugin/internal/capabilityResolutionCache.ts +0 -305
- package/src/plugin/internal/descriptorProcessFailure.ts +0 -69
- package/src/plugin/internal/loadProjectPlugins.ts +0 -3044
- package/tools/shim_audit/shim_dir_coverage_test.go +0 -25
- /package/lib/{launcher/internal/registerRuntimeHooks.d.ts → compiler/internal/transformProjectWorker.d.ts} +0 -0
|
@@ -4,39 +4,74 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.WatchTopology = void 0;
|
|
7
|
-
exports.reloadInputsForFailedTopologyRefresh = reloadInputsForFailedTopologyRefresh;
|
|
8
|
-
exports.syncWatchers = syncWatchers;
|
|
9
|
-
exports.literalGlobRoot = literalGlobRoot;
|
|
10
|
-
exports.projectInputWatchDirectories = projectInputWatchDirectories;
|
|
11
|
-
exports.projectInputActiveWatchDirectories = projectInputActiveWatchDirectories;
|
|
12
|
-
exports.projectInputAvailableWatchDirectory = projectInputAvailableWatchDirectory;
|
|
13
|
-
exports.projectInputReplacementStrandsWatchers = projectInputReplacementStrandsWatchers;
|
|
14
|
-
exports.projectInputTopologyMayAffect = projectInputTopologyMayAffect;
|
|
15
|
-
exports.projectInputEventShouldNotify = projectInputEventShouldNotify;
|
|
16
|
-
exports.projectInputReloadEventShouldNotify = projectInputReloadEventShouldNotify;
|
|
17
|
-
exports.projectInputMembershipInvalidatesProgram = projectInputMembershipInvalidatesProgram;
|
|
18
|
-
exports.planCompilerDirectoryWatchEvent = planCompilerDirectoryWatchEvent;
|
|
19
7
|
const node_crypto_1 = __importDefault(require("node:crypto"));
|
|
20
8
|
const node_fs_1 = __importDefault(require("node:fs"));
|
|
21
9
|
const node_path_1 = __importDefault(require("node:path"));
|
|
22
|
-
const
|
|
23
|
-
const
|
|
24
|
-
const
|
|
25
|
-
const
|
|
26
|
-
const
|
|
27
|
-
const
|
|
28
|
-
const
|
|
10
|
+
const outputText_1 = require("../../../compiler/internal/outputText");
|
|
11
|
+
const CompilerProjectSelection_1 = require("../../../compiler/internal/project/CompilerProjectSelection");
|
|
12
|
+
const readJsoncFile_1 = require("../../../compiler/internal/project/readJsoncFile");
|
|
13
|
+
const readProjectConfig_1 = require("../../../compiler/internal/project/readProjectConfig");
|
|
14
|
+
const resolveTsgo_1 = require("../../../compiler/internal/resolveTsgo");
|
|
15
|
+
const spawnNative_1 = require("../../../compiler/internal/spawnNative");
|
|
16
|
+
const normalizeCompilerEnumValue_1 = require("../../../flags/normalizeCompilerEnumValue");
|
|
17
|
+
const readCompilerOptionValues_1 = require("../../../flags/readCompilerOptionValues");
|
|
18
|
+
const createProjectInputPathIdentityContext_1 = require("../../../internal/pathIdentity/createProjectInputPathIdentityContext");
|
|
19
|
+
const isProjectInputPathIdentityWithin_1 = require("../../../internal/pathIdentity/isProjectInputPathIdentityWithin");
|
|
20
|
+
const resolveProjectInputPath_1 = require("../../../internal/pathIdentity/resolveProjectInputPath");
|
|
21
|
+
const collectPluginSourceDirectories_1 = require("../../../plugin/internal/source/collectPluginSourceDirectories");
|
|
22
|
+
const pluginSourceCovers_1 = require("../../../plugin/internal/source/pluginSourceCovers");
|
|
23
|
+
const pluginSourceDigest_1 = require("../../../plugin/internal/source/pluginSourceDigest");
|
|
24
|
+
const prunesPluginSourceDirectory_1 = require("../../../plugin/internal/source/prunesPluginSourceDirectory");
|
|
25
|
+
const resolveSingleFileOutput_1 = require("../resolveSingleFileOutput");
|
|
26
|
+
const ProjectInputWatchRules_1 = require("./ProjectInputWatchRules");
|
|
27
|
+
const WatchPaths_1 = require("./WatchPaths");
|
|
28
|
+
const literalGlobRoot_1 = require("./literalGlobRoot");
|
|
29
|
+
const planCompilerDirectoryWatchEvent_1 = require("./planCompilerDirectoryWatchEvent");
|
|
30
|
+
const projectInputActiveWatchDirectories_1 = require("./projectInputActiveWatchDirectories");
|
|
31
|
+
const projectInputAvailableWatchDirectory_1 = require("./projectInputAvailableWatchDirectory");
|
|
32
|
+
const projectInputEventShouldNotify_1 = require("./projectInputEventShouldNotify");
|
|
33
|
+
const projectInputMembershipInvalidatesProgram_1 = require("./projectInputMembershipInvalidatesProgram");
|
|
34
|
+
const projectInputReloadEventShouldNotify_1 = require("./projectInputReloadEventShouldNotify");
|
|
35
|
+
const projectInputReplacementStrandsWatchers_1 = require("./projectInputReplacementStrandsWatchers");
|
|
36
|
+
const projectInputTopologyMayAffect_1 = require("./projectInputTopologyMayAffect");
|
|
37
|
+
const reloadInputsForFailedTopologyRefresh_1 = require("./reloadInputsForFailedTopologyRefresh");
|
|
38
|
+
const syncWatchers_1 = require("./syncWatchers");
|
|
39
|
+
const watchDirectory_1 = require("./watchDirectory");
|
|
29
40
|
/**
|
|
30
41
|
* Keeps the launcher watch set aligned with the compiler's current program.
|
|
31
42
|
*
|
|
32
|
-
* TypeScript-Go's `--listFilesOnly`
|
|
33
|
-
* declaration
|
|
34
|
-
*
|
|
35
|
-
*
|
|
43
|
+
* The default compiler-input reader uses TypeScript-Go's `--listFilesOnly`
|
|
44
|
+
* output for source and declaration membership. An explicit reader supplies the
|
|
45
|
+
* same absolute-path membership and failure contract for each resolved project.
|
|
46
|
+
* Configuration files, project-reference roots, output inference and native
|
|
47
|
+
* filesystem identity remain this topology's responsibility.
|
|
48
|
+
* Response frames are observed once per project refresh at its compiler cwd;
|
|
49
|
+
* that option view serves all project-output queries while the original argv
|
|
50
|
+
* reaches compiler membership. A second observation rejects response changes
|
|
51
|
+
* across membership resolution. Response files join the config reload set;
|
|
52
|
+
* these observations do not pin files or detect a change restored in between.
|
|
53
|
+
*
|
|
54
|
+
* `TTSC_WATCH_DEBUG_INPUTS` reports the named event, observed population deltas
|
|
55
|
+
* and reload decision. These diagnostics reuse the decision's existing inputs;
|
|
56
|
+
* they perform no extra filesystem observations.
|
|
57
|
+
*
|
|
58
|
+
* @evidence contracts/common.md#principled-implementation The compiler-input operation's membership, published rule inputs and actual content fingerprints qualify notifications; its native default obtains the real compiler list. Post-registration reconciliation compares baselines to recover observed handoff changes, not an atomic guarantee against every transient mutation. Explicit operations preserve native defaults without replacing global filesystem or compiler methods. Project-input attribution: Observed member deltas establish attribution; stale selected names cannot override them, while directory names retain supported population causality and unrelated multiple members remain unnamed.
|
|
59
|
+
* @evidence contracts/common.md#clear-and-simple-design Compiler, plugin and project-input watch populations keep their own baselines and callbacks under one topology owner; small classifiers separate membership, selection and handle replacement. Four distinct operations own directory subscriptions, file subscriptions, immediate reload-directory reads and compiler membership; existing callers need no new argument. Project-input attribution: One private reconciliation separates member deltas from immediate resolution-directory digests before choosing a supported event name or an observed single member.
|
|
60
|
+
* @evidence contracts/common.md#prohibited-implementation-shortcuts Supported native backends and explicit gap/replacement ownership replace foreign watcher patching; failed observation is reported rather than represented as complete coverage. The constructor manufactures no observations and bypasses no input or content proof; supplied operations retain the existing callback and result contracts. Project-input attribution: Native event names do not manufacture a delta; the current and previous physical membership identify already observed names without filename or fixture exceptions.
|
|
61
|
+
* @evidence contracts/common.md#meaningful-documentation Native paragraphs explain membership authority, plugin fingerprinting, publication races, physical registration and public lifecycle operations following the documentation skill. Parameters identify each supplied operation and native default beside the constructor. Project-input attribution: Native paragraphs explain stale attention, directory causality, accompanying resolution digests and unselected immediate entries.
|
|
62
|
+
* @evidence contracts/portability.md#os-neutral-implementation Native paths use Node APIs and registration uses realpath; compiler/plugin maps preserve lexical aliases and fold only measured insensitive ASCII components. Project inputs use physical identities, while unknown/native Unicode relations remain conservative event candidates rather than identity proof. Registration paths and read options are passed unchanged; compiler-input readers supply absolute membership paths without replacing the topology's native identity policy. Project-input attribution: The supplied filesystem identity transaction establishes selected names and ancestry without an OS-wide case assumption or lexical alias guess.
|
|
63
|
+
*
|
|
64
|
+
* @evidence contracts/performance.md#efficient-algorithms Identity-keyed maps separate membership, baselines and handle registries; reconciliation delegates project/config discovery, native compiler listing, filesystem traversal/hashing and backend callbacks, with costs described by its members. Construction retains operation references and empty indexes without a filesystem observation or build. Attribution indexed visits additionally pay path/key text, ancestor and native identity work; shared ancestor keys avoid repeating the same walk within a transaction.
|
|
65
|
+
* @evidence contracts/performance.md#reuse-equivalent-work Current membership, content baselines and live registrations belong to one topology; reconciliation owners decide their reuse against fresh premises. Supplied operation identities are retained without adding an observation-result cache or assuming changed inputs remain equivalent. Project-input attribution: This classifier borrows one scan's deltas and identity transaction without retaining cross-event answers.
|
|
66
|
+
* @evidence contracts/performance.md#bound-retention-and-release-resources Current and pending maps and live subscriptions remain topology-owned without a population cap; reconciliation attempts obsolete handle retirement. Constructor acquires no handle; directory arrays and attribution deltas are call-local. close invokes supplied close methods but does not await backend closure, and a thrown close can interrupt later map cleanup; retained snapshots remain until the facade is released.
|
|
36
67
|
*/
|
|
37
68
|
class WatchTopology {
|
|
38
69
|
options;
|
|
39
70
|
callbacks;
|
|
71
|
+
openDirectoryWatch;
|
|
72
|
+
openFileWatch;
|
|
73
|
+
readDirectory;
|
|
74
|
+
getCompilerInputs;
|
|
40
75
|
analysisOnly = false;
|
|
41
76
|
closed = false;
|
|
42
77
|
compilerPostRegistrationMembershipRefresh = false;
|
|
@@ -45,9 +80,26 @@ class WatchTopology {
|
|
|
45
80
|
directories = new Map();
|
|
46
81
|
directoryWatchers = new Map();
|
|
47
82
|
extraInputs = [];
|
|
83
|
+
/**
|
|
84
|
+
* What each plugin input held when last observed, by path key: the digest a
|
|
85
|
+
* plugin build keys it on (`pluginInputState`). A notification about an input
|
|
86
|
+
* whose state did not move is not a plugin change.
|
|
87
|
+
*/
|
|
88
|
+
pluginInputStates = new Map();
|
|
89
|
+
/**
|
|
90
|
+
* The plugin inputs notifications named since the last decision, by path key,
|
|
91
|
+
* each with the locations noted for it (`notePluginNotification`).
|
|
92
|
+
*/
|
|
93
|
+
pendingPluginNotifications = new Map();
|
|
94
|
+
pluginNotificationsScheduled = false;
|
|
48
95
|
extraWatchers = new Map();
|
|
96
|
+
/** The plugin inputs whose directories the last sync already watched. */
|
|
97
|
+
watchedExtraInputs = new Set();
|
|
49
98
|
compilerFileSnapshots = new Map();
|
|
50
99
|
files = new Map();
|
|
100
|
+
lexicalIdentities = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)({
|
|
101
|
+
throwOnRealpathError: false,
|
|
102
|
+
});
|
|
51
103
|
fileWatchers = new Map();
|
|
52
104
|
observedDirectories = new Map();
|
|
53
105
|
outputFiles = new Map();
|
|
@@ -77,22 +129,55 @@ class WatchTopology {
|
|
|
77
129
|
projectInputWatchers = new Map();
|
|
78
130
|
projectInputLinkWatchers = new Map();
|
|
79
131
|
projectInputCompilerOutputOverlaps = new WeakMap();
|
|
80
|
-
projectInputCompilerAcknowledgements = new Map();
|
|
81
132
|
reloadFiles = new Map();
|
|
82
|
-
|
|
133
|
+
/**
|
|
134
|
+
* @param options What to watch.
|
|
135
|
+
* @param callbacks What to tell about it.
|
|
136
|
+
* @param openDirectoryWatch The backend every directory watch goes through:
|
|
137
|
+
* `watchDirectory`, which chooses the platform's, unless the caller
|
|
138
|
+
* observes the watch set through another.
|
|
139
|
+
* @param openFileWatch File subscriptions use this owned observer; native
|
|
140
|
+
* fs.watch by default.
|
|
141
|
+
* @param readDirectory Immediate reload-directory fingerprints use this
|
|
142
|
+
* reader; native readdirSync by default.
|
|
143
|
+
* @param getCompilerInputs Read each resolved project's absolute compiler
|
|
144
|
+
* membership; the default invokes the native compiler. Readers throw
|
|
145
|
+
* listing failures and retain ownership of their returned array, which this
|
|
146
|
+
* topology does not mutate.
|
|
147
|
+
*/
|
|
148
|
+
constructor(options, callbacks, openDirectoryWatch = watchDirectory_1.watchDirectory, openFileWatch = node_fs_1.default.watch, readDirectory = node_fs_1.default.readdirSync, getCompilerInputs = listCompilerInputs) {
|
|
83
149
|
this.options = options;
|
|
84
150
|
this.callbacks = callbacks;
|
|
151
|
+
this.openDirectoryWatch = openDirectoryWatch;
|
|
152
|
+
this.openFileWatch = openFileWatch;
|
|
153
|
+
this.readDirectory = readDirectory;
|
|
154
|
+
this.getCompilerInputs = getCompilerInputs;
|
|
85
155
|
}
|
|
86
|
-
/**
|
|
156
|
+
/**
|
|
157
|
+
* Re-resolve compiler inputs and notify when the resolved topology changes,
|
|
158
|
+
* including membership, output/configuration or analysis-mode changes. Errors
|
|
159
|
+
* propagate to the caller; native watcher registration failures are reported
|
|
160
|
+
* through onError while previous coverage remains live.
|
|
161
|
+
*
|
|
162
|
+
* @evidence contracts/common.md#principled-implementation The compiler-input operation defines membership and its native default reads the actual compiler list; new coverage is registered before stale coverage retires, and registration reconciliation compares against pre-registration baselines.
|
|
163
|
+
* @evidence contracts/common.md#clear-and-simple-design One refresh delegates compiler population resolution, watcher synchronization and notification classification to separate private owners.
|
|
164
|
+
* @evidence contracts/common.md#prohibited-implementation-shortcuts Predicted outputs never subtract from compiler-reported inputs; failed registration cannot claim complete replacement coverage.
|
|
165
|
+
* @evidence contracts/common.md#meaningful-documentation Native prose states notification gating, thrown errors and registration error ownership following the documentation skill.
|
|
166
|
+
* @evidence contracts/portability.md#os-neutral-implementation Compiler processes use explicit argv/env; native APIs own path grammar and backend differences. Lexical membership uses measured component case policy, keeping unknown names and symlink aliases distinct instead of folding all Windows paths.
|
|
167
|
+
* @evidence contracts/performance.md#efficient-algorithms Project/reference configuration discovery, output inference and supplied/native compiler listing precede file/key snapshot passes. Native path/case/ancestor work and newly admitted file hashing add text/byte costs; broad reconciliation stats tracked files and strongly reads metadata/owner movement, while named/gap events request strong reads. Windows directory pruning is pairwise, and extra/project watcher reconciliation adds its own scans and backend callback costs without a file-count or deadline cap.
|
|
168
|
+
* @evidence contracts/performance.md#reuse-equivalent-work Existing live watchers and unchanged fingerprints are reused by key; one fresh synchronous transaction shares parent case probes across membership, output and directory keys. One current root selection shares response inspection across referenced-project output queries; response observations are checked again after membership and never cached across refreshes. Registration microtasks coalesce gap work while actual compiler membership is refreshed rather than inferred from quiet notifications.
|
|
169
|
+
* @evidence contracts/performance.md#bound-retention-and-release-resources Current snapshots prune removed members and synchronization attempts obsolete handle closure, keeping old coverage after incomplete registration. Current/recovery populations and observations have no size cap; supplied close/error callbacks can throw and close does not await backend completion. State remains owner-held until released.
|
|
170
|
+
*/
|
|
87
171
|
refresh(notify) {
|
|
88
172
|
this.refreshCompilerInputs(notify, false);
|
|
89
173
|
}
|
|
90
174
|
refreshCompilerInputs(notify, skipUnobservedProjectInputWatchRoots) {
|
|
91
|
-
|
|
175
|
+
this.beginLexicalTransaction();
|
|
176
|
+
const next = resolveWatchTopology(this.options, this.extraInputs, this.lexicalIdentities, this.getCompilerInputs);
|
|
92
177
|
const compilerProgramMembershipChange = next.analysisOnly &&
|
|
93
|
-
mapsEqual(this.reloadFiles, next.reloadFiles) &&
|
|
94
|
-
mapsEqual(this.outputFiles, next.outputFiles) &&
|
|
95
|
-
mapsEqual(this.outputs, next.outputs)
|
|
178
|
+
WatchPaths_1.WatchPaths.mapsEqual(this.reloadFiles, next.reloadFiles) &&
|
|
179
|
+
WatchPaths_1.WatchPaths.mapsEqual(this.outputFiles, next.outputFiles) &&
|
|
180
|
+
WatchPaths_1.WatchPaths.mapsEqual(this.outputs, next.outputs)
|
|
96
181
|
? compilerMembershipChange(this.files, next.files)
|
|
97
182
|
: [];
|
|
98
183
|
const projectInputProgramOverlap = projectInputCompilerMembershipChange(this.projectInputs, compilerProgramMembershipChange);
|
|
@@ -102,11 +187,11 @@ class WatchTopology {
|
|
|
102
187
|
? projectInputProgramOverlap
|
|
103
188
|
: undefined;
|
|
104
189
|
const changed = this.analysisOnly !== next.analysisOnly ||
|
|
105
|
-
mapsEqual(this.files, next.files) === false ||
|
|
106
|
-
mapsEqual(this.directories, next.directories) === false ||
|
|
107
|
-
mapsEqual(this.outputFiles, next.outputFiles) === false ||
|
|
108
|
-
mapsEqual(this.outputs, next.outputs) === false ||
|
|
109
|
-
mapsEqual(this.reloadFiles, next.reloadFiles) === false;
|
|
190
|
+
WatchPaths_1.WatchPaths.mapsEqual(this.files, next.files) === false ||
|
|
191
|
+
WatchPaths_1.WatchPaths.mapsEqual(this.directories, next.directories) === false ||
|
|
192
|
+
WatchPaths_1.WatchPaths.mapsEqual(this.outputFiles, next.outputFiles) === false ||
|
|
193
|
+
WatchPaths_1.WatchPaths.mapsEqual(this.outputs, next.outputs) === false ||
|
|
194
|
+
WatchPaths_1.WatchPaths.mapsEqual(this.reloadFiles, next.reloadFiles) === false;
|
|
110
195
|
this.analysisOnly = next.analysisOnly;
|
|
111
196
|
this.files = next.files;
|
|
112
197
|
// Stamp the tracked set as it is resolved, so the first event that cannot
|
|
@@ -121,18 +206,13 @@ class WatchTopology {
|
|
|
121
206
|
// has a baseline would advance it past a change nobody reported, and the
|
|
122
207
|
// next unnamed event would then read that change as no change at all.
|
|
123
208
|
if (!this.compilerFileSnapshots.has(key)) {
|
|
124
|
-
this.compilerFileSnapshots.set(key, compilerFileSnapshot(file));
|
|
209
|
+
this.compilerFileSnapshots.set(key, compilerFileSnapshot(file, fingerprintProjectInputFile(file)));
|
|
125
210
|
}
|
|
126
211
|
}
|
|
127
212
|
this.directories = next.directories;
|
|
128
213
|
this.outputFiles = next.outputFiles;
|
|
129
214
|
this.outputs = next.outputs;
|
|
130
215
|
this.reloadFiles = next.reloadFiles;
|
|
131
|
-
for (const key of this.projectInputCompilerAcknowledgements.keys()) {
|
|
132
|
-
if (!next.files.has(key)) {
|
|
133
|
-
this.projectInputCompilerAcknowledgements.delete(key);
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
216
|
const projectInputProgramReload = projectInputProgramOverlap.length === 0
|
|
137
217
|
? false
|
|
138
218
|
: this.acknowledgeProjectInputCompilerMembership(projectInputProgramOverlap);
|
|
@@ -169,15 +249,12 @@ class WatchTopology {
|
|
|
169
249
|
* project watcher names the same creation. The rebuild scheduled here already
|
|
170
250
|
* consumes the current project bytes, so publishing their strong fingerprints
|
|
171
251
|
* keeps the later parent event from rediscovering the same population delta.
|
|
172
|
-
*
|
|
173
|
-
*
|
|
174
|
-
* while different bytes are a real later edit and remain observable even
|
|
175
|
-
* inside filesystem timestamp resolution.
|
|
252
|
+
* Compiler files keep their own content fingerprints at admission, so a
|
|
253
|
+
* delayed named event for the same bytes is quiet on every backend.
|
|
176
254
|
*/
|
|
177
255
|
acknowledgeProjectInputCompilerMembership(changed) {
|
|
178
256
|
const matches = this.collectProjectInputMatches();
|
|
179
|
-
const fingerprints = fingerprintProjectInputMatches(matches);
|
|
180
|
-
const identities = (0, projectInputPathIdentity_1.createProjectInputPathIdentityContext)();
|
|
257
|
+
const fingerprints = fingerprintProjectInputMatches(matches, this.readDirectory);
|
|
181
258
|
const changedInputs = projectInputChangedPaths({
|
|
182
259
|
next: matches,
|
|
183
260
|
nextFingerprints: fingerprints,
|
|
@@ -186,13 +263,19 @@ class WatchTopology {
|
|
|
186
263
|
});
|
|
187
264
|
const population = this.projectInputPopulation();
|
|
188
265
|
const causedBy = projectInputCompilerMembershipProjectChanges(changed, population.globs);
|
|
189
|
-
const
|
|
266
|
+
const reloadInput = {
|
|
190
267
|
causedBy,
|
|
191
268
|
changed: causedBy.length === 1 ? causedBy[0] : undefined,
|
|
192
269
|
changedInputs,
|
|
193
270
|
globs: population.globs,
|
|
194
271
|
reloadDirectories: population.reloadDirectories,
|
|
195
272
|
reloadFiles: population.reloadFiles ?? [],
|
|
273
|
+
};
|
|
274
|
+
const reload = (0, projectInputReloadEventShouldNotify_1.projectInputReloadEventShouldNotify)(reloadInput);
|
|
275
|
+
reportProjectInputDecision({
|
|
276
|
+
source: "compiler-membership",
|
|
277
|
+
...reloadInput,
|
|
278
|
+
reload,
|
|
196
279
|
});
|
|
197
280
|
// The callback below consumes the complete population observed by this
|
|
198
281
|
// scan. Crucially, reload classification runs against the old baseline
|
|
@@ -200,28 +283,54 @@ class WatchTopology {
|
|
|
200
283
|
// instead of disappearing behind the warm compiler-membership handoff.
|
|
201
284
|
this.projectInputMatches = matches;
|
|
202
285
|
this.projectInputFingerprints = fingerprints;
|
|
203
|
-
for (const location of changed) {
|
|
204
|
-
const compilerKey = pathKey(location);
|
|
205
|
-
if (!this.files.has(compilerKey))
|
|
206
|
-
continue;
|
|
207
|
-
const fingerprint = fingerprints.get(identities.resolve(location).key);
|
|
208
|
-
if (fingerprint !== undefined && fingerprint !== "") {
|
|
209
|
-
this.projectInputCompilerAcknowledgements.set(compilerKey, fingerprint);
|
|
210
|
-
}
|
|
211
|
-
}
|
|
212
286
|
return reload;
|
|
213
287
|
}
|
|
214
|
-
/**
|
|
288
|
+
/**
|
|
289
|
+
* Add Go plugin source trees discovered by the real build lane. Existing
|
|
290
|
+
* input fingerprints retain their baseline; new inputs are captured before
|
|
291
|
+
* the caller builds them, so later notifications can compare that
|
|
292
|
+
* observation. This does not freeze the source tree or prove every transient
|
|
293
|
+
* edit was seen.
|
|
294
|
+
*
|
|
295
|
+
* @evidence contracts/common.md#principled-implementation Published plugin inputs define the source corpus, and retaining existing pre-build baselines keeps unreported edits visible.
|
|
296
|
+
* @evidence contracts/common.md#clear-and-simple-design Deduplication, baseline retention and compiler/watch reconciliation remain ordered phases.
|
|
297
|
+
* @evidence contracts/common.md#prohibited-implementation-shortcuts The actual plugin source digest applies its owning source-selection and pruning policy; named plugins or fixture output do not replace observed input state.
|
|
298
|
+
* @evidence contracts/common.md#meaningful-documentation Native prose explains baseline timing and why existing inputs are not restamped following the documentation skill.
|
|
299
|
+
* @evidence contracts/portability.md#os-neutral-implementation Native path resolution and canonical backend registration govern source trees; lexical keys preserve declarations and unknown names, folding ASCII only under measured insensitive parents rather than an OS-derived rule.
|
|
300
|
+
* @evidence contracts/performance.md#efficient-algorithms Input/path keys deduplicate with text and native case/ancestor work; only newly admitted inputs compute initial source digests. Those reads scan the selected pruned corpus, then refresh(false) also pays project/compiler listing, directory traversal and watcher reconciliation; fixed publication count does not bound delegated bytes or backend work.
|
|
301
|
+
* @evidence contracts/performance.md#reuse-equivalent-work Unchanged ordered input sets return immediately; existing inputs reuse their recorded digest until actual notification processing establishes changed consumed state.
|
|
302
|
+
* @evidence contracts/performance.md#bound-retention-and-release-resources Publications replace input/digest populations and case-observation caches without a population cap; synchronization attempts obsolete watcher closure. Native/supplied closure has its own lifetime and can throw; owner close does not prove every backend has stopped or every retained snapshot byte was released.
|
|
303
|
+
*/
|
|
215
304
|
setExtraInputs(inputs) {
|
|
216
|
-
|
|
305
|
+
this.beginLexicalTransaction();
|
|
306
|
+
const next = uniqueExistingPaths(inputs, this.lexicalIdentities);
|
|
217
307
|
if (arraysEqual(this.extraInputs, next))
|
|
218
308
|
return;
|
|
219
309
|
this.extraInputs = next;
|
|
310
|
+
// The load reports its inputs before any build reads them, so the state
|
|
311
|
+
// recorded here precedes every read, and an edit after it moves the state.
|
|
312
|
+
// An input already tracked keeps its baseline: restamping it would absorb
|
|
313
|
+
// a change nobody reported.
|
|
314
|
+
const states = new Map();
|
|
315
|
+
for (const input of next) {
|
|
316
|
+
const key = this.pathKey(input);
|
|
317
|
+
states.set(key, this.pluginInputStates.get(key) ?? pluginInputState(input));
|
|
318
|
+
}
|
|
319
|
+
this.pluginInputStates = states;
|
|
220
320
|
this.refresh(false);
|
|
221
321
|
}
|
|
222
322
|
/**
|
|
223
323
|
* Reconcile project-rule dependencies, retaining absent files and empty glob
|
|
224
324
|
* populations as live topology.
|
|
325
|
+
*
|
|
326
|
+
* @evidence contracts/common.md#principled-implementation Both lexical declarations and current physical identities remain observable, including missing members and empty globs; republication can update aliased watcher ownership without requiring population movement.
|
|
327
|
+
* @evidence contracts/common.md#clear-and-simple-design Publication normalization, baseline population capture and root synchronization are separate stages, with one retained declaration-owner map.
|
|
328
|
+
* @evidence contracts/common.md#prohibited-implementation-shortcuts Missing inputs are not dropped from observation, and an unavailable safe root is reported rather than widened over a system ancestor.
|
|
329
|
+
* @evidence contracts/common.md#meaningful-documentation Native prose and helper paragraphs explain absent populations, aliases, handoff reconciliation and root ceilings following the documentation skill.
|
|
330
|
+
* @evidence contracts/portability.md#os-neutral-implementation Transaction-owned native case observations and physical identities distinguish resolved aliases; unknown case routes both glob interpretations without merging keys, while canonical registration and separate link-entry observation preserve retargets.
|
|
331
|
+
* @evidence contracts/performance.md#efficient-algorithms Publication normalizes native identities and sorts distinct path lists, then compares snapshots and reconciles alias/watch roots. Changed publications enumerate deduplicated physical glob roots, test applicable patterns with pattern/path/native identity costs and fingerprint selected file bytes or sorted immediate directory entries. Parent/case probes, repeated declaration/root admission and backend work add costs beyond file-pattern visits; payloads and traversal depth are uncapped.
|
|
332
|
+
* @evidence contracts/performance.md#reuse-equivalent-work Equal normalized publications reuse content baselines but still reconcile lexical aliases; registration microtasks coalesce equivalent handoff work, and transaction indexes reuse identity and output-overlap decisions within one scan.
|
|
333
|
+
* @evidence contracts/performance.md#bound-retention-and-release-resources Publication prunes retired declaration-owner choices and replaces uncapped match/fingerprint populations. Watcher retirement invokes close without awaiting backend completion, and supplied errors can interrupt cleanup. Weak output-overlap keys do not retain old identity transactions; the current declaration snapshot can borrow caller arrays until replaced or the facade is released.
|
|
225
334
|
*/
|
|
226
335
|
setProjectInputs(inputs) {
|
|
227
336
|
const next = normalizeProjectInputSnapshot(inputs);
|
|
@@ -245,10 +354,27 @@ class WatchTopology {
|
|
|
245
354
|
{ ...(inputs.declared ?? inputs), root: inputs.root },
|
|
246
355
|
]);
|
|
247
356
|
this.projectInputMatches = this.collectProjectInputMatches();
|
|
248
|
-
this.projectInputFingerprints = fingerprintProjectInputMatches(this.projectInputMatches);
|
|
357
|
+
this.projectInputFingerprints = fingerprintProjectInputMatches(this.projectInputMatches, this.readDirectory);
|
|
249
358
|
this.syncProjectInputWatchers();
|
|
250
359
|
}
|
|
251
|
-
/**
|
|
360
|
+
/**
|
|
361
|
+
* Invoke close on owned watchers so their backends can retire. Scheduled
|
|
362
|
+
* reconciliation callbacks observe the closed state and retire without
|
|
363
|
+
* creating replacement subscriptions. A thrown close propagates and
|
|
364
|
+
* interrupts remaining cleanup; this void method does not await
|
|
365
|
+
* native/backend shutdown or guarantee event-loop drain.
|
|
366
|
+
*
|
|
367
|
+
* @evidence contracts/common.md#principled-implementation Marking the owner closed before retiring subscriptions prevents queued reconciliations from reopening native handles.
|
|
368
|
+
* @evidence contracts/common.md#clear-and-simple-design One shutdown operation closes and clears each distinct watcher population through a shared helper.
|
|
369
|
+
* @evidence contracts/common.md#prohibited-implementation-shortcuts Shutdown invokes actual owned subscription close methods rather than only suppressing output; errors propagate and no backend completion is fabricated.
|
|
370
|
+
* @evidence contracts/common.md#meaningful-documentation Native paragraphs explain event-loop release and queued-work behavior following the documentation skill.
|
|
371
|
+
* @evidence contracts/portability.md#os-neutral-implementation Shared close methods retire both Node handles and macOS registry subscriptions without exposing native handle types.
|
|
372
|
+
* @evidence contracts/performance.md#efficient-algorithms Each successfully reached live map traverses its watcher references and invokes backend-owned close work before clearing. Completed maps make later traversals empty; delegated cleanup costs and a thrown callback are not bounded by reference count alone.
|
|
373
|
+
*
|
|
374
|
+
* @evidenceExclude contracts/performance.md#reuse-equivalent-work Shutdown decides no equivalence of compilation or fingerprint work.
|
|
375
|
+
*
|
|
376
|
+
* @evidence contracts/performance.md#bound-retention-and-release-resources On successful completion all five watcher maps clear and the lexical transaction is replaced; queued tasks observe the closed guard. A thrown close can leave later maps retained, and backend closure is not joined. Snapshot/declaration/pending byte state remains until replaced or the facade is released.
|
|
377
|
+
*/
|
|
252
378
|
close() {
|
|
253
379
|
this.closed = true;
|
|
254
380
|
closeWatchers(this.fileWatchers);
|
|
@@ -256,6 +382,17 @@ class WatchTopology {
|
|
|
256
382
|
closeWatchers(this.extraWatchers);
|
|
257
383
|
closeWatchers(this.projectInputWatchers);
|
|
258
384
|
closeWatchers(this.projectInputLinkWatchers);
|
|
385
|
+
this.beginLexicalTransaction();
|
|
386
|
+
}
|
|
387
|
+
/** Start fresh native case observations for one synchronous watch decision. */
|
|
388
|
+
beginLexicalTransaction() {
|
|
389
|
+
this.lexicalIdentities = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)({
|
|
390
|
+
throwOnRealpathError: false,
|
|
391
|
+
});
|
|
392
|
+
}
|
|
393
|
+
/** Keep lexical alias ownership while sharing this decision's case probes. */
|
|
394
|
+
pathKey(location) {
|
|
395
|
+
return WatchPaths_1.WatchPaths.pathKey(location, this.lexicalIdentities);
|
|
259
396
|
}
|
|
260
397
|
syncFileWatchers(skipMissing = false) {
|
|
261
398
|
const previous = new Map(this.fileWatchers);
|
|
@@ -264,39 +401,57 @@ class WatchTopology {
|
|
|
264
401
|
: skipMissing
|
|
265
402
|
? new Map([...this.files].filter(([, location]) => node_fs_1.default.existsSync(location)))
|
|
266
403
|
: this.files;
|
|
267
|
-
syncWatchers(this.fileWatchers, files, (location) =>
|
|
404
|
+
(0, syncWatchers_1.syncWatchers)(this.fileWatchers, files, (location) => this.openFileWatch(watcherRegistrationPath(location), { persistent: true }, () => {
|
|
405
|
+
this.beginLexicalTransaction();
|
|
268
406
|
// A per-file watcher fires on any filesystem attention its target
|
|
269
407
|
// receives, and it carries no filename to distinguish an edit from
|
|
270
408
|
// a touch. It answers the same question the unnamed directory event
|
|
271
409
|
// answers, so it answers it the same way: from the bytes.
|
|
272
|
-
const movement = this.compilerFileMovement(location);
|
|
410
|
+
const movement = this.compilerFileMovement(location, true);
|
|
273
411
|
if (movement.owner)
|
|
274
412
|
this.rearmFileWatchers([location], true);
|
|
275
|
-
if (!movement
|
|
413
|
+
if (!this.compilerMovementReports(location, movement))
|
|
276
414
|
return;
|
|
277
|
-
this.
|
|
278
|
-
kind: this.classifyCompilerInput(location),
|
|
279
|
-
path: location,
|
|
280
|
-
});
|
|
415
|
+
this.reportCompilerFileChange(location);
|
|
281
416
|
}), (location, error) => this.callbacks.onError(location, error), () => this.closed === false);
|
|
282
417
|
return [...this.fileWatchers].some(([key, watcher]) => previous.get(key) !== watcher);
|
|
283
418
|
}
|
|
284
|
-
/**
|
|
285
|
-
|
|
286
|
-
|
|
419
|
+
/**
|
|
420
|
+
* Compare a tracked file with its last observed bytes and physical owner.
|
|
421
|
+
*
|
|
422
|
+
* A named event or observation gap reads the bytes even when time and size
|
|
423
|
+
* stayed still. A broad registration scan reads only a file whose metadata or
|
|
424
|
+
* owner moved, so an unrelated event does not read the whole Program.
|
|
425
|
+
*/
|
|
426
|
+
compilerFileMovement(location, strong = false) {
|
|
427
|
+
const key = this.pathKey(location);
|
|
287
428
|
const previous = this.compilerFileSnapshots.get(key);
|
|
288
|
-
const
|
|
289
|
-
|
|
429
|
+
const metadata = compilerFileSnapshot(location, "");
|
|
430
|
+
const read = strong ||
|
|
431
|
+
previous === undefined ||
|
|
432
|
+
previous.content !== metadata.content ||
|
|
433
|
+
previous.owner !== metadata.owner;
|
|
434
|
+
const fingerprint = read
|
|
435
|
+
? fingerprintProjectInputFile(location)
|
|
436
|
+
: (previous?.fingerprint ?? "");
|
|
437
|
+
this.compilerFileSnapshots.set(key, { ...metadata, fingerprint });
|
|
290
438
|
return {
|
|
291
|
-
content: previous
|
|
292
|
-
|
|
439
|
+
content: previous === undefined
|
|
440
|
+
? fingerprint !== ""
|
|
441
|
+
: previous.fingerprint !== fingerprint,
|
|
442
|
+
owner: previous?.owner !== metadata.owner,
|
|
293
443
|
};
|
|
294
444
|
}
|
|
445
|
+
/** A config's physical replacement can change resolution with equal bytes. */
|
|
446
|
+
compilerMovementReports(location, movement) {
|
|
447
|
+
return (movement.content ||
|
|
448
|
+
(movement.owner && this.classifyCompilerInput(location) === "config"));
|
|
449
|
+
}
|
|
295
450
|
syncDirectoryWatchers() {
|
|
296
451
|
const previous = new Map(this.directoryWatchers);
|
|
297
452
|
const desired = new Map(this.directories);
|
|
298
453
|
for (const [key, location] of this.observedDirectories) {
|
|
299
|
-
if (isDirectory(location) === false ||
|
|
454
|
+
if (WatchPaths_1.WatchPaths.isDirectory(location) === false ||
|
|
300
455
|
this.isCompilerOutputDirectory(location) ||
|
|
301
456
|
this.isProjectInputDirectory(location)) {
|
|
302
457
|
this.observedDirectories.delete(key);
|
|
@@ -306,40 +461,32 @@ class WatchTopology {
|
|
|
306
461
|
}
|
|
307
462
|
if (process.platform === "win32") {
|
|
308
463
|
for (const [key, location] of desired) {
|
|
309
|
-
if ([...desired].some(([candidateKey, candidate]) => candidateKey !== key &&
|
|
464
|
+
if ([...desired].some(([candidateKey, candidate]) => candidateKey !== key &&
|
|
465
|
+
WatchPaths_1.WatchPaths.isPathWithin(candidate, location, this.lexicalIdentities))) {
|
|
310
466
|
desired.delete(key);
|
|
311
467
|
}
|
|
312
468
|
}
|
|
313
469
|
}
|
|
314
|
-
syncWatchers(this.directoryWatchers, desired, (location) =>
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
}, (event, filename) => {
|
|
318
|
-
const changed = filename === null
|
|
319
|
-
? undefined
|
|
320
|
-
: node_path_1.default.resolve(location, filename.toString());
|
|
470
|
+
(0, syncWatchers_1.syncWatchers)(this.directoryWatchers, desired, (location) => this.openDirectoryWatch(watcherRegistrationPath(location), process.platform === "win32", (event, filename, gap) => {
|
|
471
|
+
this.beginLexicalTransaction();
|
|
472
|
+
const changed = filename === null ? undefined : node_path_1.default.resolve(location, filename);
|
|
321
473
|
const pluginInput = changed ?? location;
|
|
322
474
|
if (this.isPluginInput(pluginInput)) {
|
|
323
|
-
this.
|
|
324
|
-
kind: "plugin",
|
|
325
|
-
path: pluginInput,
|
|
326
|
-
});
|
|
475
|
+
this.notePluginNotification(pluginInput);
|
|
327
476
|
return;
|
|
328
477
|
}
|
|
329
|
-
const plan = planCompilerDirectoryWatchEvent({
|
|
478
|
+
const plan = (0, planCompilerDirectoryWatchEvent_1.planCompilerDirectoryWatchEvent)({
|
|
330
479
|
changed,
|
|
331
480
|
event,
|
|
332
481
|
exists: node_fs_1.default.existsSync,
|
|
333
482
|
location,
|
|
483
|
+
identities: this.lexicalIdentities,
|
|
334
484
|
platform: process.platform,
|
|
335
485
|
trackedFiles: this.files,
|
|
336
486
|
});
|
|
337
487
|
this.rearmFileWatchers(plan.rearm);
|
|
338
|
-
for (const file of this.compilerChangesToReport(plan.changes, changed,
|
|
339
|
-
this.
|
|
340
|
-
kind: this.classifyCompilerInput(file),
|
|
341
|
-
path: file,
|
|
342
|
-
});
|
|
488
|
+
for (const file of this.compilerChangesToReport(plan.changes, changed, gap === true)) {
|
|
489
|
+
this.reportCompilerFileChange(file);
|
|
343
490
|
}
|
|
344
491
|
if (plan.refresh)
|
|
345
492
|
this.refreshFromDirectory(location, changed);
|
|
@@ -371,6 +518,7 @@ class WatchTopology {
|
|
|
371
518
|
this.compilerPostRegistrationReconciliationScheduled = false;
|
|
372
519
|
if (this.closed)
|
|
373
520
|
return;
|
|
521
|
+
this.beginLexicalTransaction();
|
|
374
522
|
const refreshCompilerMembership = this.compilerPostRegistrationMembershipRefresh;
|
|
375
523
|
const skipUnobservedProjectInputWatchRoots = this.compilerPostRegistrationSkipUnobservedProjectInputWatchRoots;
|
|
376
524
|
this.compilerPostRegistrationMembershipRefresh = false;
|
|
@@ -379,21 +527,18 @@ class WatchTopology {
|
|
|
379
527
|
const rearm = [];
|
|
380
528
|
for (const file of this.files.values()) {
|
|
381
529
|
const movement = this.compilerFileMovement(file);
|
|
382
|
-
if (movement
|
|
530
|
+
if (this.compilerMovementReports(file, movement))
|
|
383
531
|
changed.push(file);
|
|
384
532
|
if (movement.owner)
|
|
385
533
|
rearm.push(file);
|
|
386
534
|
}
|
|
387
535
|
// A replacement can move the path to a new inode without changing its
|
|
388
|
-
//
|
|
389
|
-
//
|
|
390
|
-
//
|
|
536
|
+
// bytes. Rebind an ordinary source without inventing a content change;
|
|
537
|
+
// report a config owner transition because it can change resolution.
|
|
538
|
+
// Missing entries remain covered by their parent directory.
|
|
391
539
|
this.rearmFileWatchers(rearm, true);
|
|
392
540
|
for (const file of changed) {
|
|
393
|
-
this.
|
|
394
|
-
kind: this.classifyCompilerInput(file),
|
|
395
|
-
path: file,
|
|
396
|
-
});
|
|
541
|
+
this.reportCompilerFileChange(file);
|
|
397
542
|
}
|
|
398
543
|
if (!refreshCompilerMembership)
|
|
399
544
|
return;
|
|
@@ -404,10 +549,10 @@ class WatchTopology {
|
|
|
404
549
|
this.refreshCompilerInputs(true, skipUnobservedProjectInputWatchRoots);
|
|
405
550
|
}
|
|
406
551
|
catch (error) {
|
|
407
|
-
const reported = new Set(changed.map(pathKey));
|
|
552
|
+
const reported = new Set(changed.map((file) => this.pathKey(file)));
|
|
408
553
|
const reconciledChange = changed.length === 1 ? changed[0] : undefined;
|
|
409
|
-
for (const reload of reloadInputsForFailedTopologyRefresh(this.reloadFiles.values(), reconciledChange)) {
|
|
410
|
-
if (reported.has(pathKey(reload)))
|
|
554
|
+
for (const reload of (0, reloadInputsForFailedTopologyRefresh_1.reloadInputsForFailedTopologyRefresh)(this.reloadFiles.values(), reconciledChange, this.lexicalIdentities)) {
|
|
555
|
+
if (reported.has(this.pathKey(reload)))
|
|
411
556
|
continue;
|
|
412
557
|
this.callbacks.onInputChange({ kind: "config", path: reload });
|
|
413
558
|
}
|
|
@@ -418,74 +563,125 @@ class WatchTopology {
|
|
|
418
563
|
});
|
|
419
564
|
}
|
|
420
565
|
/**
|
|
421
|
-
* Narrow a plan's changes to
|
|
566
|
+
* Narrow a plan's changes to tracked files whose bytes actually moved.
|
|
422
567
|
*
|
|
423
|
-
* A
|
|
424
|
-
*
|
|
425
|
-
*
|
|
426
|
-
* ordinary activity elsewhere in the project, so the compiler lane would wake
|
|
427
|
-
* for sources nobody touched. Only a content notification passes through: it
|
|
428
|
-
* is the one event that claims the bytes moved. A rename claims the directory
|
|
429
|
-
* entry was rewritten and an unnamed event claims nothing, so both are
|
|
430
|
-
* decided from the bytes, which is the question neither of them answered.
|
|
568
|
+
* A named event checks its file even when time and size stayed still. A gap
|
|
569
|
+
* can hide such a rewrite anywhere under the watched root, so every candidate
|
|
570
|
+
* gets a strong check. Ordinary broad scans still use metadata first.
|
|
431
571
|
*/
|
|
432
|
-
compilerChangesToReport(changes, changed,
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
// replaced by an identical copy, without its content moving at all — and an
|
|
438
|
-
// event that cannot name anything makes no claim about content either.
|
|
439
|
-
// Those two are decided from the bytes, and the rearm they drive is
|
|
440
|
-
// unaffected, because rebinding is about the inode and not the content.
|
|
441
|
-
if (changed !== undefined && event !== "rename") {
|
|
442
|
-
return changes.filter((file) => {
|
|
443
|
-
const key = pathKey(file);
|
|
444
|
-
const acknowledged = this.projectInputCompilerAcknowledgements.get(key);
|
|
445
|
-
this.projectInputCompilerAcknowledgements.delete(key);
|
|
446
|
-
this.recordCompilerFileSnapshot(file);
|
|
447
|
-
return (acknowledged === undefined ||
|
|
448
|
-
acknowledged !== fingerprintProjectInputFile(file));
|
|
449
|
-
});
|
|
450
|
-
}
|
|
451
|
-
return changes.filter((file) => this.compilerFileMovement(file).content);
|
|
572
|
+
compilerChangesToReport(changes, changed, gap) {
|
|
573
|
+
return changes.filter((file) => {
|
|
574
|
+
const movement = this.compilerFileMovement(file, changed !== undefined || gap);
|
|
575
|
+
return this.compilerMovementReports(file, movement);
|
|
576
|
+
});
|
|
452
577
|
}
|
|
453
|
-
|
|
454
|
-
|
|
578
|
+
/**
|
|
579
|
+
* Let a selected project input consume its compiler content notification.
|
|
580
|
+
* Both lanes watch a resolveJsonModule file, but its project fingerprint
|
|
581
|
+
* decides the resident update once whichever backend hears the edit first. A
|
|
582
|
+
* missing compiler member instead reconciles Program membership before a
|
|
583
|
+
* stale file-watch notification can schedule a second build.
|
|
584
|
+
*/
|
|
585
|
+
reportCompilerFileChange(location) {
|
|
586
|
+
if (this.classifyCompilerInput(location) === "compiler") {
|
|
587
|
+
if (node_fs_1.default.existsSync(location)) {
|
|
588
|
+
if (this.projectInputMatches.size !== 0) {
|
|
589
|
+
const key = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)({
|
|
590
|
+
throwOnRealpathError: false,
|
|
591
|
+
}).resolve(location).key;
|
|
592
|
+
if (this.projectInputMatches.has(key) &&
|
|
593
|
+
this.refreshProjectInputs(node_path_1.default.dirname(location), location))
|
|
594
|
+
return;
|
|
595
|
+
}
|
|
596
|
+
}
|
|
597
|
+
else {
|
|
598
|
+
this.refreshFromDirectory(node_path_1.default.dirname(location), location);
|
|
599
|
+
if (!this.files.has(this.pathKey(location)))
|
|
600
|
+
return;
|
|
601
|
+
}
|
|
602
|
+
}
|
|
603
|
+
this.callbacks.onInputChange({
|
|
604
|
+
kind: this.classifyCompilerInput(location),
|
|
605
|
+
path: location,
|
|
606
|
+
});
|
|
455
607
|
}
|
|
456
608
|
rearmFileWatchers(files, skipMissing = false) {
|
|
457
609
|
for (const file of files) {
|
|
458
|
-
const key = pathKey(file);
|
|
459
|
-
this.fileWatchers.get(key)
|
|
610
|
+
const key = this.pathKey(file);
|
|
611
|
+
const watcher = this.fileWatchers.get(key);
|
|
612
|
+
if (watcher === undefined)
|
|
613
|
+
continue;
|
|
614
|
+
watcher.close();
|
|
460
615
|
this.fileWatchers.delete(key);
|
|
461
616
|
}
|
|
462
617
|
if (this.syncFileWatchers(skipMissing)) {
|
|
463
618
|
this.scheduleCompilerPostRegistrationReconciliation(false, true);
|
|
464
619
|
}
|
|
465
620
|
}
|
|
621
|
+
/**
|
|
622
|
+
* Watch every directory of every plugin input, and report what a directory
|
|
623
|
+
* that appeared below an input already watched holds by now.
|
|
624
|
+
*
|
|
625
|
+
* Each directory has a watcher of its own, and a directory created below a
|
|
626
|
+
* plugin module is heard through its parent's; its own watcher is added only
|
|
627
|
+
* here, when that notification is decided (`decidePluginNotifications`) or
|
|
628
|
+
* the topology refreshes. A file written into it in between reaches no
|
|
629
|
+
* watcher on a platform whose watcher reports a directory's direct entries
|
|
630
|
+
* alone, and a build may have read the directory before the file landed. So
|
|
631
|
+
* once its watcher is registered, each entry it holds is noted as a plugin
|
|
632
|
+
* notification, as `@ttsc/unplugin`'s observer announces a directory it
|
|
633
|
+
* starts watching, and reported when it moved what a build reads. The
|
|
634
|
+
* directories of an input new to this sync are not reported: the load reports
|
|
635
|
+
* its inputs before any build reads them.
|
|
636
|
+
*/
|
|
466
637
|
syncExtraWatchers() {
|
|
467
638
|
const directories = new Map();
|
|
639
|
+
const appeared = [];
|
|
468
640
|
for (const input of this.extraInputs) {
|
|
641
|
+
const watchedBefore = this.watchedExtraInputs.has(this.pathKey(input));
|
|
469
642
|
for (const directory of collectInputDirectories(input)) {
|
|
470
|
-
|
|
643
|
+
const key = this.pathKey(directory);
|
|
644
|
+
directories.set(key, directory);
|
|
645
|
+
if (watchedBefore && !this.extraWatchers.has(key)) {
|
|
646
|
+
appeared.push(directory);
|
|
647
|
+
}
|
|
471
648
|
}
|
|
472
649
|
}
|
|
473
|
-
syncWatchers(this.extraWatchers, directories, (location) =>
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
650
|
+
(0, syncWatchers_1.syncWatchers)(this.extraWatchers, directories, (location) => this.openDirectoryWatch(watcherRegistrationPath(location), false, (_event, filename) => {
|
|
651
|
+
this.beginLexicalTransaction();
|
|
652
|
+
const changed = filename === null ? undefined : node_path_1.default.resolve(location, filename);
|
|
653
|
+
// The one decision every watcher that hears a plugin path shares;
|
|
654
|
+
// here it drops the entry of a directory the build passes over.
|
|
655
|
+
if (changed !== undefined && !this.isPluginInput(changed))
|
|
656
|
+
return;
|
|
657
|
+
this.notePluginNotification(changed ?? location);
|
|
481
658
|
}), (location, error) => this.callbacks.onError(location, error), () => this.closed === false);
|
|
659
|
+
this.watchedExtraInputs = new Set(this.extraInputs.map((input) => this.pathKey(input)));
|
|
660
|
+
for (const directory of appeared) {
|
|
661
|
+
// Only a directory now watched: one whose registration failed was
|
|
662
|
+
// reported through `onError`, and one gone meanwhile holds nothing.
|
|
663
|
+
if (!this.extraWatchers.has(this.pathKey(directory)))
|
|
664
|
+
continue;
|
|
665
|
+
let entries;
|
|
666
|
+
try {
|
|
667
|
+
entries = node_fs_1.default.readdirSync(directory);
|
|
668
|
+
}
|
|
669
|
+
catch {
|
|
670
|
+
continue;
|
|
671
|
+
}
|
|
672
|
+
for (const name of entries) {
|
|
673
|
+
const entry = node_path_1.default.join(directory, name);
|
|
674
|
+
if (this.isPluginInput(entry))
|
|
675
|
+
this.notePluginNotification(entry);
|
|
676
|
+
}
|
|
677
|
+
}
|
|
482
678
|
}
|
|
483
679
|
syncProjectInputWatchers(skipUnobservedProjectInputWatchRoots = false) {
|
|
484
680
|
if (this.closed)
|
|
485
681
|
return;
|
|
486
682
|
const previous = new Map(this.projectInputWatchers);
|
|
487
683
|
const previousLinks = new Map(this.projectInputLinkWatchers);
|
|
488
|
-
const identities = (0,
|
|
684
|
+
const identities = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)();
|
|
489
685
|
const desired = new Map();
|
|
490
686
|
const required = new Map();
|
|
491
687
|
for (const file of this.projectInputDeclarations("file")) {
|
|
@@ -495,7 +691,7 @@ class WatchTopology {
|
|
|
495
691
|
this.retainProjectInputWatchRoot(required, desired, identities, location, node_path_1.default.dirname(file), skipUnobservedProjectInputWatchRoots);
|
|
496
692
|
}
|
|
497
693
|
for (const glob of this.projectInputDeclarations("glob")) {
|
|
498
|
-
const root = literalGlobRoot(glob);
|
|
694
|
+
const root = (0, literalGlobRoot_1.literalGlobRoot)(glob);
|
|
499
695
|
if (this.isProjectInputCompilerOutputDirectory(root, identities)) {
|
|
500
696
|
continue;
|
|
501
697
|
}
|
|
@@ -516,15 +712,13 @@ class WatchTopology {
|
|
|
516
712
|
this.retainProjectInputWatchRoot(required, desired, identities, location, directory, skipUnobservedProjectInputWatchRoots);
|
|
517
713
|
}
|
|
518
714
|
const active = new Map();
|
|
519
|
-
for (const location of projectInputActiveWatchDirectories(desired.values(), identities)) {
|
|
715
|
+
for (const location of (0, projectInputActiveWatchDirectories_1.projectInputActiveWatchDirectories)(desired.values(), identities)) {
|
|
520
716
|
const identity = identities.resolve(location);
|
|
521
717
|
active.set(identity.key, identity.path);
|
|
522
718
|
}
|
|
523
719
|
this.projectInputRequiredWatchRoots = required;
|
|
524
|
-
syncWatchers(this.projectInputWatchers, active, (location) =>
|
|
525
|
-
const changed = filename === null
|
|
526
|
-
? undefined
|
|
527
|
-
: node_path_1.default.resolve(location, filename.toString());
|
|
720
|
+
(0, syncWatchers_1.syncWatchers)(this.projectInputWatchers, active, (location) => this.openDirectoryWatch(watcherRegistrationPath(location), true, (_event, filename) => {
|
|
721
|
+
const changed = filename === null ? undefined : node_path_1.default.resolve(location, filename);
|
|
528
722
|
this.refreshProjectInputs(location, changed);
|
|
529
723
|
}), (location, error) => {
|
|
530
724
|
const key = identities.resolve(location).key;
|
|
@@ -576,16 +770,14 @@ class WatchTopology {
|
|
|
576
770
|
continue;
|
|
577
771
|
if (this.isProjectInputCompilerOutput(declared, identities))
|
|
578
772
|
continue;
|
|
579
|
-
const parent = nearestExistingDirectory(node_path_1.default.dirname(declared));
|
|
773
|
+
const parent = WatchPaths_1.WatchPaths.nearestExistingDirectory(node_path_1.default.dirname(declared));
|
|
580
774
|
if (parent === undefined)
|
|
581
775
|
continue;
|
|
582
776
|
desired.set(identities.resolve(parent).key, parent);
|
|
583
777
|
}
|
|
584
778
|
}
|
|
585
|
-
syncWatchers(this.projectInputLinkWatchers, desired, (location) =>
|
|
586
|
-
const changed = filename === null
|
|
587
|
-
? undefined
|
|
588
|
-
: node_path_1.default.resolve(location, filename.toString());
|
|
779
|
+
(0, syncWatchers_1.syncWatchers)(this.projectInputLinkWatchers, desired, (location) => this.openDirectoryWatch(watcherRegistrationPath(location), false, (_event, filename) => {
|
|
780
|
+
const changed = filename === null ? undefined : node_path_1.default.resolve(location, filename);
|
|
589
781
|
this.refreshProjectInputs(location, changed);
|
|
590
782
|
}), (location, error) => this.callbacks.onError(location, error), () => this.closed === false);
|
|
591
783
|
}
|
|
@@ -611,7 +803,7 @@ class WatchTopology {
|
|
|
611
803
|
const requiredIdentity = identities.resolve(location ?? target);
|
|
612
804
|
required.set(requiredIdentity.key, requiredIdentity.path);
|
|
613
805
|
if (skipUnobservedProjectInputWatchRoots) {
|
|
614
|
-
const retainedActiveRoot = [...this.projectInputWatchers.keys()].find((root) => (0,
|
|
806
|
+
const retainedActiveRoot = [...this.projectInputWatchers.keys()].find((root) => (0, isProjectInputPathIdentityWithin_1.isProjectInputPathIdentityWithin)(root, requiredIdentity.key));
|
|
615
807
|
if (retainedActiveRoot !== undefined) {
|
|
616
808
|
desired.set(retainedActiveRoot, retainedActiveRoot);
|
|
617
809
|
return;
|
|
@@ -622,7 +814,7 @@ class WatchTopology {
|
|
|
622
814
|
this.projectInputUnobservedWatchRoots.has(requiredIdentity.key))) {
|
|
623
815
|
return;
|
|
624
816
|
}
|
|
625
|
-
const available = projectInputAvailableWatchDirectory(location, this.projectInputRejectedWatchRoots, identities, this.projectInputs.root);
|
|
817
|
+
const available = (0, projectInputAvailableWatchDirectory_1.projectInputAvailableWatchDirectory)(location, this.projectInputRejectedWatchRoots, identities, this.projectInputs.root);
|
|
626
818
|
if (available === undefined)
|
|
627
819
|
return;
|
|
628
820
|
const identity = identities.resolve(available);
|
|
@@ -718,7 +910,7 @@ class WatchTopology {
|
|
|
718
910
|
/** Report only newly uncovered project-input roots as an observation loss. */
|
|
719
911
|
reportUnobservedProjectInputWatchRoots(required) {
|
|
720
912
|
const active = [...this.projectInputWatchers.keys()];
|
|
721
|
-
const unavailable = new Map([...required].filter(([key]) => active.every((root) => !(0,
|
|
913
|
+
const unavailable = new Map([...required].filter(([key]) => active.every((root) => !(0, isProjectInputPathIdentityWithin_1.isProjectInputPathIdentityWithin)(root, key))));
|
|
722
914
|
const newlyUnavailable = [...unavailable]
|
|
723
915
|
.filter(([key]) => !this.projectInputUnobservedWatchRoots.has(key))
|
|
724
916
|
.map(([, location]) => location)
|
|
@@ -772,7 +964,7 @@ class WatchTopology {
|
|
|
772
964
|
...select(this.projectInputs),
|
|
773
965
|
...select(this.declaredProjectInputs),
|
|
774
966
|
]) {
|
|
775
|
-
const key = (0,
|
|
967
|
+
const key = (0, resolveProjectInputPath_1.resolveProjectInputPath)(entry);
|
|
776
968
|
if (seen.has(key))
|
|
777
969
|
continue;
|
|
778
970
|
seen.add(key);
|
|
@@ -783,17 +975,18 @@ class WatchTopology {
|
|
|
783
975
|
projectInputWatchRoot(kind, declaration, target) {
|
|
784
976
|
const key = projectInputDeclarationKey(kind, declaration);
|
|
785
977
|
const retained = this.projectInputWatchRoots.get(key);
|
|
786
|
-
if (retained !== undefined && isDirectory(retained))
|
|
978
|
+
if (retained !== undefined && WatchPaths_1.WatchPaths.isDirectory(retained))
|
|
787
979
|
return retained;
|
|
788
|
-
const resolved = projectInputRecursiveWatchRoot(target, this.projectInputs.root);
|
|
980
|
+
const resolved = ProjectInputWatchRules_1.ProjectInputWatchRules.projectInputRecursiveWatchRoot(target, this.projectInputs.root);
|
|
789
981
|
if (resolved !== undefined)
|
|
790
982
|
this.projectInputWatchRoots.set(key, resolved);
|
|
791
983
|
return resolved;
|
|
792
984
|
}
|
|
793
985
|
refreshProjectInputs(location, changed, skipUnobservedProjectInputWatchRoots = false) {
|
|
986
|
+
this.beginLexicalTransaction();
|
|
794
987
|
try {
|
|
795
988
|
const previous = this.projectInputMatches;
|
|
796
|
-
const identities = (0,
|
|
989
|
+
const identities = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)();
|
|
797
990
|
// One population for the whole decision. Every question below is asked of
|
|
798
991
|
// the same declarations, and rebuilding it per question would both cost
|
|
799
992
|
// more and let two answers disagree about what was declared.
|
|
@@ -802,11 +995,11 @@ class WatchTopology {
|
|
|
802
995
|
(previous.has(identities.resolve(changed).key) ||
|
|
803
996
|
matchesProjectInput(population, changed, identities));
|
|
804
997
|
const topologyMatched = changed !== undefined &&
|
|
805
|
-
projectInputTopologyMayAffect(population, changed, previous, identities);
|
|
998
|
+
(0, projectInputTopologyMayAffect_1.projectInputTopologyMayAffect)(population, changed, previous, identities);
|
|
806
999
|
if (changed !== undefined &&
|
|
807
1000
|
(this.isProjectInputCompilerOutput(changed, identities) ||
|
|
808
1001
|
(directlyMatched === false && topologyMatched === false))) {
|
|
809
|
-
return;
|
|
1002
|
+
return false;
|
|
810
1003
|
}
|
|
811
1004
|
// Rearm before snapshotting. A watcher that has to be replaced stops
|
|
812
1005
|
// delivering the moment it is closed, so a scan taken first would become
|
|
@@ -814,38 +1007,46 @@ class WatchTopology {
|
|
|
814
1007
|
// written there would never be announced again. Reinstalling first makes
|
|
815
1008
|
// the scan below observe whatever the gap swallowed.
|
|
816
1009
|
if (changed !== undefined &&
|
|
817
|
-
projectInputReplacementStrandsWatchers(population, changed, identities)) {
|
|
1010
|
+
(0, projectInputReplacementStrandsWatchers_1.projectInputReplacementStrandsWatchers)(population, changed, identities)) {
|
|
818
1011
|
this.retireProjectInputWatcher(location, identities);
|
|
819
1012
|
this.syncProjectInputWatchers();
|
|
820
1013
|
}
|
|
821
1014
|
const next = this.collectProjectInputMatches();
|
|
822
|
-
const membershipChanged = mapsEqual(previous, next) === false;
|
|
1015
|
+
const membershipChanged = WatchPaths_1.WatchPaths.mapsEqual(previous, next) === false;
|
|
823
1016
|
const nextFingerprints = changed === undefined ||
|
|
824
1017
|
membershipChanged ||
|
|
825
1018
|
directlyMatched ||
|
|
826
1019
|
topologyMatched
|
|
827
|
-
? fingerprintProjectInputMatches(next)
|
|
1020
|
+
? fingerprintProjectInputMatches(next, this.readDirectory)
|
|
828
1021
|
: this.projectInputFingerprints;
|
|
829
|
-
const contentChanged = mapsEqual(this.projectInputFingerprints, nextFingerprints) === false;
|
|
1022
|
+
const contentChanged = WatchPaths_1.WatchPaths.mapsEqual(this.projectInputFingerprints, nextFingerprints) === false;
|
|
830
1023
|
const changedInputs = projectInputChangedPaths({
|
|
831
1024
|
next,
|
|
832
1025
|
nextFingerprints,
|
|
833
1026
|
previous,
|
|
834
1027
|
previousFingerprints: this.projectInputFingerprints,
|
|
835
1028
|
});
|
|
836
|
-
const reconciledChange =
|
|
1029
|
+
const reconciledChange = reconcileProjectInputChange({
|
|
1030
|
+
changed,
|
|
1031
|
+
changedInputs,
|
|
1032
|
+
identities,
|
|
1033
|
+
next,
|
|
1034
|
+
previous,
|
|
1035
|
+
reloadDirectories: population.reloadDirectories ?? [],
|
|
1036
|
+
});
|
|
837
1037
|
// Both spellings classify the event. The normalized form names the file a
|
|
838
1038
|
// link pointed at when the snapshot was published, so after a retarget it
|
|
839
1039
|
// names the wrong one; only the declared form resolves to what the link
|
|
840
1040
|
// points at now, which is the selection this lane exists to protect.
|
|
841
|
-
const
|
|
1041
|
+
const reloadInput = {
|
|
842
1042
|
changed: reconciledChange,
|
|
843
1043
|
changedInputs,
|
|
844
1044
|
globs: population.globs,
|
|
845
1045
|
reloadDirectories: population.reloadDirectories ?? [],
|
|
846
1046
|
reloadFiles: population.reloadFiles ?? [],
|
|
847
|
-
}
|
|
848
|
-
const
|
|
1047
|
+
};
|
|
1048
|
+
const reload = (0, projectInputReloadEventShouldNotify_1.projectInputReloadEventShouldNotify)(reloadInput);
|
|
1049
|
+
const invalidate = (0, projectInputMembershipInvalidatesProgram_1.projectInputMembershipInvalidatesProgram)({
|
|
849
1050
|
changed: reconciledChange,
|
|
850
1051
|
changedInputs,
|
|
851
1052
|
contentChanged,
|
|
@@ -862,14 +1063,28 @@ class WatchTopology {
|
|
|
862
1063
|
if (invalidate) {
|
|
863
1064
|
this.refreshCompilerInputs(false, skipUnobservedProjectInputWatchRoots);
|
|
864
1065
|
}
|
|
865
|
-
|
|
1066
|
+
const notify = (0, projectInputEventShouldNotify_1.projectInputEventShouldNotify)({
|
|
866
1067
|
contentChanged,
|
|
867
1068
|
directlyMatched,
|
|
868
1069
|
membershipChanged,
|
|
869
1070
|
}) &&
|
|
870
1071
|
(reconciledChange === undefined ||
|
|
871
1072
|
this.isProjectInputCompilerOutput(reconciledChange, identities) ===
|
|
872
|
-
false)
|
|
1073
|
+
false);
|
|
1074
|
+
reportProjectInputDecision({
|
|
1075
|
+
source: "project-input",
|
|
1076
|
+
location,
|
|
1077
|
+
namedChange: changed ?? null,
|
|
1078
|
+
...reloadInput,
|
|
1079
|
+
directlyMatched,
|
|
1080
|
+
topologyMatched,
|
|
1081
|
+
membershipChanged,
|
|
1082
|
+
contentChanged,
|
|
1083
|
+
reload,
|
|
1084
|
+
invalidate,
|
|
1085
|
+
notify,
|
|
1086
|
+
});
|
|
1087
|
+
if (notify) {
|
|
873
1088
|
this.callbacks.onInputChange(reload
|
|
874
1089
|
? { kind: "config", path: reconciledChange }
|
|
875
1090
|
: {
|
|
@@ -878,6 +1093,7 @@ class WatchTopology {
|
|
|
878
1093
|
path: reconciledChange,
|
|
879
1094
|
});
|
|
880
1095
|
}
|
|
1096
|
+
return true;
|
|
881
1097
|
}
|
|
882
1098
|
catch (error) {
|
|
883
1099
|
// A rename can invalidate the old filesystem object before the
|
|
@@ -886,10 +1102,11 @@ class WatchTopology {
|
|
|
886
1102
|
// stranded without a watcher.
|
|
887
1103
|
this.syncProjectInputWatchers(skipUnobservedProjectInputWatchRoots);
|
|
888
1104
|
this.callbacks.onError(location, error);
|
|
1105
|
+
return false;
|
|
889
1106
|
}
|
|
890
1107
|
}
|
|
891
1108
|
collectProjectInputMatches() {
|
|
892
|
-
const identities = (0,
|
|
1109
|
+
const identities = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)();
|
|
893
1110
|
const matches = new Map();
|
|
894
1111
|
// Both spellings are scanned, and each is resolved here rather than when
|
|
895
1112
|
// the snapshot arrived. A declaration reached through a symlink otherwise
|
|
@@ -911,19 +1128,34 @@ class WatchTopology {
|
|
|
911
1128
|
}
|
|
912
1129
|
}
|
|
913
1130
|
for (const directory of this.projectInputDeclarations("reload-directory")) {
|
|
914
|
-
if (isDirectory(directory) &&
|
|
1131
|
+
if (WatchPaths_1.WatchPaths.isDirectory(directory) &&
|
|
915
1132
|
this.isProjectInputCompilerOutputDirectory(directory, identities) ===
|
|
916
1133
|
false) {
|
|
917
1134
|
const identity = identities.resolve(directory);
|
|
918
1135
|
matches.set(identity.key, identity.path);
|
|
919
1136
|
}
|
|
920
1137
|
}
|
|
1138
|
+
const globRoots = new Map();
|
|
921
1139
|
for (const glob of this.projectInputDeclarations("glob")) {
|
|
922
|
-
const root = literalGlobRoot(glob);
|
|
923
|
-
if (isDirectory(root) === false ||
|
|
1140
|
+
const root = (0, literalGlobRoot_1.literalGlobRoot)(glob);
|
|
1141
|
+
if (WatchPaths_1.WatchPaths.isDirectory(root) === false ||
|
|
924
1142
|
this.isProjectInputCompilerOutputDirectory(root, identities)) {
|
|
925
1143
|
continue;
|
|
926
1144
|
}
|
|
1145
|
+
const identity = identities.resolve(root);
|
|
1146
|
+
const group = globRoots.get(identity.key) ?? {
|
|
1147
|
+
root: identity.path,
|
|
1148
|
+
patterns: [],
|
|
1149
|
+
};
|
|
1150
|
+
group.patterns.push(glob);
|
|
1151
|
+
globRoots.set(identity.key, group);
|
|
1152
|
+
}
|
|
1153
|
+
// One native walk serves all patterns below a physical ancestor. Per-file
|
|
1154
|
+
// matching still uses every declaration's own root and wildcard semantics.
|
|
1155
|
+
for (const root of (0, projectInputActiveWatchDirectories_1.projectInputActiveWatchDirectories)([...globRoots.values()].map((group) => group.root), identities)) {
|
|
1156
|
+
const patterns = [...globRoots.values()]
|
|
1157
|
+
.filter((group) => identities.isWithin(root, group.root))
|
|
1158
|
+
.flatMap((group) => group.patterns);
|
|
927
1159
|
const stack = [root];
|
|
928
1160
|
while (stack.length !== 0) {
|
|
929
1161
|
const current = stack.pop();
|
|
@@ -945,7 +1177,7 @@ class WatchTopology {
|
|
|
945
1177
|
stack.push(location);
|
|
946
1178
|
}
|
|
947
1179
|
else if (entry.isFile() &&
|
|
948
|
-
matchesProjectInputGlob(glob, location, identities)) {
|
|
1180
|
+
patterns.some((glob) => matchesProjectInputGlob(glob, location, identities))) {
|
|
949
1181
|
const identity = identities.resolve(location);
|
|
950
1182
|
matches.set(identity.key, identity.path);
|
|
951
1183
|
}
|
|
@@ -956,26 +1188,26 @@ class WatchTopology {
|
|
|
956
1188
|
}
|
|
957
1189
|
refreshFromDirectory(location, changed) {
|
|
958
1190
|
if (changed !== undefined &&
|
|
959
|
-
isDirectory(changed) &&
|
|
1191
|
+
WatchPaths_1.WatchPaths.isDirectory(changed) &&
|
|
960
1192
|
this.isCompilerOutputDirectory(changed) === false &&
|
|
961
1193
|
this.isProjectInputDirectory(changed) === false) {
|
|
962
|
-
this.observedDirectories.set(pathKey(changed), changed);
|
|
1194
|
+
this.observedDirectories.set(this.pathKey(changed), changed);
|
|
963
1195
|
}
|
|
964
1196
|
try {
|
|
965
1197
|
this.refresh(true);
|
|
966
1198
|
}
|
|
967
1199
|
catch (error) {
|
|
968
|
-
for (const reload of reloadInputsForFailedTopologyRefresh(this.reloadFiles.values(), changed)) {
|
|
1200
|
+
for (const reload of (0, reloadInputsForFailedTopologyRefresh_1.reloadInputsForFailedTopologyRefresh)(this.reloadFiles.values(), changed, this.lexicalIdentities)) {
|
|
969
1201
|
this.callbacks.onInputChange({ kind: "config", path: reload });
|
|
970
1202
|
}
|
|
971
1203
|
this.callbacks.onError(location, error);
|
|
972
1204
|
}
|
|
973
1205
|
}
|
|
974
1206
|
isCompilerOutputDirectory(location) {
|
|
975
|
-
return [...this.outputs.values()].some((output) => isPathWithin(output, location));
|
|
1207
|
+
return [...this.outputs.values()].some((output) => WatchPaths_1.WatchPaths.isPathWithin(output, location, this.lexicalIdentities));
|
|
976
1208
|
}
|
|
977
1209
|
isCompilerOutput(location) {
|
|
978
|
-
return (this.outputFiles.has(pathKey(location)) ||
|
|
1210
|
+
return (this.outputFiles.has(this.pathKey(location)) ||
|
|
979
1211
|
this.isCompilerOutputDirectory(location));
|
|
980
1212
|
}
|
|
981
1213
|
isProjectInputCompilerOutputDirectory(location, identities) {
|
|
@@ -1013,7 +1245,7 @@ class WatchTopology {
|
|
|
1013
1245
|
}
|
|
1014
1246
|
isProjectInputDirectory(location) {
|
|
1015
1247
|
const resolved = node_path_1.default.resolve(location);
|
|
1016
|
-
const identities = (0,
|
|
1248
|
+
const identities = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)();
|
|
1017
1249
|
return (this.projectInputs.files.some((file) => identities.isWithin(resolved, file) ||
|
|
1018
1250
|
identities.isWithin(node_path_1.default.dirname(file), resolved)) ||
|
|
1019
1251
|
(this.projectInputs.reloadFiles ?? []).some((file) => identities.isWithin(resolved, file) ||
|
|
@@ -1021,7 +1253,7 @@ class WatchTopology {
|
|
|
1021
1253
|
(this.projectInputs.reloadDirectories ?? []).some((directory) => identities.isWithin(resolved, directory) ||
|
|
1022
1254
|
identities.isWithin(directory, resolved)) ||
|
|
1023
1255
|
this.projectInputs.globs.some((glob) => {
|
|
1024
|
-
const root = literalGlobRoot(glob);
|
|
1256
|
+
const root = (0, literalGlobRoot_1.literalGlobRoot)(glob);
|
|
1025
1257
|
return (identities.isWithin(root, resolved) ||
|
|
1026
1258
|
identities.isWithin(resolved, root));
|
|
1027
1259
|
}));
|
|
@@ -1029,28 +1261,112 @@ class WatchTopology {
|
|
|
1029
1261
|
classifyCompilerInput(location) {
|
|
1030
1262
|
if (this.isPluginInput(location))
|
|
1031
1263
|
return "plugin";
|
|
1032
|
-
return this.reloadFiles.has(pathKey(location)) ? "config" : "compiler";
|
|
1264
|
+
return this.reloadFiles.has(this.pathKey(location)) ? "config" : "compiler";
|
|
1033
1265
|
}
|
|
1034
|
-
|
|
1266
|
+
/**
|
|
1267
|
+
* Note a notification at `location` against the plugin inputs it may have
|
|
1268
|
+
* moved, to be decided once the delivery it came in has reached every
|
|
1269
|
+
* listener (`decidePluginNotifications`).
|
|
1270
|
+
*
|
|
1271
|
+
* A watcher reports more than an edit. Windows reports a directory's entry as
|
|
1272
|
+
* changed when only its metadata moved, such as its access time after a build
|
|
1273
|
+
* enumerated it, and a notification taken at its word restarted the resident
|
|
1274
|
+
* check host for a plugin whose sources nobody edited. An input is decided by
|
|
1275
|
+
* what its build reads, which is every one of its source files, so the
|
|
1276
|
+
* notifications of one delivery are decided together: an install or a
|
|
1277
|
+
* checkout brings hundreds, and each input they name is read once. A location
|
|
1278
|
+
* no input covers, such as a directory above one, names every input.
|
|
1279
|
+
*/
|
|
1280
|
+
notePluginNotification(location) {
|
|
1035
1281
|
const resolved = node_path_1.default.resolve(location);
|
|
1036
|
-
|
|
1282
|
+
const covering = this.extraInputs.filter((input) => (0, pluginSourceCovers_1.pluginSourceCovers)(input, resolved, "entry"));
|
|
1283
|
+
for (const input of covering.length === 0 ? this.extraInputs : covering) {
|
|
1284
|
+
const key = this.pathKey(input);
|
|
1285
|
+
const locations = this.pendingPluginNotifications.get(key) ?? new Set();
|
|
1286
|
+
locations.add(location);
|
|
1287
|
+
this.pendingPluginNotifications.set(key, locations);
|
|
1288
|
+
}
|
|
1289
|
+
if (this.pluginNotificationsScheduled)
|
|
1290
|
+
return;
|
|
1291
|
+
this.pluginNotificationsScheduled = true;
|
|
1292
|
+
// A watcher backend hands one delivery to its listeners within one turn
|
|
1293
|
+
// of the event loop, so the check phase after that turn holds all of it.
|
|
1294
|
+
setImmediate(() => this.decidePluginNotifications());
|
|
1037
1295
|
}
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1296
|
+
/**
|
|
1297
|
+
* Report every location noted for a plugin input whose state moved, once
|
|
1298
|
+
* each, and record the state it moved to. A notification that moved no input
|
|
1299
|
+
* is dropped.
|
|
1300
|
+
*
|
|
1301
|
+
* Whether a build must rerun and what must be watched are separate questions.
|
|
1302
|
+
* A delivery can name a directory created below an input: while it is empty
|
|
1303
|
+
* it moves nothing a build reads, yet it needs a watcher of its own before a
|
|
1304
|
+
* file lands in it, or on a platform whose watcher reports a directory's
|
|
1305
|
+
* direct entries alone that file reaches no watcher. So the watchers are
|
|
1306
|
+
* synced first, and what a directory they start watching already holds is
|
|
1307
|
+
* noted into this same decision (`syncExtraWatchers`).
|
|
1308
|
+
*/
|
|
1309
|
+
decidePluginNotifications() {
|
|
1310
|
+
if (this.closed) {
|
|
1311
|
+
this.pendingPluginNotifications = new Map();
|
|
1312
|
+
this.pluginNotificationsScheduled = false;
|
|
1313
|
+
return;
|
|
1314
|
+
}
|
|
1315
|
+
this.beginLexicalTransaction();
|
|
1316
|
+
// Still scheduled while syncing, so what the sync notes joins this decision
|
|
1317
|
+
// instead of scheduling another.
|
|
1318
|
+
this.syncExtraWatchers();
|
|
1319
|
+
this.pluginNotificationsScheduled = false;
|
|
1320
|
+
const pending = this.pendingPluginNotifications;
|
|
1321
|
+
this.pendingPluginNotifications = new Map();
|
|
1322
|
+
const reported = new Set();
|
|
1323
|
+
for (const input of this.extraInputs) {
|
|
1324
|
+
const key = this.pathKey(input);
|
|
1325
|
+
const locations = pending.get(key);
|
|
1326
|
+
if (locations === undefined)
|
|
1327
|
+
continue;
|
|
1328
|
+
const state = pluginInputState(input);
|
|
1329
|
+
if (this.pluginInputStates.get(key) === state)
|
|
1330
|
+
continue;
|
|
1331
|
+
this.pluginInputStates.set(key, state);
|
|
1332
|
+
for (const location of locations) {
|
|
1333
|
+
if (reported.has(location))
|
|
1334
|
+
continue;
|
|
1335
|
+
reported.add(location);
|
|
1336
|
+
this.callbacks.onInputChange({ kind: "plugin", path: location });
|
|
1337
|
+
}
|
|
1338
|
+
}
|
|
1339
|
+
}
|
|
1340
|
+
/**
|
|
1341
|
+
* Whether a path is one a plugin build keys on: the plugin input itself, or a
|
|
1342
|
+
* path below it outside every directory the build passes over
|
|
1343
|
+
* (`pluginSourceCovers`). A write in a plugin module's `node_modules` or
|
|
1344
|
+
* `.git` is not one, whatever watcher heard it.
|
|
1345
|
+
*
|
|
1346
|
+
* Nor is such a directory's own entry. Windows reports every write inside a
|
|
1347
|
+
* directory as a change of that directory's entry to a watch on its parent,
|
|
1348
|
+
* and nothing of a directory the build passes over, or below it, is a source.
|
|
1349
|
+
* An entry of the same name that is a file is one the build reads.
|
|
1350
|
+
*/
|
|
1351
|
+
isPluginInput(location) {
|
|
1044
1352
|
const resolved = node_path_1.default.resolve(location);
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
reloads.set(key, resolved);
|
|
1353
|
+
if ((0, prunesPluginSourceDirectory_1.prunesPluginSourceDirectory)(node_path_1.default.basename(resolved)) &&
|
|
1354
|
+
WatchPaths_1.WatchPaths.isDirectory(resolved)) {
|
|
1355
|
+
return false;
|
|
1049
1356
|
}
|
|
1357
|
+
return this.extraInputs.some((input) => (0, pluginSourceCovers_1.pluginSourceCovers)(input, resolved, "entry"));
|
|
1050
1358
|
}
|
|
1051
|
-
return [...reloads.values()].sort();
|
|
1052
1359
|
}
|
|
1053
|
-
|
|
1360
|
+
exports.WatchTopology = WatchTopology;
|
|
1361
|
+
function resolveWatchTopology(options, extraInputs, identities, getCompilerInputs) {
|
|
1362
|
+
const selection = CompilerProjectSelection_1.CompilerProjectSelection.read(options);
|
|
1363
|
+
if (selection.inspectionError !== undefined)
|
|
1364
|
+
throw selection.inspectionError;
|
|
1365
|
+
options = {
|
|
1366
|
+
...options,
|
|
1367
|
+
compilerArgsCwd: selection.compilerArgsCwd,
|
|
1368
|
+
pinCompilerProject: selection.projectGuard.length !== 0,
|
|
1369
|
+
};
|
|
1054
1370
|
let analysisOnly = options.emit === false;
|
|
1055
1371
|
const files = new Map();
|
|
1056
1372
|
const outputFiles = new Map();
|
|
@@ -1058,78 +1374,89 @@ function resolveWatchTopology(options, extraInputs) {
|
|
|
1058
1374
|
const reloadFiles = new Map();
|
|
1059
1375
|
const roots = [];
|
|
1060
1376
|
if (options.files.length !== 0) {
|
|
1061
|
-
const project =
|
|
1062
|
-
|
|
1063
|
-
projectRoot: options.projectRoot,
|
|
1064
|
-
tsconfig: options.tsconfig,
|
|
1065
|
-
});
|
|
1377
|
+
const project = selection.project;
|
|
1378
|
+
const inspected = watchCompilerOptions(selection, options);
|
|
1066
1379
|
analysisOnly = watchTopologyAnalysisOnly(options, project);
|
|
1380
|
+
addPaths(files, inspected.responseFiles, identities);
|
|
1381
|
+
addPaths(reloadFiles, inspected.responseFiles, identities);
|
|
1067
1382
|
roots.push(project.root);
|
|
1068
|
-
addPaths(files, project.configPaths);
|
|
1069
|
-
addPaths(reloadFiles, project.configPaths);
|
|
1383
|
+
addPaths(files, project.configPaths, identities);
|
|
1384
|
+
addPaths(reloadFiles, project.configPaths, identities);
|
|
1070
1385
|
const positionalInputs = options.files.map((file) => node_path_1.default.resolve(options.cwd, file));
|
|
1071
1386
|
if (positionalInputs.length === 1 &&
|
|
1072
1387
|
(options.emit ?? project.compilerOptions.noEmit !== true)) {
|
|
1073
1388
|
addPaths(outputFiles, [
|
|
1074
|
-
(0,
|
|
1389
|
+
(0, resolveSingleFileOutput_1.resolveSingleFileOutput)({
|
|
1075
1390
|
cliOutDir: options.outDir,
|
|
1076
1391
|
cwd: options.cwd,
|
|
1077
1392
|
file: positionalInputs[0],
|
|
1078
1393
|
passthrough: options.passthrough,
|
|
1079
1394
|
tsconfig: options.tsconfig,
|
|
1080
|
-
}),
|
|
1081
|
-
]);
|
|
1395
|
+
}, project),
|
|
1396
|
+
], identities);
|
|
1082
1397
|
}
|
|
1083
|
-
addPaths(files, positionalInputs);
|
|
1398
|
+
addPaths(files, positionalInputs, identities);
|
|
1084
1399
|
}
|
|
1085
1400
|
else {
|
|
1086
|
-
const projects = readReferencedProjects(
|
|
1087
|
-
if (projects[0] !== undefined) {
|
|
1088
|
-
analysisOnly = watchTopologyAnalysisOnly(options, projects[0]);
|
|
1089
|
-
}
|
|
1401
|
+
const projects = readReferencedProjects(selection.project, identities);
|
|
1090
1402
|
for (const project of projects) {
|
|
1403
|
+
const inspected = watchCompilerOptions(selection, options);
|
|
1404
|
+
if (project === projects[0]) {
|
|
1405
|
+
analysisOnly = watchTopologyAnalysisOnly(inspected.options, project);
|
|
1406
|
+
}
|
|
1091
1407
|
roots.push(project.root);
|
|
1092
|
-
addPaths(files, project.configPaths);
|
|
1093
|
-
addPaths(reloadFiles, project.configPaths);
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
addPaths(files,
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1408
|
+
addPaths(files, project.configPaths, identities);
|
|
1409
|
+
addPaths(reloadFiles, project.configPaths, identities);
|
|
1410
|
+
addPaths(files, inspected.responseFiles, identities);
|
|
1411
|
+
addPaths(reloadFiles, inspected.responseFiles, identities);
|
|
1412
|
+
const compilerInputs = getCompilerInputs(project, options);
|
|
1413
|
+
CompilerProjectSelection_1.CompilerProjectSelection.assertCurrent(selection);
|
|
1414
|
+
const compilerOutputs = resolveCompilerOutputs(project, inspected.options);
|
|
1415
|
+
addPaths(outputFiles, compilerOutputs.files, identities);
|
|
1416
|
+
addPaths(outputFiles, inferPerSourceCompilerOutputs(project, inspected.options, compilerInputs, identities), identities);
|
|
1417
|
+
addPaths(outputs, compilerOutputs.directories, identities);
|
|
1418
|
+
addPaths(files, compilerInputs, identities);
|
|
1419
|
+
}
|
|
1420
|
+
}
|
|
1421
|
+
CompilerProjectSelection_1.CompilerProjectSelection.assertCurrent(selection);
|
|
1422
|
+
addPaths(files, extraInputs, identities);
|
|
1103
1423
|
return {
|
|
1104
1424
|
analysisOnly,
|
|
1105
|
-
directories: collectTopologyDirectories(files.values(), roots),
|
|
1425
|
+
directories: collectTopologyDirectories(files.values(), roots, identities),
|
|
1106
1426
|
files,
|
|
1107
1427
|
outputFiles,
|
|
1108
1428
|
outputs,
|
|
1109
1429
|
reloadFiles,
|
|
1110
1430
|
};
|
|
1111
1431
|
}
|
|
1432
|
+
/**
|
|
1433
|
+
* Share the root selection's observed options across its referenced projects.
|
|
1434
|
+
* The original request still reaches the compiler-input operation. Positional
|
|
1435
|
+
* output placement remains the single-file launcher's own copy policy.
|
|
1436
|
+
*/
|
|
1437
|
+
function watchCompilerOptions(selection, options) {
|
|
1438
|
+
return {
|
|
1439
|
+
options: { ...options, passthrough: selection.inspectedArgs },
|
|
1440
|
+
responseFiles: [...selection.observations.keys()],
|
|
1441
|
+
};
|
|
1442
|
+
}
|
|
1112
1443
|
function watchTopologyAnalysisOnly(options, project) {
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1444
|
+
const noEmit = passthroughBooleanOption((0, readCompilerOptionValues_1.readCompilerOptionValues)(options.passthrough).values, "--noEmit") ??
|
|
1445
|
+
(options.emit === undefined
|
|
1446
|
+
? project.compilerOptions.noEmit === true
|
|
1447
|
+
: options.emit === false);
|
|
1117
1448
|
return noEmit;
|
|
1118
1449
|
}
|
|
1119
|
-
function readReferencedProjects(
|
|
1120
|
-
const root = (0, readProjectConfig_1.readProjectConfig)({
|
|
1121
|
-
cwd: options.cwd,
|
|
1122
|
-
projectRoot: options.projectRoot,
|
|
1123
|
-
tsconfig: options.tsconfig,
|
|
1124
|
-
});
|
|
1450
|
+
function readReferencedProjects(root, identities) {
|
|
1125
1451
|
const projects = [];
|
|
1126
1452
|
const queue = [root];
|
|
1127
1453
|
const seen = new Set();
|
|
1128
|
-
|
|
1129
|
-
const project = queue
|
|
1130
|
-
|
|
1454
|
+
for (let cursor = 0; cursor < queue.length; cursor++) {
|
|
1455
|
+
const project = queue[cursor];
|
|
1456
|
+
const key = WatchPaths_1.WatchPaths.pathKey(project.path, identities);
|
|
1457
|
+
if (seen.has(key))
|
|
1131
1458
|
continue;
|
|
1132
|
-
seen.add(
|
|
1459
|
+
seen.add(key);
|
|
1133
1460
|
projects.push(project);
|
|
1134
1461
|
for (const reference of readProjectReferences(project.path)) {
|
|
1135
1462
|
queue.push((0, readProjectConfig_1.readProjectConfig)({
|
|
@@ -1141,7 +1468,7 @@ function readReferencedProjects(options) {
|
|
|
1141
1468
|
return projects;
|
|
1142
1469
|
}
|
|
1143
1470
|
function readProjectReferences(tsconfig) {
|
|
1144
|
-
const parsed = (0,
|
|
1471
|
+
const parsed = (0, readJsoncFile_1.readJsoncFile)(tsconfig);
|
|
1145
1472
|
if (isRecord(parsed) === false ||
|
|
1146
1473
|
Array.isArray(parsed.references) === false) {
|
|
1147
1474
|
return [];
|
|
@@ -1171,8 +1498,9 @@ function listCompilerInputs(project, options) {
|
|
|
1171
1498
|
"--pretty",
|
|
1172
1499
|
"false",
|
|
1173
1500
|
...(options.passthrough ?? []),
|
|
1501
|
+
...(options.pinCompilerProject === true ? ["-p", project.path] : []),
|
|
1174
1502
|
], {
|
|
1175
|
-
cwd: project.root,
|
|
1503
|
+
cwd: options.compilerArgsCwd ?? project.root,
|
|
1176
1504
|
env: { ...process.env, ...options.env },
|
|
1177
1505
|
encoding: "utf8",
|
|
1178
1506
|
});
|
|
@@ -1184,13 +1512,13 @@ function listCompilerInputs(project, options) {
|
|
|
1184
1512
|
// its Program membership—especially while the compiler is reporting an
|
|
1185
1513
|
// overwrite diagnostic. Product inference is used only to classify future
|
|
1186
1514
|
// filesystem events, never to subtract from the compiler's answer.
|
|
1187
|
-
const inputs = (0,
|
|
1515
|
+
const inputs = (0, outputText_1.outputText)(result.stdout)
|
|
1188
1516
|
.split(/\r?\n/)
|
|
1189
1517
|
.map((line) => line.trim())
|
|
1190
1518
|
.filter((line) => node_path_1.default.isAbsolute(line))
|
|
1191
1519
|
.map((line) => node_path_1.default.resolve(line));
|
|
1192
1520
|
if (result.status !== 0 && inputs.length === 0) {
|
|
1193
|
-
throw new Error(`ttsc: failed to list compiler inputs:\n${(0,
|
|
1521
|
+
throw new Error(`ttsc: failed to list compiler inputs:\n${(0, outputText_1.outputText)(result.stderr) || (0, outputText_1.outputText)(result.stdout)}`);
|
|
1194
1522
|
}
|
|
1195
1523
|
return inputs;
|
|
1196
1524
|
}
|
|
@@ -1213,7 +1541,7 @@ function resolveCompilerOutputs(project, options) {
|
|
|
1213
1541
|
files: [...files],
|
|
1214
1542
|
};
|
|
1215
1543
|
}
|
|
1216
|
-
function inferPerSourceCompilerOutputs(project, options, inputs) {
|
|
1544
|
+
function inferPerSourceCompilerOutputs(project, options, inputs, identities) {
|
|
1217
1545
|
const emit = effectiveCompilerEmit(project, options);
|
|
1218
1546
|
const outputs = new Set();
|
|
1219
1547
|
// TypeScript-Go 7 requires an explicit rootDir when output layout would
|
|
@@ -1229,7 +1557,7 @@ function inferPerSourceCompilerOutputs(project, options, inputs) {
|
|
|
1229
1557
|
const mappedStem = (directory, adjacentWhenOutside) => {
|
|
1230
1558
|
if (directory === undefined)
|
|
1231
1559
|
return stem;
|
|
1232
|
-
if (!isPathWithin(sourceRoot, input)) {
|
|
1560
|
+
if (!WatchPaths_1.WatchPaths.isPathWithin(sourceRoot, input, identities)) {
|
|
1233
1561
|
return adjacentWhenOutside ? stem : undefined;
|
|
1234
1562
|
}
|
|
1235
1563
|
return node_path_1.default.resolve(directory, node_path_1.default.relative(sourceRoot, stem));
|
|
@@ -1244,7 +1572,7 @@ function inferPerSourceCompilerOutputs(project, options, inputs) {
|
|
|
1244
1572
|
}
|
|
1245
1573
|
continue;
|
|
1246
1574
|
}
|
|
1247
|
-
if (!isCompilerEmittableSourceExtension(extension))
|
|
1575
|
+
if (!ProjectInputWatchRules_1.ProjectInputWatchRules.isCompilerEmittableSourceExtension(extension))
|
|
1248
1576
|
continue;
|
|
1249
1577
|
if (emit.javascript &&
|
|
1250
1578
|
(emit.outDir !== undefined ||
|
|
@@ -1283,24 +1611,12 @@ function inferPerSourceCompilerOutputs(project, options, inputs) {
|
|
|
1283
1611
|
}
|
|
1284
1612
|
return [...outputs];
|
|
1285
1613
|
}
|
|
1286
|
-
function isCompilerEmittableSourceExtension(extension) {
|
|
1287
|
-
return [
|
|
1288
|
-
".cjs",
|
|
1289
|
-
".cts",
|
|
1290
|
-
".js",
|
|
1291
|
-
".jsx",
|
|
1292
|
-
".mjs",
|
|
1293
|
-
".mts",
|
|
1294
|
-
".ts",
|
|
1295
|
-
".tsx",
|
|
1296
|
-
].includes(extension);
|
|
1297
|
-
}
|
|
1298
1614
|
function isJavaScriptSourceExtension(extension) {
|
|
1299
1615
|
return [".cjs", ".js", ".jsx", ".mjs"].includes(extension);
|
|
1300
1616
|
}
|
|
1301
1617
|
function effectiveCompilerEmit(project, options) {
|
|
1302
1618
|
const compilerOptions = project.compilerOptions;
|
|
1303
|
-
const passthrough = options.passthrough;
|
|
1619
|
+
const passthrough = (0, readCompilerOptionValues_1.readCompilerOptionValues)(options.passthrough).values;
|
|
1304
1620
|
const noEmit = passthroughBooleanOption(passthrough, "--noEmit") ??
|
|
1305
1621
|
(options.emit === false
|
|
1306
1622
|
? true
|
|
@@ -1333,8 +1649,15 @@ function effectiveCompilerEmit(project, options) {
|
|
|
1333
1649
|
const cliDeclarationDir = passthroughPathOption(passthrough, "--declarationDir");
|
|
1334
1650
|
const cliRootDir = passthroughPathOption(passthrough, "--rootDir");
|
|
1335
1651
|
const cliTsBuildInfoFile = passthroughPathOption(passthrough, "--tsBuildInfoFile");
|
|
1336
|
-
|
|
1337
|
-
|
|
1652
|
+
// Presence carries explicit null/empty enum resets. A configured JSX string
|
|
1653
|
+
// follows JSON's lowercase-only contract, never the CLI whitespace trim.
|
|
1654
|
+
const rawJsx = passthrough.has("jsx")
|
|
1655
|
+
? passthrough.get("jsx")
|
|
1656
|
+
: typeof compilerOptions.jsx === "string"
|
|
1657
|
+
? (0, normalizeCompilerEnumValue_1.normalizeCompilerEnumValue)(compilerOptions.jsx, "json")
|
|
1658
|
+
: undefined;
|
|
1659
|
+
const jsx = typeof rawJsx === "string" ? rawJsx : undefined;
|
|
1660
|
+
const compilerCwd = options.compilerArgsCwd ?? project.root;
|
|
1338
1661
|
return {
|
|
1339
1662
|
declaration,
|
|
1340
1663
|
declarationDir: cliDeclarationDir === null
|
|
@@ -1393,66 +1716,35 @@ function replaceOutputExtension(location, extension) {
|
|
|
1393
1716
|
? `${location}${extension}`
|
|
1394
1717
|
: `${location.slice(0, -current.length)}${extension}`;
|
|
1395
1718
|
}
|
|
1396
|
-
function passthroughBooleanOption(
|
|
1397
|
-
|
|
1398
|
-
|
|
1399
|
-
|
|
1400
|
-
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
continue;
|
|
1404
|
-
const next = tokens?.[index + 1];
|
|
1405
|
-
if (next === "true" || next === "false" || next === "null") {
|
|
1406
|
-
value = next === "true";
|
|
1407
|
-
index++;
|
|
1408
|
-
}
|
|
1409
|
-
else {
|
|
1410
|
-
value = true;
|
|
1411
|
-
}
|
|
1412
|
-
}
|
|
1413
|
-
return value;
|
|
1414
|
-
}
|
|
1415
|
-
function passthroughPathOption(tokens, name) {
|
|
1416
|
-
let value;
|
|
1417
|
-
for (let index = 0; index < (tokens?.length ?? 0); index++) {
|
|
1418
|
-
const token = tokens?.[index];
|
|
1419
|
-
if (token === undefined)
|
|
1420
|
-
continue;
|
|
1421
|
-
if (!passthroughOptionMatches(token, name))
|
|
1422
|
-
continue;
|
|
1423
|
-
if (index + 1 < (tokens?.length ?? 0)) {
|
|
1424
|
-
const next = tokens?.[++index];
|
|
1425
|
-
value = next === "null" ? null : next;
|
|
1426
|
-
}
|
|
1427
|
-
}
|
|
1428
|
-
return value;
|
|
1429
|
-
}
|
|
1430
|
-
function passthroughStringOption(tokens, name) {
|
|
1431
|
-
return passthroughPathOption(tokens, name)?.toLowerCase() ?? undefined;
|
|
1719
|
+
function passthroughBooleanOption(values, name) {
|
|
1720
|
+
const value = values.get(name.slice(2));
|
|
1721
|
+
return typeof value === "boolean"
|
|
1722
|
+
? value
|
|
1723
|
+
: value === null
|
|
1724
|
+
? false
|
|
1725
|
+
: undefined;
|
|
1432
1726
|
}
|
|
1433
|
-
function
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
if (token.includes("="))
|
|
1437
|
-
return false;
|
|
1438
|
-
return (0, schema_1.resolveFlagSpec)(token)?.name === (0, schema_1.resolveFlagSpec)(name)?.name;
|
|
1727
|
+
function passthroughPathOption(values, name) {
|
|
1728
|
+
const value = values.get(name.slice(2));
|
|
1729
|
+
return typeof value === "string" || value === null ? value : undefined;
|
|
1439
1730
|
}
|
|
1440
|
-
function collectTopologyDirectories(files, roots) {
|
|
1731
|
+
function collectTopologyDirectories(files, roots, identities) {
|
|
1441
1732
|
const directories = new Map();
|
|
1442
1733
|
for (const root of roots) {
|
|
1443
|
-
directories.set(pathKey(root), root);
|
|
1734
|
+
directories.set(WatchPaths_1.WatchPaths.pathKey(root, identities), root);
|
|
1444
1735
|
}
|
|
1445
1736
|
for (const file of files) {
|
|
1446
1737
|
const directory = node_path_1.default.dirname(file);
|
|
1447
|
-
const root = roots.find((candidate) => isPathWithin(candidate, directory));
|
|
1738
|
+
const root = roots.find((candidate) => WatchPaths_1.WatchPaths.isPathWithin(candidate, directory, identities));
|
|
1448
1739
|
if (root === undefined) {
|
|
1449
|
-
directories.set(pathKey(directory), directory);
|
|
1740
|
+
directories.set(WatchPaths_1.WatchPaths.pathKey(directory, identities), directory);
|
|
1450
1741
|
continue;
|
|
1451
1742
|
}
|
|
1452
1743
|
let current = directory;
|
|
1453
1744
|
while (true) {
|
|
1454
|
-
directories.set(pathKey(current), current);
|
|
1455
|
-
if (pathKey(current) ===
|
|
1745
|
+
directories.set(WatchPaths_1.WatchPaths.pathKey(current, identities), current);
|
|
1746
|
+
if (WatchPaths_1.WatchPaths.pathKey(current, identities) ===
|
|
1747
|
+
WatchPaths_1.WatchPaths.pathKey(root, identities))
|
|
1456
1748
|
break;
|
|
1457
1749
|
const parent = node_path_1.default.dirname(current);
|
|
1458
1750
|
if (parent === current)
|
|
@@ -1462,102 +1754,45 @@ function collectTopologyDirectories(files, roots) {
|
|
|
1462
1754
|
}
|
|
1463
1755
|
return directories;
|
|
1464
1756
|
}
|
|
1757
|
+
/**
|
|
1758
|
+
* Every directory of a plugin input a watch observes: the input and the
|
|
1759
|
+
* directories below it, except those the plugin build passes over and all below
|
|
1760
|
+
* them (`prunesPluginSourceDirectory`). The input is a plugin's whole Go
|
|
1761
|
+
* module, which can be a repository with its own `node_modules` and `.git`;
|
|
1762
|
+
* watching those would rebuild for every package install and commit without the
|
|
1763
|
+
* build reading any of it.
|
|
1764
|
+
*/
|
|
1465
1765
|
function collectInputDirectories(input) {
|
|
1466
|
-
|
|
1467
|
-
return [];
|
|
1468
|
-
const directories = [];
|
|
1469
|
-
const stack = [input];
|
|
1470
|
-
while (stack.length !== 0) {
|
|
1471
|
-
const current = stack.pop();
|
|
1472
|
-
directories.push(current);
|
|
1473
|
-
let entries;
|
|
1474
|
-
try {
|
|
1475
|
-
entries = node_fs_1.default.readdirSync(current, { withFileTypes: true });
|
|
1476
|
-
}
|
|
1477
|
-
catch (error) {
|
|
1478
|
-
if (isVanishedFilesystemEntry(error))
|
|
1479
|
-
continue;
|
|
1480
|
-
throw error;
|
|
1481
|
-
}
|
|
1482
|
-
for (const entry of entries) {
|
|
1483
|
-
if (entry.isDirectory()) {
|
|
1484
|
-
stack.push(node_path_1.default.join(current, entry.name));
|
|
1485
|
-
}
|
|
1486
|
-
}
|
|
1487
|
-
}
|
|
1488
|
-
return directories;
|
|
1766
|
+
return (0, collectPluginSourceDirectories_1.collectPluginSourceDirectories)(input);
|
|
1489
1767
|
}
|
|
1490
1768
|
function isVanishedFilesystemEntry(error) {
|
|
1491
1769
|
return (error instanceof Error &&
|
|
1492
1770
|
"code" in error &&
|
|
1493
1771
|
(error.code === "ENOENT" || error.code === "ENOTDIR"));
|
|
1494
1772
|
}
|
|
1495
|
-
function isDirectory(location) {
|
|
1496
|
-
try {
|
|
1497
|
-
return node_fs_1.default.statSync(location).isDirectory();
|
|
1498
|
-
}
|
|
1499
|
-
catch {
|
|
1500
|
-
return false;
|
|
1501
|
-
}
|
|
1502
|
-
}
|
|
1503
|
-
function syncWatchers(watchers, desired, create, onError, shouldContinue = () => true) {
|
|
1504
|
-
let complete = true;
|
|
1505
|
-
for (const [key, location] of desired) {
|
|
1506
|
-
if (!shouldContinue()) {
|
|
1507
|
-
complete = false;
|
|
1508
|
-
break;
|
|
1509
|
-
}
|
|
1510
|
-
if (watchers.has(key))
|
|
1511
|
-
continue;
|
|
1512
|
-
try {
|
|
1513
|
-
const watcher = create(location, key);
|
|
1514
|
-
watcher.on("error", (error) => {
|
|
1515
|
-
if (watchers.get(key) === watcher) {
|
|
1516
|
-
watchers.delete(key);
|
|
1517
|
-
}
|
|
1518
|
-
watcher.close();
|
|
1519
|
-
onError(location, error);
|
|
1520
|
-
});
|
|
1521
|
-
watchers.set(key, watcher);
|
|
1522
|
-
}
|
|
1523
|
-
catch (error) {
|
|
1524
|
-
complete = false;
|
|
1525
|
-
onError(location, error);
|
|
1526
|
-
}
|
|
1527
|
-
}
|
|
1528
|
-
if (!complete)
|
|
1529
|
-
return false;
|
|
1530
|
-
for (const [key, watcher] of watchers) {
|
|
1531
|
-
if (desired.has(key))
|
|
1532
|
-
continue;
|
|
1533
|
-
watcher.close();
|
|
1534
|
-
watchers.delete(key);
|
|
1535
|
-
}
|
|
1536
|
-
return true;
|
|
1537
|
-
}
|
|
1538
1773
|
function closeWatchers(watchers) {
|
|
1539
1774
|
for (const watcher of watchers.values())
|
|
1540
1775
|
watcher.close();
|
|
1541
1776
|
watchers.clear();
|
|
1542
1777
|
}
|
|
1543
|
-
function addPaths(target, paths) {
|
|
1778
|
+
function addPaths(target, paths, identities) {
|
|
1544
1779
|
for (const location of paths) {
|
|
1545
1780
|
const resolved = node_path_1.default.resolve(location);
|
|
1546
|
-
target.set(pathKey(resolved), resolved);
|
|
1781
|
+
target.set(WatchPaths_1.WatchPaths.pathKey(resolved, identities), resolved);
|
|
1547
1782
|
}
|
|
1548
1783
|
}
|
|
1549
|
-
function uniqueExistingPaths(paths) {
|
|
1784
|
+
function uniqueExistingPaths(paths, identities) {
|
|
1550
1785
|
const unique = new Map();
|
|
1551
1786
|
for (const location of paths) {
|
|
1552
1787
|
if (location.length === 0)
|
|
1553
1788
|
continue;
|
|
1554
1789
|
const resolved = node_path_1.default.resolve(location);
|
|
1555
|
-
unique.set(pathKey(resolved), resolved);
|
|
1790
|
+
unique.set(WatchPaths_1.WatchPaths.pathKey(resolved, identities), resolved);
|
|
1556
1791
|
}
|
|
1557
1792
|
return [...unique.values()];
|
|
1558
1793
|
}
|
|
1559
1794
|
function normalizeProjectInputSnapshot(snapshot) {
|
|
1560
|
-
const identities = (0,
|
|
1795
|
+
const identities = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)();
|
|
1561
1796
|
const files = new Map();
|
|
1562
1797
|
const globs = new Map();
|
|
1563
1798
|
const reloadDirectories = new Map();
|
|
@@ -1587,7 +1822,7 @@ function normalizeProjectInputSnapshot(snapshot) {
|
|
|
1587
1822
|
};
|
|
1588
1823
|
}
|
|
1589
1824
|
function projectInputSnapshotsEqual(left, right) {
|
|
1590
|
-
const identities = (0,
|
|
1825
|
+
const identities = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)();
|
|
1591
1826
|
return (
|
|
1592
1827
|
// Every sibling comparison in this class decides on identity, and this one
|
|
1593
1828
|
// is only safe today because both operands come from the same normalizer.
|
|
@@ -1598,150 +1833,28 @@ function projectInputSnapshotsEqual(left, right) {
|
|
|
1598
1833
|
arraysEqual(left.reloadDirectories ?? [], right.reloadDirectories ?? []) &&
|
|
1599
1834
|
arraysEqual(left.reloadFiles ?? [], right.reloadFiles ?? []));
|
|
1600
1835
|
}
|
|
1601
|
-
function literalGlobRoot(pattern) {
|
|
1602
|
-
const resolved = node_path_1.default.resolve(pattern);
|
|
1603
|
-
const normalized = resolved.split("\\").join("/");
|
|
1604
|
-
const wildcard = normalized.search(/[*?]/);
|
|
1605
|
-
if (wildcard === -1)
|
|
1606
|
-
return node_path_1.default.dirname(resolved);
|
|
1607
|
-
const separator = normalized.lastIndexOf("/", wildcard);
|
|
1608
|
-
const prefix = separator < 0 ? "." : normalized.slice(0, separator);
|
|
1609
|
-
const volumeRoot = node_path_1.default.parse(resolved).root;
|
|
1610
|
-
const normalizedVolumeRoot = volumeRoot.split("\\").join("/");
|
|
1611
|
-
if (prefix.length === 0 ||
|
|
1612
|
-
prefix === normalizedVolumeRoot.replace(/\/$/, "")) {
|
|
1613
|
-
return volumeRoot;
|
|
1614
|
-
}
|
|
1615
|
-
return node_path_1.default.resolve(prefix);
|
|
1616
|
-
}
|
|
1617
1836
|
function projectInputDeclarationKey(kind, declaration) {
|
|
1618
|
-
return `${kind}\0${(0,
|
|
1837
|
+
return `${kind}\0${(0, resolveProjectInputPath_1.resolveProjectInputPath)(declaration)}`;
|
|
1619
1838
|
}
|
|
1620
1839
|
/**
|
|
1621
|
-
*
|
|
1622
|
-
* declaration.
|
|
1840
|
+
* Metadata, fingerprint, and physical-owner identities for a tracked file.
|
|
1623
1841
|
*
|
|
1624
|
-
*
|
|
1625
|
-
*
|
|
1626
|
-
*
|
|
1627
|
-
*
|
|
1628
|
-
* except that the boundary never rises to a directory holding the project,
|
|
1629
|
-
* since such a root outranks the project's own in the active merge and leaves
|
|
1630
|
-
* one handle over a shared system directory to carry everything. An external
|
|
1631
|
-
* declaration that can only be owned that way falls back to its own tree, and
|
|
1632
|
-
* is left unwatched when even that would contain the project.
|
|
1633
|
-
*/
|
|
1634
|
-
function projectInputWatchDirectories(target, projectRoot) {
|
|
1635
|
-
const root = projectInputRecursiveWatchRoot(target, projectRoot);
|
|
1636
|
-
return root === undefined ? [] : [root];
|
|
1637
|
-
}
|
|
1638
|
-
/**
|
|
1639
|
-
* Removes recursive roots already covered by an ancestor without rewriting the
|
|
1640
|
-
* declaration-specific roots retained by WatchTopology.
|
|
1842
|
+
* Modification time and size avoid a read on an ordinary broad scan. A strong
|
|
1843
|
+
* event compares the fingerprint, so a timestamp collision cannot hide an edit
|
|
1844
|
+
* and a metadata-only notification does not create a build. Device and inode
|
|
1845
|
+
* answer whether a POSIX per-file watcher still owns the path.
|
|
1641
1846
|
*/
|
|
1642
|
-
function
|
|
1643
|
-
const unique = new Map();
|
|
1644
|
-
for (const directory of directories) {
|
|
1645
|
-
// Coverage is decided on physical identity so two spellings of one
|
|
1646
|
-
// directory cannot both survive, but the surviving entry keeps the
|
|
1647
|
-
// caller's spelling: this function selects roots, it does not rename them.
|
|
1648
|
-
const identity = identities.resolve(directory);
|
|
1649
|
-
if (!unique.has(identity.key))
|
|
1650
|
-
unique.set(identity.key, directory);
|
|
1651
|
-
}
|
|
1652
|
-
return [...unique]
|
|
1653
|
-
.filter(([key]) => {
|
|
1654
|
-
let ancestor = node_path_1.default.dirname(key);
|
|
1655
|
-
while (ancestor !== key) {
|
|
1656
|
-
if (unique.has(ancestor))
|
|
1657
|
-
return false;
|
|
1658
|
-
const parent = node_path_1.default.dirname(ancestor);
|
|
1659
|
-
if (parent === ancestor)
|
|
1660
|
-
break;
|
|
1661
|
-
ancestor = parent;
|
|
1662
|
-
}
|
|
1663
|
-
return true;
|
|
1664
|
-
})
|
|
1665
|
-
.map(([, directory]) => directory);
|
|
1666
|
-
}
|
|
1667
|
-
function projectInputAvailableWatchDirectory(location, rejected, identities = (0, projectInputPathIdentity_1.createProjectInputPathIdentityContext)(), projectRoot) {
|
|
1668
|
-
const resolvedProjectRoot = projectRoot === undefined ? undefined : node_path_1.default.resolve(projectRoot);
|
|
1669
|
-
let current = node_path_1.default.resolve(location);
|
|
1670
|
-
while (true) {
|
|
1671
|
-
const identity = identities.resolve(current);
|
|
1672
|
-
// Escalation obeys the same ceiling root selection does. A watcher that
|
|
1673
|
-
// failed once would otherwise be replaced by one over a directory holding
|
|
1674
|
-
// the project, which outranks the project's own root in the active merge
|
|
1675
|
-
// and re-opens, through the recovery path, the exact swallow that selection
|
|
1676
|
-
// refuses to create. Giving up the failed root is the lesser loss.
|
|
1677
|
-
if (resolvedProjectRoot !== undefined &&
|
|
1678
|
-
identity.key !== identities.resolve(resolvedProjectRoot).key &&
|
|
1679
|
-
identities.isWithin(identity.path, resolvedProjectRoot)) {
|
|
1680
|
-
return undefined;
|
|
1681
|
-
}
|
|
1682
|
-
if (!rejected.has(identity.key))
|
|
1683
|
-
return identity.path;
|
|
1684
|
-
const parent = node_path_1.default.dirname(current);
|
|
1685
|
-
if (parent === current)
|
|
1686
|
-
return undefined;
|
|
1687
|
-
const fallback = nearestExistingDirectory(parent);
|
|
1688
|
-
if (fallback === undefined)
|
|
1689
|
-
return undefined;
|
|
1690
|
-
current = fallback;
|
|
1691
|
-
}
|
|
1692
|
-
}
|
|
1693
|
-
function projectInputRecursiveWatchRoot(target, projectRoot, identities = (0, projectInputPathIdentity_1.createProjectInputPathIdentityContext)()) {
|
|
1694
|
-
const resolvedTarget = node_path_1.default.resolve(target);
|
|
1695
|
-
const resolvedProjectRoot = node_path_1.default.resolve(projectRoot);
|
|
1696
|
-
if (identities.isWithin(resolvedProjectRoot, resolvedTarget)) {
|
|
1697
|
-
return nearestExistingDirectory(resolvedProjectRoot);
|
|
1698
|
-
}
|
|
1699
|
-
// An external anchor rises to the declared parent so a tree that does not
|
|
1700
|
-
// exist yet is still observed, and so siblings under it share one handle. It
|
|
1701
|
-
// may not rise past the project, though: a directory that contains the
|
|
1702
|
-
// project swallows the project's own root when the two are merged, and every
|
|
1703
|
-
// in-project declaration then rides one recursive handle over a shared system
|
|
1704
|
-
// directory — a temp root, or the filesystem root itself — which delivers
|
|
1705
|
-
// nothing. Prefer the declared parent, fall back to the target's own tree,
|
|
1706
|
-
// and decline rather than widen past the project.
|
|
1707
|
-
for (const candidate of [
|
|
1708
|
-
nearestExistingDirectory(node_path_1.default.dirname(resolvedTarget)),
|
|
1709
|
-
nearestExistingDirectory(resolvedTarget),
|
|
1710
|
-
]) {
|
|
1711
|
-
if (candidate === undefined)
|
|
1712
|
-
continue;
|
|
1713
|
-
// The project root cannot outrank itself in the merge, so it is the one
|
|
1714
|
-
// container that is never a swallow — it is the owner the internal branch
|
|
1715
|
-
// would have chosen anyway. A declaration reached through an in-project
|
|
1716
|
-
// directory symlink lands here, and rejecting it would drop the hoist that
|
|
1717
|
-
// keeps a replaced directory from stranding a child handle.
|
|
1718
|
-
if (identities.resolve(candidate).key !==
|
|
1719
|
-
identities.resolve(resolvedProjectRoot).key &&
|
|
1720
|
-
identities.isWithin(candidate, resolvedProjectRoot)) {
|
|
1721
|
-
continue;
|
|
1722
|
-
}
|
|
1723
|
-
return candidate;
|
|
1724
|
-
}
|
|
1725
|
-
return undefined;
|
|
1726
|
-
}
|
|
1727
|
-
/**
|
|
1728
|
-
* Cheap content and physical-owner identities for a tracked file.
|
|
1729
|
-
*
|
|
1730
|
-
* Modification time and size answer "did the bytes move" without reading the
|
|
1731
|
-
* file. Device and inode answer whether a POSIX per-file watcher still owns the
|
|
1732
|
-
* path. Keeping the answers separate lets an identical atomic replacement
|
|
1733
|
-
* rebind its watcher without inventing a compiler notification.
|
|
1734
|
-
*/
|
|
1735
|
-
function compilerFileSnapshot(location) {
|
|
1847
|
+
function compilerFileSnapshot(location, fingerprint) {
|
|
1736
1848
|
try {
|
|
1737
1849
|
const stats = node_fs_1.default.statSync(location);
|
|
1738
1850
|
return {
|
|
1739
1851
|
content: `${stats.mtimeMs}:${stats.size}`,
|
|
1852
|
+
fingerprint,
|
|
1740
1853
|
owner: `${stats.dev}:${stats.ino}`,
|
|
1741
1854
|
};
|
|
1742
1855
|
}
|
|
1743
1856
|
catch {
|
|
1744
|
-
return { content: "", owner: "" };
|
|
1857
|
+
return { content: "", fingerprint: "", owner: "" };
|
|
1745
1858
|
}
|
|
1746
1859
|
}
|
|
1747
1860
|
function isSymbolicLink(location) {
|
|
@@ -1752,18 +1865,7 @@ function isSymbolicLink(location) {
|
|
|
1752
1865
|
return false;
|
|
1753
1866
|
}
|
|
1754
1867
|
}
|
|
1755
|
-
function
|
|
1756
|
-
let current = node_path_1.default.resolve(location);
|
|
1757
|
-
while (true) {
|
|
1758
|
-
if (isDirectory(current))
|
|
1759
|
-
return current;
|
|
1760
|
-
const parent = node_path_1.default.dirname(current);
|
|
1761
|
-
if (parent === current)
|
|
1762
|
-
return undefined;
|
|
1763
|
-
current = parent;
|
|
1764
|
-
}
|
|
1765
|
-
}
|
|
1766
|
-
function matchesProjectInput(snapshot, location, identities = (0, projectInputPathIdentity_1.createProjectInputPathIdentityContext)()) {
|
|
1868
|
+
function matchesProjectInput(snapshot, location, identities = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)()) {
|
|
1767
1869
|
const key = identities.resolve(location).key;
|
|
1768
1870
|
return (snapshot.files.some((file) => identities.resolve(file).key === key) ||
|
|
1769
1871
|
(snapshot.reloadFiles ?? []).some((file) => identities.resolve(file).key === key) ||
|
|
@@ -1771,89 +1873,52 @@ function matchesProjectInput(snapshot, location, identities = (0, projectInputPa
|
|
|
1771
1873
|
snapshot.globs.some((glob) => matchesProjectInputGlob(glob, location, identities)));
|
|
1772
1874
|
}
|
|
1773
1875
|
/**
|
|
1774
|
-
*
|
|
1775
|
-
* object that was replaced.
|
|
1776
|
-
*
|
|
1777
|
-
* Only one backend needs the answer. Node routes a recursive watch to its own
|
|
1778
|
-
* per-directory implementation when the platform is neither macOS nor Windows,
|
|
1779
|
-
* and that implementation keys its handles by path: the handle for a directory
|
|
1780
|
-
* renamed away stays bound to the object that left, and any child whose name
|
|
1781
|
-
* survives the swap is skipped as already known. The native subtree backends
|
|
1782
|
-
* both other platforms use follow the path, so retiring their watcher would buy
|
|
1783
|
-
* nothing and would open a window in which no events are delivered.
|
|
1784
|
-
*
|
|
1785
|
-
* The answer is deliberately narrower than the rescan rule, because
|
|
1786
|
-
* reinstalling a root costs one watch descriptor per entry beneath it, which an
|
|
1787
|
-
* install storm would pay thousands of times. A directory appearing inside a
|
|
1788
|
-
* glob root deserves a rescan but replaces nothing a root stands on, and a
|
|
1789
|
-
* reload directory anchors the directory that contains it rather than itself,
|
|
1790
|
-
* since its fingerprint is a digest of its own immediate entries and nothing
|
|
1791
|
-
* below it can reach the declared corpus.
|
|
1792
|
-
*/
|
|
1793
|
-
function projectInputReplacementStrandsWatchers(snapshot, location, identities = (0, projectInputPathIdentity_1.createProjectInputPathIdentityContext)(), platform = process.platform) {
|
|
1794
|
-
if (platform === "darwin" || platform === "win32")
|
|
1795
|
-
return false;
|
|
1796
|
-
const changed = node_path_1.default.resolve(location);
|
|
1797
|
-
if (!isDirectory(changed))
|
|
1798
|
-
return false;
|
|
1799
|
-
return projectInputAnchorsDeclaration(snapshot, node_path_1.default.dirname(changed), identities);
|
|
1800
|
-
}
|
|
1801
|
-
function projectInputAnchorsDeclaration(snapshot, directory, identities) {
|
|
1802
|
-
return (snapshot.files.some((file) => identities.isWithin(directory, file)) ||
|
|
1803
|
-
(snapshot.reloadFiles ?? []).some((file) => identities.isWithin(directory, file)) ||
|
|
1804
|
-
(snapshot.reloadDirectories ?? []).some((entry) =>
|
|
1805
|
-
// A reload directory anchors the directory that contains it, never
|
|
1806
|
-
// itself. Its own fingerprint is a digest of its immediate entries, so
|
|
1807
|
-
// nothing below it can reach the corpus, and treating it as its own
|
|
1808
|
-
// anchor would rearm for every entry created directly inside it —
|
|
1809
|
-
// including `node_modules`, which contributors publish as one.
|
|
1810
|
-
identities.isWithin(directory, entry) &&
|
|
1811
|
-
identities.resolve(directory).key !== identities.resolve(entry).key) ||
|
|
1812
|
-
snapshot.globs.some((glob) => identities.isWithin(directory, literalGlobRoot(glob))));
|
|
1813
|
-
}
|
|
1814
|
-
/**
|
|
1815
|
-
* Decide whether an event that named no declared input can still have moved
|
|
1816
|
-
* one.
|
|
1876
|
+
* Attribute a complete population scan to the changes it actually observed.
|
|
1817
1877
|
*
|
|
1818
|
-
*
|
|
1819
|
-
*
|
|
1820
|
-
*
|
|
1821
|
-
*
|
|
1822
|
-
*
|
|
1823
|
-
*
|
|
1878
|
+
* Observer attention can arrive late for bytes already admitted while another
|
|
1879
|
+
* member has changed. Such a name must not consume that member's delta under
|
|
1880
|
+
* the wrong path or select execution reload for unchanged selection bytes. A
|
|
1881
|
+
* directory event remains a valid cause when it contains every changed member.
|
|
1882
|
+
* Ancestor resolution-directory digests accompany those members rather than
|
|
1883
|
+
* replace their identity; unrelated directory deltas remain separate. When only
|
|
1884
|
+
* those digests changed, an untracked native name can still explain an
|
|
1885
|
+
* immediate-entry change whose member was not selected, but not another
|
|
1886
|
+
* directory's independent delta.
|
|
1824
1887
|
*/
|
|
1825
|
-
function
|
|
1826
|
-
const
|
|
1827
|
-
const
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1888
|
+
function reconcileProjectInputChange(input) {
|
|
1889
|
+
const directories = new Set(input.reloadDirectories.map((location) => input.identities.resolve(location).key));
|
|
1890
|
+
const members = input.changedInputs.filter((location) => !directories.has(input.identities.resolve(location).key));
|
|
1891
|
+
const memberAncestors = new Set();
|
|
1892
|
+
for (const member of members) {
|
|
1893
|
+
let ancestor = node_path_1.default.dirname(input.identities.resolve(member).path);
|
|
1894
|
+
while (true) {
|
|
1895
|
+
const identity = input.identities.resolve(ancestor);
|
|
1896
|
+
if (memberAncestors.has(identity.key))
|
|
1897
|
+
break;
|
|
1898
|
+
memberAncestors.add(identity.key);
|
|
1899
|
+
const parent = node_path_1.default.dirname(identity.path);
|
|
1900
|
+
if (parent === identity.path)
|
|
1901
|
+
break;
|
|
1902
|
+
ancestor = parent;
|
|
1903
|
+
}
|
|
1904
|
+
}
|
|
1905
|
+
const observed = input.changedInputs.filter((location) => {
|
|
1906
|
+
const key = input.identities.resolve(location).key;
|
|
1907
|
+
return !directories.has(key) || !memberAncestors.has(key);
|
|
1908
|
+
});
|
|
1909
|
+
const changed = input.changed;
|
|
1910
|
+
if (changed !== undefined) {
|
|
1911
|
+
const key = input.identities.resolve(changed).key;
|
|
1912
|
+
if (observed.every((location) => input.identities.isWithin(changed, location)) ||
|
|
1913
|
+
(members.length === 0 &&
|
|
1914
|
+
!input.previous.has(key) &&
|
|
1915
|
+
!input.next.has(key) &&
|
|
1916
|
+
observed.every((location) => input.identities.resolve(location).key ===
|
|
1917
|
+
input.identities.resolve(node_path_1.default.dirname(changed)).key))) {
|
|
1918
|
+
return changed;
|
|
1919
|
+
}
|
|
1920
|
+
}
|
|
1921
|
+
return observed.length === 1 ? observed[0] : undefined;
|
|
1857
1922
|
}
|
|
1858
1923
|
function projectInputChangedPaths(input) {
|
|
1859
1924
|
const changed = new Map();
|
|
@@ -1874,123 +1939,6 @@ function projectInputChangedPaths(input) {
|
|
|
1874
1939
|
}
|
|
1875
1940
|
return [...changed.values()];
|
|
1876
1941
|
}
|
|
1877
|
-
/**
|
|
1878
|
-
* Classify an exact execution-selection input ahead of ordinary project data.
|
|
1879
|
-
*
|
|
1880
|
-
* `changedInputs` carries fingerprint or membership deltas, so a filename-less
|
|
1881
|
-
* event can still select the cold lane. A named exact event selects the cold
|
|
1882
|
-
* lane only after the surrounding change detector admits the event; unchanged
|
|
1883
|
-
* bytes remain quiet before this classifier is observed.
|
|
1884
|
-
*/
|
|
1885
|
-
function projectInputReloadEventShouldNotify(input) {
|
|
1886
|
-
const identities = (0, projectInputPathIdentity_1.createProjectInputPathIdentityContext)();
|
|
1887
|
-
const reloadFiles = new Set(input.reloadFiles.map((location) => identities.resolve(location).key));
|
|
1888
|
-
const reloadDirectories = (input.reloadDirectories ?? []).map((location) => identities.resolve(location));
|
|
1889
|
-
// Territory a declared glob is rooted at, judged against the resolution
|
|
1890
|
-
// directory that would otherwise claim it. A project root is published as a
|
|
1891
|
-
// resolution directory because the config lives there, so the directory a
|
|
1892
|
-
// glob is rooted at reads as a new immediate entry the moment it appears --
|
|
1893
|
-
// and appearing is what a declared population does. The data lane already
|
|
1894
|
-
// reports it, with program invalidation when the membership moved, which is
|
|
1895
|
-
// the cold-Program-same-process transition that belongs to data.
|
|
1896
|
-
//
|
|
1897
|
-
// Data can only carve out strictly below a resolution directory. A glob
|
|
1898
|
-
// rooted on that directory, or above it -- `literalGlobRoot` answers with the
|
|
1899
|
-
// volume root for a pattern with no literal prefix -- would otherwise exempt
|
|
1900
|
-
// everything the directory exists to classify, and the selection lane would
|
|
1901
|
-
// retire in silence. Its role predates any glob drawn around it.
|
|
1902
|
-
//
|
|
1903
|
-
// Only glob roots, either way. A declared file sitting directly in a
|
|
1904
|
-
// resolution directory is still a selection surface: its own bytes are what a
|
|
1905
|
-
// project rule reads to decide, once per execution.
|
|
1906
|
-
const globRoots = (input.globs ?? []).map((glob) => identities.resolve(literalGlobRoot(glob)));
|
|
1907
|
-
const exemptedFrom = (directory, location) => globRoots.some((globRoot) => globRoot.key !== directory.key &&
|
|
1908
|
-
identities.isWithin(directory.path, globRoot.path) &&
|
|
1909
|
-
identities.isWithin(globRoot.path, location));
|
|
1910
|
-
// A reload directory is a non-recursive surface: its digest covers its
|
|
1911
|
-
// immediate entries' names, kinds, and link targets, so it moves only when the
|
|
1912
|
-
// directory itself moves or when an entry it holds directly does. Matching the
|
|
1913
|
-
// whole subtree instead makes a resolution ancestor -- the lint config graph
|
|
1914
|
-
// publishes every node_modules level it searched, up to the filesystem root --
|
|
1915
|
-
// read every edit beneath it as a selection change, which restarts the sidecar
|
|
1916
|
-
// on each keystroke and ends warm reuse for any project inside one.
|
|
1917
|
-
const holdsAsImmediateEntry = (location) => {
|
|
1918
|
-
const parent = identities.resolve(node_path_1.default.dirname(location)).key;
|
|
1919
|
-
return reloadDirectories.some((directory) => directory.key === parent && exemptedFrom(directory, location) === false);
|
|
1920
|
-
};
|
|
1921
|
-
const namesDirectory = (location) => {
|
|
1922
|
-
const key = identities.resolve(location).key;
|
|
1923
|
-
return reloadDirectories.some((directory) => directory.key === key);
|
|
1924
|
-
};
|
|
1925
|
-
// A digest delta on the directory itself is the only signal there is when the
|
|
1926
|
-
// entry that appeared is not a declared match, so it cannot simply be dropped
|
|
1927
|
-
// -- but it also cannot say what appeared. The event being classified in the
|
|
1928
|
-
// same pass can: when it names data, the delta it caused is that data's, and
|
|
1929
|
-
// when it names anything else, or nothing at all, the safe reading is that
|
|
1930
|
-
// resolution moved. A missed reselection is a wrong answer; a spare restart is
|
|
1931
|
-
// a slow one.
|
|
1932
|
-
const explains = (directory) => {
|
|
1933
|
-
const causes = input.causedBy ?? (input.changed === undefined ? [] : [input.changed]);
|
|
1934
|
-
// Only an immediate entry can move this directory's digest, so only an
|
|
1935
|
-
// immediate entry can account for the delta. Asking whether the event was
|
|
1936
|
-
// data somewhere else answers a different directory's question, and one
|
|
1937
|
-
// exemption would then cancel every other directory's evidence.
|
|
1938
|
-
return causes.some((location) => {
|
|
1939
|
-
const parent = identities.resolve(node_path_1.default.dirname(location)).key;
|
|
1940
|
-
return parent === directory.key && exemptedFrom(directory, location);
|
|
1941
|
-
});
|
|
1942
|
-
};
|
|
1943
|
-
const isReloadDirectoryEvent = (location) => namesDirectory(location) || holdsAsImmediateEntry(location);
|
|
1944
|
-
const isReloadDirectoryDelta = (location) => {
|
|
1945
|
-
if (holdsAsImmediateEntry(location))
|
|
1946
|
-
return true;
|
|
1947
|
-
const key = identities.resolve(location).key;
|
|
1948
|
-
return reloadDirectories.some((directory) => directory.key === key && explains(directory) === false);
|
|
1949
|
-
};
|
|
1950
|
-
return ((input.changed !== undefined &&
|
|
1951
|
-
(reloadFiles.has(identities.resolve(input.changed).key) ||
|
|
1952
|
-
isReloadDirectoryEvent(input.changed))) ||
|
|
1953
|
-
input.changedInputs.some((location) => reloadFiles.has(identities.resolve(location).key) ||
|
|
1954
|
-
isReloadDirectoryDelta(location)));
|
|
1955
|
-
}
|
|
1956
|
-
/**
|
|
1957
|
-
* Return whether a project-input population transition can reshape a Program.
|
|
1958
|
-
*
|
|
1959
|
-
* JSON is data to a ProjectRule but may simultaneously be a `resolveJsonModule`
|
|
1960
|
-
* source. TypeScript and JavaScript paths can likewise overlap a project-input
|
|
1961
|
-
* declaration. Their creation or deletion therefore requires a cold Program
|
|
1962
|
-
* inside the existing resident process. A filename-less event cannot identify
|
|
1963
|
-
* the changed member and is conservatively invalidating whenever the population
|
|
1964
|
-
* moved.
|
|
1965
|
-
*/
|
|
1966
|
-
function projectInputMembershipInvalidatesProgram(input) {
|
|
1967
|
-
if (input.contentChanged === true &&
|
|
1968
|
-
(input.changedInputs ??
|
|
1969
|
-
(input.changed === undefined ? [] : [input.changed])).some((location) => node_path_1.default.basename(location).toLowerCase() === "package.json")) {
|
|
1970
|
-
return true;
|
|
1971
|
-
}
|
|
1972
|
-
if (mapsEqual(input.previous, input.next))
|
|
1973
|
-
return false;
|
|
1974
|
-
if (input.changed === undefined)
|
|
1975
|
-
return true;
|
|
1976
|
-
for (const [key, location] of input.previous) {
|
|
1977
|
-
if (input.next.has(key) === false &&
|
|
1978
|
-
projectInputPathMayAffectProgram(location)) {
|
|
1979
|
-
return true;
|
|
1980
|
-
}
|
|
1981
|
-
}
|
|
1982
|
-
for (const [key, location] of input.next) {
|
|
1983
|
-
if (input.previous.has(key) === false &&
|
|
1984
|
-
projectInputPathMayAffectProgram(location)) {
|
|
1985
|
-
return true;
|
|
1986
|
-
}
|
|
1987
|
-
}
|
|
1988
|
-
return false;
|
|
1989
|
-
}
|
|
1990
|
-
function projectInputPathMayAffectProgram(location) {
|
|
1991
|
-
const extension = node_path_1.default.extname(location).toLowerCase();
|
|
1992
|
-
return extension === ".json" || isCompilerEmittableSourceExtension(extension);
|
|
1993
|
-
}
|
|
1994
1942
|
function compilerMembershipChange(previous, next) {
|
|
1995
1943
|
const changed = new Map();
|
|
1996
1944
|
for (const [key, location] of previous) {
|
|
@@ -2004,8 +1952,9 @@ function compilerMembershipChange(previous, next) {
|
|
|
2004
1952
|
return [...changed.values()].sort();
|
|
2005
1953
|
}
|
|
2006
1954
|
function projectInputCompilerMembershipChange(snapshot, changed) {
|
|
2007
|
-
|
|
2008
|
-
|
|
1955
|
+
const identities = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)();
|
|
1956
|
+
return changed.filter((location) => matchesProjectInput(snapshot, location, identities) &&
|
|
1957
|
+
ProjectInputWatchRules_1.ProjectInputWatchRules.projectInputPathMayAffectProgram(location));
|
|
2009
1958
|
}
|
|
2010
1959
|
/**
|
|
2011
1960
|
* Name a compiler-membership transition as the recursive project watcher does.
|
|
@@ -2017,24 +1966,28 @@ function projectInputCompilerMembershipChange(snapshot, changed) {
|
|
|
2017
1966
|
* selection reload. The deepest matching glob owns the most specific delivery.
|
|
2018
1967
|
*/
|
|
2019
1968
|
function projectInputCompilerMembershipProjectChanges(locations, globs) {
|
|
2020
|
-
const identities = (0,
|
|
2021
|
-
const roots = globs.map((glob) => identities.resolve(literalGlobRoot(glob)));
|
|
1969
|
+
const identities = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)();
|
|
1970
|
+
const roots = globs.map((glob) => identities.resolve((0, literalGlobRoot_1.literalGlobRoot)(glob)));
|
|
2022
1971
|
const changes = new Map();
|
|
2023
1972
|
for (const location of locations) {
|
|
2024
1973
|
const candidate = identities.resolve(location);
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
.
|
|
1974
|
+
let root;
|
|
1975
|
+
for (const entry of roots) {
|
|
1976
|
+
if (identities.isWithin(entry.path, candidate.path) &&
|
|
1977
|
+
(root === undefined || entry.path.length > root.path.length)) {
|
|
1978
|
+
root = entry;
|
|
1979
|
+
}
|
|
1980
|
+
}
|
|
2028
1981
|
const change = root ?? candidate;
|
|
2029
1982
|
changes.set(change.key, change.path);
|
|
2030
1983
|
}
|
|
2031
1984
|
return [...changes.values()].sort();
|
|
2032
1985
|
}
|
|
2033
|
-
function fingerprintProjectInputMatches(matches) {
|
|
1986
|
+
function fingerprintProjectInputMatches(matches, readDirectory) {
|
|
2034
1987
|
const fingerprints = new Map();
|
|
2035
1988
|
for (const [key, location] of matches) {
|
|
2036
|
-
fingerprints.set(key, isDirectory(location)
|
|
2037
|
-
? fingerprintProjectInputDirectory(location)
|
|
1989
|
+
fingerprints.set(key, WatchPaths_1.WatchPaths.isDirectory(location)
|
|
1990
|
+
? fingerprintProjectInputDirectory(location, readDirectory)
|
|
2038
1991
|
: fingerprintProjectInputFile(location));
|
|
2039
1992
|
}
|
|
2040
1993
|
return fingerprints;
|
|
@@ -2050,10 +2003,9 @@ function fingerprintProjectInputFile(location) {
|
|
|
2050
2003
|
return "";
|
|
2051
2004
|
}
|
|
2052
2005
|
}
|
|
2053
|
-
function fingerprintProjectInputDirectory(location) {
|
|
2006
|
+
function fingerprintProjectInputDirectory(location, readDirectory) {
|
|
2054
2007
|
try {
|
|
2055
|
-
const entries =
|
|
2056
|
-
.readdirSync(location, { withFileTypes: true })
|
|
2008
|
+
const entries = readDirectory(location, { withFileTypes: true })
|
|
2057
2009
|
.map((entry) => {
|
|
2058
2010
|
const kind = entry.isDirectory()
|
|
2059
2011
|
? "directory"
|
|
@@ -2080,10 +2032,10 @@ function fingerprintProjectInputDirectory(location) {
|
|
|
2080
2032
|
return "";
|
|
2081
2033
|
}
|
|
2082
2034
|
}
|
|
2083
|
-
function matchesProjectInputGlob(pattern, location, identities = (0,
|
|
2084
|
-
const root = identities.resolve(literalGlobRoot(pattern));
|
|
2035
|
+
function matchesProjectInputGlob(pattern, location, identities = (0, createProjectInputPathIdentityContext_1.createProjectInputPathIdentityContext)()) {
|
|
2036
|
+
const root = identities.resolve((0, literalGlobRoot_1.literalGlobRoot)(pattern));
|
|
2085
2037
|
const candidate = identities.resolve(location);
|
|
2086
|
-
if (!(0,
|
|
2038
|
+
if (!(0, isProjectInputPathIdentityWithin_1.isProjectInputPathIdentityWithin)(root.key, candidate.key))
|
|
2087
2039
|
return false;
|
|
2088
2040
|
const sensitive = identities.caseSensitive(root.path);
|
|
2089
2041
|
const patternParts = node_path_1.default
|
|
@@ -2092,11 +2044,13 @@ function matchesProjectInputGlob(pattern, location, identities = (0, projectInpu
|
|
|
2092
2044
|
const candidateParts = node_path_1.default
|
|
2093
2045
|
.relative(root.path, candidate.path)
|
|
2094
2046
|
.split(node_path_1.default.sep);
|
|
2095
|
-
|
|
2096
|
-
|
|
2097
|
-
|
|
2098
|
-
|
|
2099
|
-
|
|
2047
|
+
// Unknown capability is an observation-routing question, not an identity
|
|
2048
|
+
// proof: admit either interpretation so an unproven case policy cannot hide
|
|
2049
|
+
// a possible declared input. The resolver retains distinct physical keys.
|
|
2050
|
+
return ((sensitive !== false &&
|
|
2051
|
+
matchProjectInputGlobParts(patternParts, candidateParts)) ||
|
|
2052
|
+
(sensitive !== true &&
|
|
2053
|
+
matchProjectInputGlobParts(patternParts.map((segment) => segment.toLowerCase()), candidateParts.map((segment) => segment.toLowerCase()))));
|
|
2100
2054
|
}
|
|
2101
2055
|
function matchProjectInputGlobParts(pattern, candidate) {
|
|
2102
2056
|
const memo = new Map();
|
|
@@ -2138,56 +2092,27 @@ function matchProjectInputGlobSegment(pattern, candidate) {
|
|
|
2138
2092
|
}
|
|
2139
2093
|
return new RegExp(`${source}$`, "u").test(candidate);
|
|
2140
2094
|
}
|
|
2141
|
-
function mapsEqual(left, right) {
|
|
2142
|
-
if (left.size !== right.size)
|
|
2143
|
-
return false;
|
|
2144
|
-
return [...left].every(([key, value]) => right.get(key) === value);
|
|
2145
|
-
}
|
|
2146
2095
|
function arraysEqual(left, right) {
|
|
2147
2096
|
return (left.length === right.length && left.every((value, i) => value === right[i]));
|
|
2148
2097
|
}
|
|
2149
|
-
function
|
|
2150
|
-
|
|
2151
|
-
return (relative === "" ||
|
|
2152
|
-
(relative !== ".." &&
|
|
2153
|
-
relative.startsWith(`..${node_path_1.default.sep}`) === false &&
|
|
2154
|
-
!node_path_1.default.isAbsolute(relative)));
|
|
2098
|
+
function isRecord(value) {
|
|
2099
|
+
return typeof value === "object" && value !== null;
|
|
2155
2100
|
}
|
|
2156
2101
|
/**
|
|
2157
|
-
*
|
|
2158
|
-
*
|
|
2159
|
-
*
|
|
2160
|
-
*
|
|
2161
|
-
* surviving tracked input below the watch root. Windows has no per-file
|
|
2162
|
-
* watchers here, so both named and unnamed directory events report inputs.
|
|
2102
|
+
* What a plugin build keys a plugin input on: the digest of the files its build
|
|
2103
|
+
* reads from a source directory (`pluginSourceDigest`), or a file's bytes. An
|
|
2104
|
+
* input that cannot be read has a state of its own, so the change that made it
|
|
2105
|
+
* unreadable is reported and the build names the failure.
|
|
2163
2106
|
*/
|
|
2164
|
-
function
|
|
2165
|
-
|
|
2166
|
-
|
|
2167
|
-
|
|
2168
|
-
|
|
2169
|
-
? [input.changed]
|
|
2170
|
-
: [];
|
|
2171
|
-
if (input.changed === undefined) {
|
|
2172
|
-
return {
|
|
2173
|
-
changes: candidates,
|
|
2174
|
-
rearm: input.platform === "win32" ? [] : candidates,
|
|
2175
|
-
refresh: true,
|
|
2176
|
-
};
|
|
2177
|
-
}
|
|
2178
|
-
if (candidates.length === 0) {
|
|
2179
|
-
return { changes: [], rearm: [], refresh: true };
|
|
2180
|
-
}
|
|
2181
|
-
if (input.platform === "win32") {
|
|
2182
|
-
return { changes: candidates, rearm: [], refresh: false };
|
|
2107
|
+
function pluginInputState(input) {
|
|
2108
|
+
try {
|
|
2109
|
+
return WatchPaths_1.WatchPaths.isDirectory(input)
|
|
2110
|
+
? `directory:${(0, pluginSourceDigest_1.pluginSourceDigest)(input)}`
|
|
2111
|
+
: `file:${fingerprintProjectInputFile(input)}`;
|
|
2183
2112
|
}
|
|
2184
|
-
|
|
2185
|
-
return {
|
|
2113
|
+
catch (error) {
|
|
2114
|
+
return `unreadable:${error instanceof Error ? error.message : String(error)}`;
|
|
2186
2115
|
}
|
|
2187
|
-
return { changes: [], rearm: [], refresh: false };
|
|
2188
|
-
}
|
|
2189
|
-
function isRecord(value) {
|
|
2190
|
-
return typeof value === "object" && value !== null;
|
|
2191
2116
|
}
|
|
2192
2117
|
/**
|
|
2193
2118
|
* Resolve the spelling a filesystem watcher must be registered under.
|
|
@@ -2217,11 +2142,13 @@ function watcherRegistrationPath(location) {
|
|
|
2217
2142
|
return location;
|
|
2218
2143
|
}
|
|
2219
2144
|
}
|
|
2220
|
-
|
|
2221
|
-
|
|
2222
|
-
|
|
2223
|
-
|
|
2224
|
-
|
|
2225
|
-
|
|
2145
|
+
/**
|
|
2146
|
+
* Report the actual decision inputs, without additional filesystem
|
|
2147
|
+
* observations.
|
|
2148
|
+
*/
|
|
2149
|
+
function reportProjectInputDecision(decision) {
|
|
2150
|
+
if (!process.env.TTSC_WATCH_DEBUG_INPUTS)
|
|
2151
|
+
return;
|
|
2152
|
+
process.stdout.write(`[ttsc:debug] project-input decision ${JSON.stringify(decision)}\n`);
|
|
2226
2153
|
}
|
|
2227
|
-
//# sourceMappingURL=
|
|
2154
|
+
//# sourceMappingURL=WatchTopology.js.map
|