-
Notifications
You must be signed in to change notification settings - Fork 770
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
[READY] Support TypeScript 2.6.1 #869
Conversation
TBH i'd rather just restrict the version of tsserver that we use and point people having the issue at the bug, but we would at least have to fix the other part (about goto). Are we certain that the npm messages will only appear during header parsing ? The code for parsing message body isn't very robust either, but is it possible for the npm message to appear after a valid I would be surprised if it is, or if we should even worry about it, but thought i'd ask anyway. assuming that and that the tests finally pass :) Reviewed 2 of 2 files at r1. Comments from Reviewable |
Codecov Report
@@ Coverage Diff @@
## master #869 +/- ##
=========================================
- Coverage 94.77% 94.7% -0.07%
=========================================
Files 79 79
Lines 5435 5440 +5
Branches 171 171
=========================================
+ Hits 5151 5152 +1
- Misses 235 239 +4
Partials 49 49 |
This is my concern too. If we can't be certain we better restrict tsserver version. Review status: all files reviewed at latest revision, all discussions resolved, some commit checks failed. Comments from Reviewable |
Looking at TSServer code, the whole response is written at once on stdout (see Review status: all files reviewed at latest revision, all discussions resolved, some commit checks failed. Comments from Reviewable |
Shall we ship it then? Fire when ready! Review status: all files reviewed at latest revision, all discussions resolved, some commit checks failed. Comments from Reviewable |
@zzbot r+ Reviewed 2 of 2 files at r1. Comments from Reviewable |
📌 Commit 5f98ed4 has been approved by |
[READY] Support TypeScript 2.6.1 TypeScript 2.6.1 introduced a bug in TSServer where NPM warnings are printed on stdout at startup: ``` npm WARN 2.6 No description npm WARN 2.6 No repository field. npm WARN 2.6 No license field. ``` See issue microsoft/TypeScript#19660. The TypeScript completer chokes on this output as it always expects a HTTP-like response from TSServer and assumes that the server died if not. Though it's a TSServer bug, we can handle it by catching the `ValueError` exception raised when parsing invalid headers and by interrupting the reader loop only if the server is not running. Also, this new version of TypeScript returns an empty list when no definition is found. Update the `_GoToDefinition` and `_GoToType` functions accordingly. Fixes ycm-core/YouCompleteMe#2818. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/valloric/ycmd/869) <!-- Reviewable:end -->
☀️ Test successful - status-appveyor, status-travis |
[READY] Update ycmd Include the following changes: - PR ycm-core/ycmd#856: update JediHTTP; - PR ycm-core/ycmd#860: improve diagnostics location in C-family languages; - PR ycm-core/ycmd#865: use Objective-C triggers for Objective-C++; - PR ycm-core/ycmd#869: support TypeScript 2.6.1; - PR ycm-core/ycmd#875: allow switching to a different JavaScript project with `RestartServer`; - PR ycm-core/ycmd#877: support `-idirafter` include flag in C-family languages. Update the JavaScript documentation on how to switch to a different project. We only mention the `:YcmCompleter RestartServer` way as other methods involve restarting ycmd and losing all its data like stored identifiers. <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/valloric/youcompleteme/2839) <!-- Reviewable:end -->
Include the following changes: - PR ycm-core/ycmd#856: update JediHTTP; - PR ycm-core/ycmd#860: improve diagnostics location in C-family languages; - PR ycm-core/ycmd#865: use Objective-C triggers for Objective-C++; - PR ycm-core/ycmd#869: support TypeScript 2.6.1; - PR ycm-core/ycmd#875: allow switching to a different JavaScript project with `RestartServer`; - PR ycm-core/ycmd#877: support `-idirafter` include flag in C-family languages.
TypeScript 2.6.1 introduced a bug in TSServer where NPM warnings are printed on stdout at startup:
See issue microsoft/TypeScript#19660. The TypeScript completer chokes on this output as it always expects a HTTP-like response from TSServer and assumes that the server died if not. Though it's a TSServer bug, we can handle it by catching the
ValueError
exception raised when parsing invalid headers and by interrupting the reader loop only if the server is not running.Also, this new version of TypeScript returns an empty list when no definition is found. Update the
_GoToDefinition
and_GoToType
functions accordingly.Fixes ycm-core/YouCompleteMe#2818.
This change is