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

tsserver picks up interlocking files created by emacs #320

Open
ananthakumaran opened this issue Jun 8, 2019 · 0 comments
Open

tsserver picks up interlocking files created by emacs #320

ananthakumaran opened this issue Jun 8, 2019 · 0 comments

Comments

@ananthakumaran
Copy link
Owner

ananthakumaran commented Jun 8, 2019

Last week I started to work on a prototype typescript project (It's been some time since I have used typescript/tide for professional work). The editor was really sluggish for some reason, though things were working fine. I started to look at the log file, there was too much activity going on for some reason. Each save triggered a full project reload. After some digging, it looks like the interlocking files created by emacs (filename starts with .#) is picked by tsserver and it seems to cause a full project reload in the backend. Some of the related logs can be found below.

If I disable interlocking via (setq create-lockfiles nil), all of this grinding stops. I don't remember this happening in the past. I am not sure if this is a recent change. We need to disable this by default. How we do it is still a question.

Info 2549 [10:35:12.752] DirectoryWatcher:: Triggered with [removed]/src/.#field.ts :: WatchInfo: [removed]/src 1 Project: [removed]/tsconfig.json WatchType: Wild card directory
Info 2550 [10:35:12.753] Scheduled: [removed]/tsconfig.json
Info 2551 [10:35:12.753] Scheduled: *ensureProjectForOpenFiles*
Info 2552 [10:35:12.753] Elapsed:: 0ms DirectoryWatcher:: Triggered with [removed]/src/.#field.ts :: WatchInfo: [removed]/src 1 Project: [removed]/tsconfig.json WatchType: Wild card directory
Info 2553 [10:35:12.753] DirectoryWatcher:: Triggered with [removed]/src/.#field.ts :: WatchInfo: [removed]/src 1 Project: [removed]/tsconfig.json WatchType: Failed Lookup Locations
Info 2554 [10:35:12.753] Scheduled: [removed]/tsconfig.json, Cancelled earlier one
Info 2555 [10:35:12.753] Scheduled: *ensureProjectForOpenFiles*, Cancelled earlier one
Info 2556 [10:35:12.753] Elapsed:: 0ms DirectoryWatcher:: Triggered with [removed]/src/.#field.ts :: WatchInfo: [removed]/src 1 Project: [removed]/tsconfig.json WatchType: Failed Lookup Locations
Info 2557 [10:35:12.753] request:
    {"command":"syntacticDiagnosticsSync","seq":"8513","arguments":{"file":"[removed]/src/field.ts"}}
Info 2558 [10:35:12.757] Starting updateGraphWorker: Project: [removed]/tsconfig.json
Info 2559 [10:35:13.539] Finishing updateGraphWorker: Project: [removed]/tsconfig.json Version: 60 structureChanged: true Elapsed: 782ms
Perf 2560 [10:35:13.539] 8513::syntacticDiagnosticsSync: elapsed time (in milliseconds) 786.1921
Info 2561 [10:35:13.539] response:
    {"seq":0,"type":"response","command":"syntacticDiagnosticsSync","request_seq":"8513","success":true,"body":[]}
Info 2562 [10:35:13.540] request:
    {"command":"semanticDiagnosticsSync","seq":"8514","arguments":{"file":"[removed]/src/field.ts"}}
Perf 2563 [10:35:13.544] 8514::semanticDiagnosticsSync: elapsed time (in milliseconds) 4.0577
Info 2564 [10:35:13.544] response:
    {"seq":0,"type":"response","command":"semanticDiagnosticsSync","request_seq":"8514","success":true,"body":[]}
Info 2565 [10:35:13.544] Running: [removed]/tsconfig.json
Info 2566 [10:35:13.544] Running: *ensureProjectForOpenFiles*
Info 2567 [10:35:13.544] Structure before ensureProjectForOpenFiles:
Info 2568 [10:35:13.544] Project '[removed]/tsconfig.json' (Configured) 0
Info 2568 [10:35:13.544] 	Files (445)
	[removed]/tide/tsserver/lib.es5.d.ts
	[removed]/tide/tsserver/lib.es2015.d.ts
	[removed]/tide/tsserver/lib.es2016.d.ts
	[removed]/tide/tsserver/lib.es2017.d.ts
	[removed]/tide/tsserver/lib.es2018.d.ts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant