Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TS error stays around #12798

Closed
chrmarti opened this issue Sep 27, 2016 · 7 comments
Closed

TS error stays around #12798

chrmarti opened this issue Sep 27, 2016 · 7 comments
Assignees
Labels
typescript Typescript support issues upstream Issue identified as 'upstream' component related (exists outside of VS Code)
Milestone

Comments

@chrmarti
Copy link
Collaborator

  • VSCode Version: Code - Insiders 1.6.0-insider (f62883f, 2016-09-27T12:46:15.113Z)
  • OS Version: Darwin x64 15.6.0

Testing #12633

Steps to Reproduce:

  1. Rename file referenced by other file
  2. Other file shows error
  3. Rename first file back
  4. Unexpected: Error stays

ts-compile-error-stays-around

[Info - 10:32:20 AM] Using tsserver from location: /Applications/Visual Studio Code - Insiders.app/Contents/Resources/app/extensions/typescript/server/typescript/lib/tsserver.js
[Trace - 10:32:20 AM] Sending request: open (0). Response expected: no. Current queue length: 0
Arguments: {
"file": "/Users/chrmarti/Development/repos/ts203/app.ts",
"fileContent": "import * as bar from './bar';\n\nbar.boo();\n"
}
[Trace - 10:32:20 AM] Sending request: open (1). Response expected: no. Current queue length: 0
Arguments: {
"file": "/Users/chrmarti/Development/repos/ts203/bar.ts",
"fileContent": "export function boo() {\n console.log('boo');\n}\n"
}
[Trace - 10:32:20 AM] Sending request: geterr (2). Response expected: no. Current queue length: 0
Arguments: {
"delay": 0,
"files": [
"/Users/chrmarti/Development/repos/ts203/app.ts",
"/Users/chrmarti/Development/repos/ts203/bar.ts"
]
}
[Trace - 10:32:21 AM] Event received: syntaxDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/app.ts",
"diagnostics": []
}
[Trace - 10:32:21 AM] Event received: semanticDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/app.ts",
"diagnostics": []
}
[Trace - 10:32:21 AM] Event received: syntaxDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/bar.ts",
"diagnostics": []
}
[Trace - 10:32:21 AM] Event received: semanticDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/bar.ts",
"diagnostics": []
}
[Trace - 10:33:42 AM] Sending request: open (3). Response expected: no. Current queue length: 0
Arguments: {
"file": "/Users/chrmarti/Development/repos/ts203/boo.ts",
"fileContent": "export function boo() {\n console.log('boo');\n}\n"
}
[Trace - 10:33:42 AM] Sending request: close (4). Response expected: no. Current queue length: 0
Arguments: {
"file": "/Users/chrmarti/Development/repos/ts203/bar.ts"
}
[Trace - 10:33:42 AM] Sending request: geterr (5). Response expected: no. Current queue length: 0
Arguments: {
"delay": 0,
"files": [
"/Users/chrmarti/Development/repos/ts203/boo.ts",
"/Users/chrmarti/Development/repos/ts203/app.ts"
]
}
[Trace - 10:33:42 AM] Event received: syntaxDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/boo.ts",
"diagnostics": []
}
[Trace - 10:33:42 AM] Event received: semanticDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/boo.ts",
"diagnostics": []
}
[Trace - 10:33:42 AM] Event received: syntaxDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/app.ts",
"diagnostics": []
}
[Trace - 10:33:42 AM] Event received: semanticDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/app.ts",
"diagnostics": [
{
"start": {
"line": 1,
"offset": 22
},
"end": {
"line": 1,
"offset": 29
},
"text": "File '/Users/chrmarti/Development/repos/ts203/bar.ts' is not a module."
}
]
}
[Trace - 10:33:43 AM] Event received: syntaxDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/boo.ts",
"diagnostics": []
}
[Trace - 10:33:43 AM] Event received: semanticDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/boo.ts",
"diagnostics": []
}
[Trace - 10:33:48 AM] Sending request: open (6). Response expected: no. Current queue length: 0
Arguments: {
"file": "/Users/chrmarti/Development/repos/ts203/bar.ts",
"fileContent": "export function boo() {\n console.log('boo');\n}\n"
}
[Trace - 10:33:48 AM] Sending request: close (7). Response expected: no. Current queue length: 0
Arguments: {
"file": "/Users/chrmarti/Development/repos/ts203/boo.ts"
}
[Trace - 10:33:48 AM] Sending request: geterr (8). Response expected: no. Current queue length: 0
Arguments: {
"delay": 0,
"files": [
"/Users/chrmarti/Development/repos/ts203/bar.ts",
"/Users/chrmarti/Development/repos/ts203/app.ts"
]
}
[Trace - 10:33:48 AM] Event received: syntaxDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/bar.ts",
"diagnostics": []
}
[Trace - 10:33:48 AM] Event received: semanticDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/bar.ts",
"diagnostics": []
}
[Trace - 10:33:48 AM] Event received: syntaxDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/app.ts",
"diagnostics": []
}
[Trace - 10:33:48 AM] Event received: semanticDiag (0).
Data: {
"file": "/Users/chrmarti/Development/repos/ts203/app.ts",
"diagnostics": [
{
"start": {
"line": 1,
"offset": 22
},
"end": {
"line": 1,
"offset": 29
},
"text": "Cannot find module './bar'."
}
]
}

@dbaeumer
Copy link
Member

I will investigate, but the trace shows that an error is still reported by the tsserver. There is little we can do if this is the case.

@dbaeumer dbaeumer added this to the September 2016 milestone Sep 28, 2016
@dbaeumer dbaeumer added typescript Typescript support issues bug Issue identified by VS Code Team member as probable bug labels Sep 28, 2016
@dbaeumer
Copy link
Member

dbaeumer commented Sep 28, 2016

OK. The problem was that I still called realpath however the workbench and other parts didn't. After fixing this renaming back and forth works.

cast

@chrmarti can you please verify on Mac.

@dbaeumer
Copy link
Member

Reopening the issue. Even with the fix I can still reproduce this under Mac. TS bug to track: microsoft/TypeScript#11206

@dbaeumer
Copy link
Member

dbaeumer commented Sep 28, 2016

However Windows looks good if both files are open. If only app.ts is open and bar.ts is renamed then things fail as well.

@dbaeumer
Copy link
Member

This is getting more wired. Now I can reproduce this on Windows as well.

dbaeumer added a commit that referenced this issue Sep 28, 2016
@waderyan waderyan added the info-needed Issue requires more information from poster label Sep 28, 2016
@dbaeumer dbaeumer modified the milestones: October 2016, September 2016 Sep 29, 2016
@dbaeumer
Copy link
Member

Moving to October. There is nothing I can do today. More fixing requires a TS update.

@waderyan waderyan removed their assignment Sep 29, 2016
@dbaeumer
Copy link
Member

This got fixed with the latest upgrade to TS 2.0.6 were we now use one inferred project.

@dbaeumer dbaeumer added upstream Issue identified as 'upstream' component related (exists outside of VS Code) and removed bug Issue identified by VS Code Team member as probable bug info-needed Issue requires more information from poster labels Oct 26, 2016
@vscodebot vscodebot bot locked and limited conversation to collaborators Nov 18, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
typescript Typescript support issues upstream Issue identified as 'upstream' component related (exists outside of VS Code)
Projects
None yet
Development

No branches or pull requests

3 participants