From cae589d277bd99305dc2c2a5b6fd5af0f7087fd2 Mon Sep 17 00:00:00 2001 From: Sheetal Nandi Date: Wed, 11 Oct 2023 12:14:21 -0700 Subject: [PATCH] Handle unnecessary typings request force just because root files change First unresolved import gets the typing file into cache and sets it as root, This results in scheduling new typing request with that unresolved import missing The result will come back with typing file that is omitted, so root file will change but file will still be part of program so its not really removed from program --- src/server/project.ts | 21 +- ...ultiple-projects-with-shared-resolution.js | 100 --------- ...abling-typeAquisition-multiple-projects.js | 102 --------- .../change-after-enabling-typeAquisition.js | 102 --------- ...ultiple-projects-with-shared-resolution.js | 205 ----------------- ...aller-installs-typing-multiple-projects.js | 209 ------------------ ...n-when-typing-installer-installs-typing.js | 102 --------- ...ultiple-projects-with-shared-resolution.js | 105 --------- ...sabled-typeAquisition-multiple-projects.js | 107 --------- ...ultiple-projects-with-shared-resolution.js | 205 ----------------- ...nabled-typeAquisition-multiple-projects.js | 209 ------------------ .../typeAquisition/enabled-typeAquisition.js | 102 --------- ...ultiple-projects-with-shared-resolution.js | 105 --------- ...aller-installs-typing-multiple-projects.js | 107 --------- ...ultiple-projects-with-shared-resolution.js | 105 --------- ...after-project-changes-multiple-projects.js | 107 --------- ...rom-node_modules-empty-types-has-import.js | 94 -------- .../install-typings-for-unresolved-imports.js | 6 +- ...date-the-resolutions-with-trimmed-names.js | 33 ++- .../invalidate-the-resolutions.js | 119 +--------- ...utions-pointing-to-js-on-typing-install.js | 3 +- .../should-handle-node-core-modules.js | 28 +-- 22 files changed, 63 insertions(+), 2213 deletions(-) diff --git a/src/server/project.ts b/src/server/project.ts index f3f8026a9a2..dec9d635980 100644 --- a/src/server/project.ts +++ b/src/server/project.ts @@ -33,6 +33,8 @@ import { DocumentPositionMapper, ensureTrailingDirectorySeparator, enumerateInsertsAndDeletes, + equateStringsCaseInsensitive, + equateStringsCaseSensitive, every, explainFiles, ExportInfoMap, @@ -88,7 +90,6 @@ import { ModuleResolutionCache, ModuleResolutionHost, ModuleSpecifierCache, - noop, noopFileWatcher, normalizePath, normalizeSlashes, @@ -1520,7 +1521,23 @@ export abstract class Project implements LanguageServiceHost, ModuleResolutionHo unresolvedImports, }; const typingFiles = !typeAcquisition || !typeAcquisition.enable ? emptyArray : toSorted(newTypings); - if (enumerateInsertsAndDeletes(typingFiles, this.typingFiles, getStringComparer(!this.useCaseSensitiveFileNames()), /*inserted*/ noop, removed => this.detachScriptInfoFromProject(removed))) { + // The typings files are result of types acquired based on unresolved imports and other structure + // With respect to unresolved imports: + // The first time we see unresolved import the TI will fetch the typing into cache and return it as part of typings file + // This makes typings file set as files to be included as root + // Program update on this will resolve the unresolved imports from the previous pass + // Because resolution has changed, this will enqueue TI request without the previously unresolved imports + // As a result TI will send new Typings files that does not contain the typing files we got before + // So our root files will change as part of that but we dont want to detach the typing files that are no more typings file + // but rather let program update do that + // This ensures that if nothing else changes, program will still have that file and the update doesnt mark file as added or removed unncessarily + if ( + !arrayIsEqualTo( + typingFiles, + this.typingFiles, + this.useCaseSensitiveFileNames() ? equateStringsCaseSensitive : equateStringsCaseInsensitive, + ) + ) { // If typing files changed, then only schedule project update this.typingFiles = typingFiles; // Invalidate files with unresolved imports diff --git a/tests/baselines/reference/tsserver/typeAquisition/change-after-enabling-typeAquisition-multiple-projects-with-shared-resolution.js b/tests/baselines/reference/tsserver/typeAquisition/change-after-enabling-typeAquisition-multiple-projects-with-shared-resolution.js index d3738046620..cbf310459d9 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/change-after-enabling-typeAquisition-multiple-projects-with-shared-resolution.js +++ b/tests/baselines/reference/tsserver/typeAquisition/change-after-enabling-typeAquisition-multiple-projects-with-shared-resolution.js @@ -1804,110 +1804,10 @@ Info seq [hh:mm:ss:mss] Files (3) /home/src/tslibs/TS/Lib/lib.d.ts Text-1 "/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ndeclare const console: { log(msg: any): void; };" /home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts Text-1 "export const x = 1;" /users/user/projects/project1/app.js SVC-1-0 "var x = require('bar');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project1/app.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project1", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project1/bower_components", - "/users/user/projects/project1/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project1/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 2 Timeout callback:: count: 2 diff --git a/tests/baselines/reference/tsserver/typeAquisition/change-after-enabling-typeAquisition-multiple-projects.js b/tests/baselines/reference/tsserver/typeAquisition/change-after-enabling-typeAquisition-multiple-projects.js index 5a32a9ea59c..7f86b400275 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/change-after-enabling-typeAquisition-multiple-projects.js +++ b/tests/baselines/reference/tsserver/typeAquisition/change-after-enabling-typeAquisition-multiple-projects.js @@ -1845,112 +1845,10 @@ Info seq [hh:mm:ss:mss] Files (3) /home/src/tslibs/TS/Lib/lib.d.ts Text-1 "/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ndeclare const console: { log(msg: any): void; };" /home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts Text-1 "export const x = 1;" /users/user/projects/project1/app.js SVC-1-0 "var x = require('bar');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project1/app.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project1", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Searching for typing names in /users/user/projects/project1/node_modules; all files: [] -TI:: [hh:mm:ss:mss] Found package names: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project1/bower_components", - "/users/user/projects/project1/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project1/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 2 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typeAquisition/change-after-enabling-typeAquisition.js b/tests/baselines/reference/tsserver/typeAquisition/change-after-enabling-typeAquisition.js index 894cec727e0..f11dc714e2a 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/change-after-enabling-typeAquisition.js +++ b/tests/baselines/reference/tsserver/typeAquisition/change-after-enabling-typeAquisition.js @@ -846,112 +846,10 @@ Info seq [hh:mm:ss:mss] Files (3) /home/src/tslibs/TS/Lib/lib.d.ts Text-1 "/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ndeclare const console: { log(msg: any): void; };" /home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts Text-1 "export const x = 1;" /users/user/projects/project1/app.js SVC-1-0 "var x = require('bar');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project1/app.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project1", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Searching for typing names in /users/user/projects/project1/node_modules; all files: [] -TI:: [hh:mm:ss:mss] Found package names: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project1/bower_components", - "/users/user/projects/project1/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project1/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 2 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typeAquisition/changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects-with-shared-resolution.js b/tests/baselines/reference/tsserver/typeAquisition/changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects-with-shared-resolution.js index 6ce1d6f70c4..a70f5c55afd 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects-with-shared-resolution.js +++ b/tests/baselines/reference/tsserver/typeAquisition/changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects-with-shared-resolution.js @@ -1648,110 +1648,10 @@ Info seq [hh:mm:ss:mss] Files (3) /home/src/tslibs/TS/Lib/lib.d.ts Text-1 "/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ndeclare const console: { log(msg: any): void; };" /home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts Text-1 "export const x = 1;" /users/user/projects/project1/app.js SVC-1-0 "var x = require('bar');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project1/app.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project1", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project1/bower_components", - "/users/user/projects/project1/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project1/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery Info seq [hh:mm:ss:mss] Running: /users/user/projects/project2/jsconfig.json Info seq [hh:mm:ss:mss] Starting updateGraphWorker: Project: /users/user/projects/project2/jsconfig.json Info seq [hh:mm:ss:mss] ======== Resolving module 'bar' from '/users/user/projects/project2/app.js'. ======== @@ -1939,115 +1839,10 @@ Info seq [hh:mm:ss:mss] Files (5) /users/user/projects/project2/app.js SVC-1-0 "var x = require('bar');" /home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts Text-1 "export const foo = 1;" /users/user/projects/project2/app2.js Text-1 "var x = require('foo');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts - Imported via 'foo' from file 'app2.js' - app2.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project2/app.js", - "/users/user/projects/project2/app2.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project2", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project2/bower_components", - "/users/user/projects/project2/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project2/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 3 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typeAquisition/changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects.js b/tests/baselines/reference/tsserver/typeAquisition/changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects.js index d4120c30575..4fa125e47da 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects.js +++ b/tests/baselines/reference/tsserver/typeAquisition/changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects.js @@ -1702,112 +1702,10 @@ Info seq [hh:mm:ss:mss] Files (3) /home/src/tslibs/TS/Lib/lib.d.ts Text-1 "/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ndeclare const console: { log(msg: any): void; };" /home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts Text-1 "export const x = 1;" /users/user/projects/project1/app.js SVC-1-0 "var x = require('bar');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project1/app.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project1", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Searching for typing names in /users/user/projects/project1/node_modules; all files: [] -TI:: [hh:mm:ss:mss] Found package names: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project1/bower_components", - "/users/user/projects/project1/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project1/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery Info seq [hh:mm:ss:mss] Running: /users/user/projects/project2/jsconfig.json Info seq [hh:mm:ss:mss] Starting updateGraphWorker: Project: /users/user/projects/project2/jsconfig.json Info seq [hh:mm:ss:mss] ======== Resolving module 'bar' from '/users/user/projects/project2/app.js'. ======== @@ -1997,117 +1895,10 @@ Info seq [hh:mm:ss:mss] Files (5) /users/user/projects/project2/app.js SVC-1-0 "var x = require('bar');" /home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts Text-1 "export const foo = 1;" /users/user/projects/project2/app2.js Text-1 "var x = require('foo');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts - Imported via 'foo' from file 'app2.js' - app2.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project2/app.js", - "/users/user/projects/project2/app2.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project2", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Searching for typing names in /users/user/projects/project2/node_modules; all files: [] -TI:: [hh:mm:ss:mss] Found package names: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project2/bower_components", - "/users/user/projects/project2/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project2/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 3 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typeAquisition/changes-to-typeAquisition-when-typing-installer-installs-typing.js b/tests/baselines/reference/tsserver/typeAquisition/changes-to-typeAquisition-when-typing-installer-installs-typing.js index 39d12bef253..2cefac4713e 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/changes-to-typeAquisition-when-typing-installer-installs-typing.js +++ b/tests/baselines/reference/tsserver/typeAquisition/changes-to-typeAquisition-when-typing-installer-installs-typing.js @@ -717,112 +717,10 @@ Info seq [hh:mm:ss:mss] Files (3) /home/src/tslibs/TS/Lib/lib.d.ts Text-1 "/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ndeclare const console: { log(msg: any): void; };" /home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts Text-1 "export const x = 1;" /users/user/projects/project1/app.js SVC-1-0 "var x = require('bar');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project1/app.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project1", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Searching for typing names in /users/user/projects/project1/node_modules; all files: [] -TI:: [hh:mm:ss:mss] Found package names: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project1/bower_components", - "/users/user/projects/project1/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project1/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 2 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typeAquisition/disabled-typeAquisition-multiple-projects-with-shared-resolution.js b/tests/baselines/reference/tsserver/typeAquisition/disabled-typeAquisition-multiple-projects-with-shared-resolution.js index 087b67836aa..278a86a44bd 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/disabled-typeAquisition-multiple-projects-with-shared-resolution.js +++ b/tests/baselines/reference/tsserver/typeAquisition/disabled-typeAquisition-multiple-projects-with-shared-resolution.js @@ -1484,115 +1484,10 @@ Info seq [hh:mm:ss:mss] Files (5) /users/user/projects/project2/app.js SVC-1-0 "var x = require('bar');" /home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts Text-1 "export const foo = 1;" /users/user/projects/project2/app2.js Text-1 "var x = require('foo');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts - Imported via 'foo' from file 'app2.js' - app2.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project2/app.js", - "/users/user/projects/project2/app2.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project2", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project2/bower_components", - "/users/user/projects/project2/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project2/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 2 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typeAquisition/disabled-typeAquisition-multiple-projects.js b/tests/baselines/reference/tsserver/typeAquisition/disabled-typeAquisition-multiple-projects.js index 7bd810d8a4f..30d0d095b9a 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/disabled-typeAquisition-multiple-projects.js +++ b/tests/baselines/reference/tsserver/typeAquisition/disabled-typeAquisition-multiple-projects.js @@ -1542,117 +1542,10 @@ Info seq [hh:mm:ss:mss] Files (5) /users/user/projects/project2/app.js SVC-1-0 "var x = require('bar');" /home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts Text-1 "export const foo = 1;" /users/user/projects/project2/app2.js Text-1 "var x = require('foo');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts - Imported via 'foo' from file 'app2.js' - app2.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project2/app.js", - "/users/user/projects/project2/app2.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project2", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Searching for typing names in /users/user/projects/project2/node_modules; all files: [] -TI:: [hh:mm:ss:mss] Found package names: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project2/bower_components", - "/users/user/projects/project2/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project2/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 2 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typeAquisition/enabled-typeAquisition-multiple-projects-with-shared-resolution.js b/tests/baselines/reference/tsserver/typeAquisition/enabled-typeAquisition-multiple-projects-with-shared-resolution.js index fdc8760193a..88802a2601e 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/enabled-typeAquisition-multiple-projects-with-shared-resolution.js +++ b/tests/baselines/reference/tsserver/typeAquisition/enabled-typeAquisition-multiple-projects-with-shared-resolution.js @@ -1648,110 +1648,10 @@ Info seq [hh:mm:ss:mss] Files (3) /home/src/tslibs/TS/Lib/lib.d.ts Text-1 "/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ndeclare const console: { log(msg: any): void; };" /home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts Text-1 "export const x = 1;" /users/user/projects/project1/app.js SVC-1-0 "var x = require('bar');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project1/app.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project1", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project1/bower_components", - "/users/user/projects/project1/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project1/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery Info seq [hh:mm:ss:mss] Running: /users/user/projects/project2/jsconfig.json Info seq [hh:mm:ss:mss] Starting updateGraphWorker: Project: /users/user/projects/project2/jsconfig.json Info seq [hh:mm:ss:mss] ======== Resolving module 'bar' from '/users/user/projects/project2/app.js'. ======== @@ -1939,115 +1839,10 @@ Info seq [hh:mm:ss:mss] Files (5) /users/user/projects/project2/app.js SVC-1-0 "var x = require('bar');" /home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts Text-1 "export const foo = 1;" /users/user/projects/project2/app2.js Text-1 "var x = require('foo');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts - Imported via 'foo' from file 'app2.js' - app2.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project2/app.js", - "/users/user/projects/project2/app2.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project2", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project2/bower_components", - "/users/user/projects/project2/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project2/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 3 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typeAquisition/enabled-typeAquisition-multiple-projects.js b/tests/baselines/reference/tsserver/typeAquisition/enabled-typeAquisition-multiple-projects.js index a1a112d4efe..e03364456f9 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/enabled-typeAquisition-multiple-projects.js +++ b/tests/baselines/reference/tsserver/typeAquisition/enabled-typeAquisition-multiple-projects.js @@ -1702,112 +1702,10 @@ Info seq [hh:mm:ss:mss] Files (3) /home/src/tslibs/TS/Lib/lib.d.ts Text-1 "/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ndeclare const console: { log(msg: any): void; };" /home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts Text-1 "export const x = 1;" /users/user/projects/project1/app.js SVC-1-0 "var x = require('bar');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project1/app.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project1", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Searching for typing names in /users/user/projects/project1/node_modules; all files: [] -TI:: [hh:mm:ss:mss] Found package names: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project1/bower_components", - "/users/user/projects/project1/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project1/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery Info seq [hh:mm:ss:mss] Running: /users/user/projects/project2/jsconfig.json Info seq [hh:mm:ss:mss] Starting updateGraphWorker: Project: /users/user/projects/project2/jsconfig.json Info seq [hh:mm:ss:mss] ======== Resolving module 'bar' from '/users/user/projects/project2/app.js'. ======== @@ -1997,117 +1895,10 @@ Info seq [hh:mm:ss:mss] Files (5) /users/user/projects/project2/app.js SVC-1-0 "var x = require('bar');" /home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts Text-1 "export const foo = 1;" /users/user/projects/project2/app2.js Text-1 "var x = require('foo');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts - Imported via 'foo' from file 'app2.js' - app2.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project2/app.js", - "/users/user/projects/project2/app2.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project2", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Searching for typing names in /users/user/projects/project2/node_modules; all files: [] -TI:: [hh:mm:ss:mss] Found package names: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project2/bower_components", - "/users/user/projects/project2/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project2/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 3 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typeAquisition/enabled-typeAquisition.js b/tests/baselines/reference/tsserver/typeAquisition/enabled-typeAquisition.js index 348ecdb81ad..e10fc25e9e3 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/enabled-typeAquisition.js +++ b/tests/baselines/reference/tsserver/typeAquisition/enabled-typeAquisition.js @@ -717,112 +717,10 @@ Info seq [hh:mm:ss:mss] Files (3) /home/src/tslibs/TS/Lib/lib.d.ts Text-1 "/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ndeclare const console: { log(msg: any): void; };" /home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts Text-1 "export const x = 1;" /users/user/projects/project1/app.js SVC-1-0 "var x = require('bar');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project1/app.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project1", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Searching for typing names in /users/user/projects/project1/node_modules; all files: [] -TI:: [hh:mm:ss:mss] Found package names: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project1/bower_components", - "/users/user/projects/project1/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project1/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project1/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project1/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 2 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typeAquisition/midway-changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects-with-shared-resolution.js b/tests/baselines/reference/tsserver/typeAquisition/midway-changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects-with-shared-resolution.js index 1c2991c1e22..f0d3bb52bf3 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/midway-changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects-with-shared-resolution.js +++ b/tests/baselines/reference/tsserver/typeAquisition/midway-changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects-with-shared-resolution.js @@ -1705,115 +1705,10 @@ Info seq [hh:mm:ss:mss] Files (5) /users/user/projects/project2/app.js SVC-1-0 "var x = require('bar');" /home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts Text-1 "export const foo = 1;" /users/user/projects/project2/app2.js Text-1 "var x = require('foo');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts - Imported via 'foo' from file 'app2.js' - app2.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project2/app.js", - "/users/user/projects/project2/app2.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project2", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project2/bower_components", - "/users/user/projects/project2/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project2/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery Info seq [hh:mm:ss:mss] Running: /users/user/projects/project1/jsconfig.json Info seq [hh:mm:ss:mss] event: { diff --git a/tests/baselines/reference/tsserver/typeAquisition/midway-changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects.js b/tests/baselines/reference/tsserver/typeAquisition/midway-changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects.js index 98c498416b9..4380d5e81cb 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/midway-changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects.js +++ b/tests/baselines/reference/tsserver/typeAquisition/midway-changes-to-typeAquisition-when-typing-installer-installs-typing-multiple-projects.js @@ -1759,117 +1759,10 @@ Info seq [hh:mm:ss:mss] Files (5) /users/user/projects/project2/app.js SVC-1-0 "var x = require('bar');" /home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts Text-1 "export const foo = 1;" /users/user/projects/project2/app2.js Text-1 "var x = require('foo');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts - Imported via 'foo' from file 'app2.js' - app2.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project2/app.js", - "/users/user/projects/project2/app2.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project2", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Searching for typing names in /users/user/projects/project2/node_modules; all files: [] -TI:: [hh:mm:ss:mss] Found package names: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project2/bower_components", - "/users/user/projects/project2/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project2/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery Info seq [hh:mm:ss:mss] Running: /users/user/projects/project1/jsconfig.json Info seq [hh:mm:ss:mss] event: { diff --git a/tests/baselines/reference/tsserver/typeAquisition/receives-update-of-typings-after-project-changes-multiple-projects-with-shared-resolution.js b/tests/baselines/reference/tsserver/typeAquisition/receives-update-of-typings-after-project-changes-multiple-projects-with-shared-resolution.js index d5e9d879051..ec974fe0fdb 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/receives-update-of-typings-after-project-changes-multiple-projects-with-shared-resolution.js +++ b/tests/baselines/reference/tsserver/typeAquisition/receives-update-of-typings-after-project-changes-multiple-projects-with-shared-resolution.js @@ -1903,115 +1903,10 @@ Info seq [hh:mm:ss:mss] Files (5) /users/user/projects/project2/app.js SVC-1-0 "var x = require('bar');" /home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts Text-1 "export const foo = 1;" /users/user/projects/project2/app2.js Text-1 "var x = require('foo');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts - Imported via 'foo' from file 'app2.js' - app2.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project2/app.js", - "/users/user/projects/project2/app2.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project2", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project2/bower_components", - "/users/user/projects/project2/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project2/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 2 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typeAquisition/receives-update-of-typings-after-project-changes-multiple-projects.js b/tests/baselines/reference/tsserver/typeAquisition/receives-update-of-typings-after-project-changes-multiple-projects.js index c52056f92a9..83ce791409e 100644 --- a/tests/baselines/reference/tsserver/typeAquisition/receives-update-of-typings-after-project-changes-multiple-projects.js +++ b/tests/baselines/reference/tsserver/typeAquisition/receives-update-of-typings-after-project-changes-multiple-projects.js @@ -1958,117 +1958,10 @@ Info seq [hh:mm:ss:mss] Files (5) /users/user/projects/project2/app.js SVC-1-0 "var x = require('bar');" /home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts Text-1 "export const foo = 1;" /users/user/projects/project2/app2.js Text-1 "var x = require('foo');" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/bar/index.d.ts - Imported via 'bar' from file 'app.js' - app.js - Matched by default include pattern '**/*' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/foo/index.d.ts - Imported via 'foo' from file 'app2.js' - app2.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 5 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/users/user/projects/project2/app.js", - "/users/user/projects/project2/app2.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/users/user/projects/project2", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Searching for typing names in /users/user/projects/project2/node_modules; all files: [] -TI:: [hh:mm:ss:mss] Found package names: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/users/user/projects/project2/bower_components", - "/users/user/projects/project2/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/users/user/projects/project2/jsconfig.json" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/users/user/projects/project2/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "traceResolution": true, - "configFilePath": "/users/user/projects/project2/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 2 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typingsInstaller/discover-from-node_modules-empty-types-has-import.js b/tests/baselines/reference/tsserver/typingsInstaller/discover-from-node_modules-empty-types-has-import.js index 9e9813952e2..b0ee75af892 100644 --- a/tests/baselines/reference/tsserver/typingsInstaller/discover-from-node_modules-empty-types-has-import.js +++ b/tests/baselines/reference/tsserver/typingsInstaller/discover-from-node_modules-empty-types-has-import.js @@ -638,104 +638,10 @@ Info seq [hh:mm:ss:mss] Files (3) /home/src/tslibs/TS/Lib/lib.d.ts Text-1 "/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ndeclare const console: { log(msg: any): void; };" /home/src/Library/Caches/typescript/node_modules/@types/jquery/index.d.ts Text-1 "" /user/username/projects/project/app.js SVC-1-0 "import \"jquery\";" - - - ../../../../home/src/tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../../../home/src/Library/Caches/typescript/node_modules/@types/jquery/index.d.ts - Imported via "jquery" from file 'app.js' - app.js - Matched by default include pattern '**/*' Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/user/username/projects/project/jsconfig.json", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/user/username/projects/project/app.js" - ], - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "types": [], - "configFilePath": "/user/username/projects/project/jsconfig.json", - "allowNonTsExtensions": true - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/user/username/projects/project", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [] - } -TI:: [hh:mm:ss:mss] Closing file watchers for project '/user/username/projects/project/jsconfig.json' -TI:: [hh:mm:ss:mss] No watchers are registered for project '/user/username/projects/project/jsconfig.json' -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/user/username/projects/project/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "types": [], - "configFilePath": "/user/username/projects/project/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/user/username/projects/project/jsconfig.json", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "allowJs": true, - "maxNodeModuleJsDepth": 2, - "allowSyntheticDefaultImports": true, - "skipLibCheck": true, - "noEmit": true, - "types": [], - "configFilePath": "/user/username/projects/project/jsconfig.json", - "allowNonTsExtensions": true - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery After running Timeout callback:: count: 2 PolledWatches:: diff --git a/tests/baselines/reference/tsserver/typingsInstaller/install-typings-for-unresolved-imports.js b/tests/baselines/reference/tsserver/typingsInstaller/install-typings-for-unresolved-imports.js index 1a658bd1cc4..c0843f08869 100644 --- a/tests/baselines/reference/tsserver/typingsInstaller/install-typings-for-unresolved-imports.js +++ b/tests/baselines/reference/tsserver/typingsInstaller/install-typings-for-unresolved-imports.js @@ -583,14 +583,16 @@ Projects:: ScriptInfos:: /home/src/Library/Caches/typescript/node_modules/@types/commander/index.d.ts *new* version: Text-1 - containingProjects: 0 + containingProjects: 1 + /dev/null/inferredProject1* /home/src/Library/Caches/typescript/node_modules/@types/ember__component/index.d.ts *new* version: Text-1 containingProjects: 1 /dev/null/inferredProject1* /home/src/Library/Caches/typescript/node_modules/@types/node/index.d.ts *new* version: Text-1 - containingProjects: 0 + containingProjects: 1 + /dev/null/inferredProject1* /home/src/projects/project/app.js (Open) version: SVC-1-0 containingProjects: 1 diff --git a/tests/baselines/reference/tsserver/typingsInstaller/invalidate-the-resolutions-with-trimmed-names.js b/tests/baselines/reference/tsserver/typingsInstaller/invalidate-the-resolutions-with-trimmed-names.js index ad045af607f..bdffc6cdf98 100644 --- a/tests/baselines/reference/tsserver/typingsInstaller/invalidate-the-resolutions-with-trimmed-names.js +++ b/tests/baselines/reference/tsserver/typingsInstaller/invalidate-the-resolutions-with-trimmed-names.js @@ -624,7 +624,8 @@ ScriptInfos:: /dev/null/inferredProject1* /home/src/Library/Caches/typescript/node_modules/foo/index.d.ts *new* version: Text-1 - containingProjects: 0 + containingProjects: 1 + /dev/null/inferredProject1* /home/src/projects/project/app.js (Open) version: SVC-1-0 containingProjects: 1 @@ -768,6 +769,36 @@ Projects:: projectProgramVersion: 3 *changed* dirty: false *changed* +ScriptInfos:: +/home/src/Library/Caches/typescript/node_modules/foo/a/a.d.ts + version: Text-1 + containingProjects: 1 + /dev/null/inferredProject1* +/home/src/Library/Caches/typescript/node_modules/foo/a/b.d.ts + version: Text-1 + containingProjects: 1 + /dev/null/inferredProject1* +/home/src/Library/Caches/typescript/node_modules/foo/a/c.d.ts + version: Text-1 + containingProjects: 1 + /dev/null/inferredProject1* +/home/src/Library/Caches/typescript/node_modules/foo/index.d.ts *changed* + version: Text-1 + containingProjects: 0 *changed* + /dev/null/inferredProject1* *deleted* +/home/src/projects/project/app.js (Open) + version: SVC-1-0 + containingProjects: 1 + /dev/null/inferredProject1* *default* +/home/src/projects/project/node_modules/fooo/index.d.ts + version: Text-1 + containingProjects: 1 + /dev/null/inferredProject1* +/home/src/tslibs/TS/Lib/lib.d.ts + version: Text-1 + containingProjects: 1 + /dev/null/inferredProject1* + Info seq [hh:mm:ss:mss] request: { "command": "applyChangedToOpenFiles", diff --git a/tests/baselines/reference/tsserver/typingsInstaller/invalidate-the-resolutions.js b/tests/baselines/reference/tsserver/typingsInstaller/invalidate-the-resolutions.js index c26767732f5..997bf6bb9d9 100644 --- a/tests/baselines/reference/tsserver/typingsInstaller/invalidate-the-resolutions.js +++ b/tests/baselines/reference/tsserver/typingsInstaller/invalidate-the-resolutions.js @@ -585,7 +585,8 @@ Projects:: ScriptInfos:: /home/src/Library/Caches/typescript/node_modules/foo/index.d.ts *new* version: Text-1 - containingProjects: 0 + containingProjects: 1 + /dev/null/inferredProject1* /home/src/projects/project/app.js (Open) version: SVC-1-0 containingProjects: 1 @@ -607,108 +608,10 @@ Info seq [hh:mm:ss:mss] Files (4) /home/src/Library/Caches/typescript/node_modules/foo/index.d.ts Text-1 "export function a(): void;" /home/src/projects/project/node_modules/fooo/index.d.ts Text-1 "export var x: string;" /home/src/projects/project/app.js SVC-1-0 "import * as a from \"foo\";import * as x from \"fooo\";" - - - ../../tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../Library/Caches/typescript/node_modules/foo/index.d.ts - Imported via "foo" from file 'app.js' - node_modules/fooo/index.d.ts - Imported via "fooo" from file 'app.js' - app.js - Root file specified for compilation Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 4 Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 4 Done: [] -TI:: [hh:mm:ss:mss] Got install request - { - "projectName": "/dev/null/inferredProject1*", - "fileNames": [ - "/home/src/tslibs/TS/Lib/lib.d.ts", - "/home/src/projects/project/app.js" - ], - "compilerOptions": { - "target": 1, - "jsx": 1, - "allowNonTsExtensions": true, - "allowJs": true, - "noEmitForJsFiles": true, - "maxNodeModuleJsDepth": 2 - }, - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "unresolvedImports": [], - "projectRootPath": "/home/src/projects/project", - "kind": "discover" - } -TI:: [hh:mm:ss:mss] Explicitly included types: [] -TI:: [hh:mm:ss:mss] Searching for typing names in /home/src/projects/project/node_modules; all files: [] -TI:: [hh:mm:ss:mss] Found package names: [] -TI:: [hh:mm:ss:mss] Inferred typings from unresolved imports: [] -TI:: [hh:mm:ss:mss] Finished typings discovery: - { - "cachedTypingPaths": [], - "newTypingNames": [], - "filesToWatch": [ - "/home/src/projects/project/bower_components", - "/home/src/projects/project/node_modules" - ] - } -TI:: [hh:mm:ss:mss] Sending response: - { - "kind": "action::watchTypingLocations", - "projectName": "/dev/null/inferredProject1*" - } -TI:: [hh:mm:ss:mss] Sending response: - { - "projectName": "/dev/null/inferredProject1*", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "target": 1, - "jsx": 1, - "allowNonTsExtensions": true, - "allowJs": true, - "noEmitForJsFiles": true, - "maxNodeModuleJsDepth": 2 - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } -Info seq [hh:mm:ss:mss] event: - { - "seq": 0, - "type": "event", - "event": "setTypings", - "body": { - "projectName": "/dev/null/inferredProject1*", - "typeAcquisition": { - "enable": true, - "include": [], - "exclude": [] - }, - "compilerOptions": { - "target": 1, - "jsx": 1, - "allowNonTsExtensions": true, - "allowJs": true, - "noEmitForJsFiles": true, - "maxNodeModuleJsDepth": 2 - }, - "typings": [], - "unresolvedImports": [], - "kind": "action::set" - } - } -TI:: [hh:mm:ss:mss] No new typings were requested as a result of typings discovery Info seq [hh:mm:ss:mss] Resolution from : /home/src/projects/project/app.js for "fooo" goes to: { "resolvedFileName": "/home/src/projects/project/node_modules/fooo/index.d.ts", "extension": ".d.ts", @@ -723,24 +626,6 @@ Projects:: projectProgramVersion: 3 *changed* dirty: false *changed* -ScriptInfos:: -/home/src/Library/Caches/typescript/node_modules/foo/index.d.ts *changed* - version: Text-1 - containingProjects: 1 *changed* - /dev/null/inferredProject1* *new* -/home/src/projects/project/app.js (Open) - version: SVC-1-0 - containingProjects: 1 - /dev/null/inferredProject1* *default* -/home/src/projects/project/node_modules/fooo/index.d.ts - version: Text-1 - containingProjects: 1 - /dev/null/inferredProject1* -/home/src/tslibs/TS/Lib/lib.d.ts - version: Text-1 - containingProjects: 1 - /dev/null/inferredProject1* - Info seq [hh:mm:ss:mss] request: { "command": "applyChangedToOpenFiles", diff --git a/tests/baselines/reference/tsserver/typingsInstaller/redo-resolutions-pointing-to-js-on-typing-install.js b/tests/baselines/reference/tsserver/typingsInstaller/redo-resolutions-pointing-to-js-on-typing-install.js index 9f1ced45f16..79e670c3109 100644 --- a/tests/baselines/reference/tsserver/typingsInstaller/redo-resolutions-pointing-to-js-on-typing-install.js +++ b/tests/baselines/reference/tsserver/typingsInstaller/redo-resolutions-pointing-to-js-on-typing-install.js @@ -604,7 +604,8 @@ Projects:: ScriptInfos:: /home/src/Library/Caches/typescript/node_modules/@types/commander/index.d.ts *new* version: Text-1 - containingProjects: 0 + containingProjects: 1 + /dev/null/inferredProject1* /home/src/tslibs/TS/Lib/lib.d.ts version: Text-1 containingProjects: 1 diff --git a/tests/baselines/reference/tsserver/typingsInstaller/should-handle-node-core-modules.js b/tests/baselines/reference/tsserver/typingsInstaller/should-handle-node-core-modules.js index 2d667472191..364875cf5e8 100644 --- a/tests/baselines/reference/tsserver/typingsInstaller/should-handle-node-core-modules.js +++ b/tests/baselines/reference/tsserver/typingsInstaller/should-handle-node-core-modules.js @@ -540,7 +540,8 @@ Projects:: ScriptInfos:: /home/src/Library/Caches/typescript/node_modules/node/index.d.ts *new* version: Text-1 - containingProjects: 0 + containingProjects: 1 + /dev/null/inferredProject1* /home/src/projects/project/app.js (Open) version: SVC-1-0 containingProjects: 1 @@ -584,7 +585,8 @@ After request ScriptInfos:: /home/src/Library/Caches/typescript/node_modules/node/index.d.ts version: Text-1 - containingProjects: 0 + containingProjects: 1 + /dev/null/inferredProject1* /home/src/projects/project/app.js (Open) *changed* version: SVC-1-1 *changed* containingProjects: 1 @@ -606,14 +608,6 @@ Info seq [hh:mm:ss:mss] Files (3) /home/src/tslibs/TS/Lib/lib.d.ts Text-1 "/// \ninterface Boolean {}\ninterface Function {}\ninterface CallableFunction {}\ninterface NewableFunction {}\ninterface IArguments {}\ninterface Number { toExponential: any; }\ninterface Object {}\ninterface RegExp {}\ninterface String { charAt: any; }\ninterface Array { length: number; [n: number]: T; }\ninterface ReadonlyArray {}\ndeclare const console: { log(msg: any): void; };" /home/src/Library/Caches/typescript/node_modules/node/index.d.ts Text-1 "\ndeclare module \"net\" {\n export type n = number;\n}\ndeclare module \"stream\" {\n export type s = string;\n}" /home/src/projects/project/app.js SVC-1-1 "// @ts-check\n\nconst net = require(\"net\");\nconst stream = require(\"s tream\");" - - - ../../tslibs/TS/Lib/lib.d.ts - Default library for target 'es5' - ../../Library/Caches/typescript/node_modules/node/index.d.ts - Imported via "net" from file 'app.js' - app.js - Root file specified for compilation Info seq [hh:mm:ss:mss] ----------------------------------------------- Info seq [hh:mm:ss:mss] getUnresolvedImports:: Files:: 3 @@ -752,20 +746,6 @@ Projects:: projectProgramVersion: 3 *changed* dirty: false *changed* -ScriptInfos:: -/home/src/Library/Caches/typescript/node_modules/node/index.d.ts *changed* - version: Text-1 - containingProjects: 1 *changed* - /dev/null/inferredProject1* *new* -/home/src/projects/project/app.js (Open) - version: SVC-1-1 - containingProjects: 1 - /dev/null/inferredProject1* *default* -/home/src/tslibs/TS/Lib/lib.d.ts - version: Text-1 - containingProjects: 1 - /dev/null/inferredProject1* - Before request Info seq [hh:mm:ss:mss] request: