-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
TypeScript language service crashes on projects on a mounted SharePoint WebDav folder #7469
Comments
Can you provide some more information about your project setup, what kind of project? What is your |
From @jandersonfcosta on March 8, 2016 15:56 Hi egamma, Note: For css, js and html files, intellisense is working normal. So intellisense is lost. Before it worked. |
I suspect you run out of memory because you do not exclude some of the folders in the project in the jsconfig.json. Therefore Does your project include a If it doesn't have a jsconfig.json, can you create one following the migration guide: In the past Code excluded some folders automatically, this is not done automatically anymore and you need to define the exclude folders in the jsconfig.json. |
From @jandersonfcosta on March 8, 2016 17:7 My project not include a jsconfig.json Note: For css, json and html files, intellisense is working normal. |
JavaScript is more complex than css, html, and json, therefore a complex project needs a jsconfig.json. In the past we have automatically excluded some folders from being analyzed we no longer do this and for this reason you now need a jsconfig.json file.
|
From @jandersonfcosta on March 8, 2016 17:41 Did not work |
Can you pls sketch the folder structure (as is done here microsoft/vscode#3791 (comment)) of your project and include the jsconfig.json you are using? Without some more information we cannot track this down. |
From @lukkarip on March 10, 2016 8:8 The workflow to work with SharePoint Javascript, CSS, MasterPage, PageLayouts etc. is to map folder [site]/_catalogs/masterpage and work with this mapped folder. The problem is that by default you can't include json files (http://sharepoint.stackexchange.com/questions/114540/why-is-upload-of-json-files-prohibited) :) So way to work with Visual Studio Code is to reference Typescript definitions by adding references to code pages "manually". So, after Visual Studio Code 0.10.10 update, opening any javascript file now gives error "The Typescript language service died unexpectedly 5 times in the last 5 Minutes. Please consider to open a bug report." again and again. |
@lukkarip thanks for explaining the workflow and setup. I assume this is a larger folder with many JS files? Previously, the JavaScript infrastructure has excluded some well known folders: Can you confirm that this is the case. I'm sorry that adding a jsconfig.json is not a solution for your setup. |
From @lukkarip on March 10, 2016 9:42 I made a quick test to demonstrate the problem. I created just one javascript file, which contains no reference to anything, just couple of lines some javascript. I put this one file in "testing" folder under [site]/_catalogs/masterpage. This is done by mapping network drive (WebDAV). This is SharePoint 2013. In Visual Studio Code (0.10.10) I select only to open this "testing" folder with one js file. When opened Visual Studio Code starts to give warning "The Typescript language service died unexpectedly 5 times in the last 5 Minutes. Please consider to open a bug report." again and again. So in practise, Visual Studio Code cannot be used with SharePoint 2013 at the moment. Needed to change to SublimeText for now. Hope some fix is goming soon. I have admin rights so seems that I was able to .json-format from "not allowed files" in SharePoint Central Admin. With this change. I can in fact add json-file. The problem is in this my test case there seems to be anything that could be excluded(?) |
Can you reproduce this when you work on a local folder with the same file? |
Can you share this one js file? |
From @lukkarip on March 10, 2016 10:14 Same "testing"-folder with this one file works fine locally. The problem is only if opened in SharePoint 2013 mapped folder. Test file is really uninteresting random javascript, but here it is: https://github.com/lukkarip/Tests/blob/master/testing/session-handler.js |
@bpasero can you please add your insights on the node issue that causes this and then move it to the TypeScript repository. |
From @bpasero on March 10, 2016 17:18 The node issue is: nodejs/node#4002 @egamma I am not sure how to move the issue, so I give it back to you to decide if this one should stay open as tracking bug or not. |
From @bpasero on March 10, 2016 17:19 And our workaround for the bug is in: https://github.com/Microsoft/vscode/blob/master/src/vs/base/node/extfs.ts#L48 |
@bpasero thanks. This is a regression for SharePoint users using code. The previous JS implementation profited from the fix described above. Therefore suggest to consider it for TS 1.8.9 if possible. |
This could also be related to #7420 , where file watchers cause issues if not a local drive. |
@jandersonfcosta The fix was merged in master, can you confirm it with your project? You can clone master and build locally, or wait for a day to use the next nightly build on npm (at least version "typescript@1.9.0-dev.20160325") |
With the latest change of returning polling file watchers, this should be fixed. |
This started reoccuring for me on the most recent vs code update. WebDav on SharePoint. We see it's traversing the webdav folder for tsconfig.json & jsconfig.json while issuing a warning in the editor that the TypeScript language service has crashed 5 times in the last 5 seconds. |
@cverhelst can you please log a new issue and give us more information about which versions you are using and a repro project that can help us diagnose the issue. |
@mhegazy It's fixed in the latest patch, thanks! microsoft/vscode#17345 |
From @jandersonfcosta on March 8, 2016 15:31
After update VSC to 0.10.10, javascript intellisense stop working.
VSC show warn message: "The Typescript language service died unexpectedly 5 times in the last 5 Minutes. Please consider to open a bug report."
Any idea?
Thank you!
Copied from original issue: microsoft/vscode#3860
The text was updated successfully, but these errors were encountered: