Skip to content

Update language service when manifest is saved. (Closes #1284)#1366

Merged
orpuente-MS merged 4 commits into
mainfrom
oscarpuente/json-watcher
Apr 10, 2024
Merged

Update language service when manifest is saved. (Closes #1284)#1366
orpuente-MS merged 4 commits into
mainfrom
oscarpuente/json-watcher

Conversation

@orpuente-MS
Copy link
Copy Markdown
Contributor

@orpuente-MS orpuente-MS commented Apr 8, 2024

This PR enables sending document-updates to a given project documents when its manifest is edited and saved.

manifest-watcher-demo.mp4

@orpuente-MS orpuente-MS linked an issue Apr 8, 2024 that may be closed by this pull request
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 8, 2024

Benchmark for 9a8cc47

Click to view benchmark
Test Base PR %
Array append evaluation 352.1±4.37µs 350.3±1.29µs -0.51%
Array literal evaluation 193.6±8.77µs 192.9±2.41µs -0.36%
Array update evaluation 431.2±1.94µs 431.1±1.95µs -0.02%
Core + Standard library compilation 16.8±0.04ms 16.8±0.06ms 0.00%
Deutsch-Jozsa evaluation 5.1±0.08ms 5.1±0.06ms 0.00%
Large file parity evaluation 33.7±0.09ms 33.7±0.22ms 0.00%
Large input file compilation 11.9±0.07ms 11.1±0.12ms -6.72%
Large input file compilation (interpreter) 43.1±0.97ms 43.0±0.89ms -0.23%
Large nested iteration 34.2±0.26ms 34.1±0.16ms -0.29%
Perform Runtime Capabilities Analysis (RCA) on Deutsch-Jozsa sample 1477.5±30.05µs 1479.9±26.74µs +0.16%
Perform Runtime Capabilities Analysis (RCA) on large file sample 7.6±0.08ms 7.6±0.14ms 0.00%
Perform Runtime Capabilities Analysis (RCA) on teleport sample 1389.3±32.34µs 1395.2±45.69µs +0.42%
Perform Runtime Capabilities Analysis (RCA) on the core and std libraries 21.2±0.31ms 21.2±0.29ms 0.00%
Teleport evaluation 81.0±3.70µs 80.2±3.54µs -0.99%

Copy link
Copy Markdown
Member

@minestarks minestarks left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm amazed by the simplicity of this fix. I was getting all twisted up imagining what sorts of infrastructure changes we'd need to do in the language service... But this is very clever and to the point. Thanks!

Comment thread vscode/src/extension.ts Outdated
Comment thread vscode/src/extension.ts Outdated
Comment thread vscode/src/extension.ts Outdated
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 8, 2024

Benchmark for 8774d9d

Click to view benchmark
Test Base PR %
Array append evaluation 346.4±2.85µs 335.7±2.38µs -3.09%
Array literal evaluation 203.0±3.65µs 177.0±1.58µs -12.81%
Array update evaluation 431.3±2.69µs 418.0±1.53µs -3.08%
Core + Standard library compilation 17.6±1.52ms 17.0±0.25ms -3.41%
Deutsch-Jozsa evaluation 5.0±0.09ms 5.0±0.04ms 0.00%
Large file parity evaluation 33.8±0.19ms 33.7±0.23ms -0.30%
Large input file compilation 11.2±0.24ms 11.4±0.35ms +1.79%
Large input file compilation (interpreter) 43.4±1.18ms 43.7±1.26ms +0.69%
Large nested iteration 33.8±0.33ms 32.6±0.37ms -3.55%
Perform Runtime Capabilities Analysis (RCA) on Deutsch-Jozsa sample 1518.7±65.96µs 1493.4±34.50µs -1.67%
Perform Runtime Capabilities Analysis (RCA) on large file sample 7.9±0.11ms 8.0±0.14ms +1.27%
Perform Runtime Capabilities Analysis (RCA) on teleport sample 1424.4±33.03µs 1407.6±63.76µs -1.18%
Perform Runtime Capabilities Analysis (RCA) on the core and std libraries 21.5±0.39ms 21.3±0.27ms -0.93%
Teleport evaluation 80.4±3.41µs 80.7±3.80µs +0.37%

@orpuente-MS orpuente-MS requested a review from minestarks April 8, 2024 23:06
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Apr 8, 2024

Benchmark for f6dc3be

Click to view benchmark
Test Base PR %
Array append evaluation 341.6±22.29µs 345.8±2.20µs +1.23%
Array literal evaluation 177.1±4.51µs 195.4±1.20µs +10.33%
Array update evaluation 423.7±22.62µs 429.9±1.65µs +1.46%
Core + Standard library compilation 16.8±0.32ms 18.2±0.66ms +8.33%
Deutsch-Jozsa evaluation 5.0±0.06ms 5.0±0.04ms 0.00%
Large file parity evaluation 33.7±0.16ms 33.7±0.39ms 0.00%
Large input file compilation 11.2±0.14ms 12.0±0.31ms +7.14%
Large input file compilation (interpreter) 43.0±0.98ms 48.1±1.70ms +11.86%
Large nested iteration 33.0±2.13ms 33.8±0.28ms +2.42%
Perform Runtime Capabilities Analysis (RCA) on Deutsch-Jozsa sample 1490.7±26.37µs 1515.1±72.86µs +1.64%
Perform Runtime Capabilities Analysis (RCA) on large file sample 7.7±0.12ms 7.8±0.09ms +1.30%
Perform Runtime Capabilities Analysis (RCA) on teleport sample 1407.3±33.61µs 1427.3±71.35µs +1.42%
Perform Runtime Capabilities Analysis (RCA) on the core and std libraries 21.2±0.16ms 21.8±1.10ms +2.83%
Teleport evaluation 80.1±3.96µs 81.4±11.65µs +1.62%

@orpuente-MS orpuente-MS added this pull request to the merge queue Apr 10, 2024
Merged via the queue into main with commit ffaf5c2 Apr 10, 2024
@orpuente-MS orpuente-MS deleted the oscarpuente/json-watcher branch April 10, 2024 18:47
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

Successfully merging this pull request may close these issues.

Project isn't updated after editing qsharp.json

2 participants