microsoft / qsharp

Azure Quantum Development Kit, including the Q# programming language, resource estimator, and Quantum Katas
https://microsoft.github.io/qsharp/
MIT License
426 stars 86 forks source link

Support error Uri, update RCA error strings #1575

Closed swernli closed 4 months ago

swernli commented 4 months ago

This change adds support for error Uris by hooking the miette error .url() to the VS Code and Monaco target field. It also updates the wording on RCA check pass errors to use "configured target profile" instead of "current target" for more clarification. A follow up PR can update the error link(s) to point to more specific documentation pages.

In VS Code, the error links show up as a clickable error code: image

In Python/Jupyter, the miette visualization is used which puts clickable links next to the error code: image

In Monaco (used in the playground) links work like the VS Code version:

image
github-actions[bot] commented 4 months ago

Benchmark for 9517571

Click to view benchmark | Test | Base | PR | % | |------|--------------|------------------|---| | Array append evaluation | **331.2±2.48µs** | 333.8±4.43µs | **+0.79%** | | Array literal evaluation | 192.5±0.88µs | 192.7±3.73µs | +0.10% | | Array update evaluation | 412.6±4.52µs | 417.0±5.42µs | +1.07% | | Core + Standard library compilation | 21.7±0.99ms | 21.9±0.95ms | +0.92% | | Deutsch-Jozsa evaluation | 5.2±0.07ms | **5.1±0.04ms** | **-1.92%** | | Large file parity evaluation | 34.2±0.09ms | 34.2±0.48ms | 0.00% | | Large input file compilation | 14.1±0.71ms | 14.1±0.75ms | 0.00% | | Large input file compilation (interpreter) | 51.6±1.57ms | 52.6±2.56ms | +1.94% | | Large nested iteration | 32.6±0.22ms | 32.7±0.18ms | +0.31% | | Perform Runtime Capabilities Analysis (RCA) on Deutsch-Jozsa sample | 1597.7±99.70µs | 1595.5±132.02µs | -0.14% | | Perform Runtime Capabilities Analysis (RCA) on large file sample | 8.2±0.24ms | 8.1±0.22ms | -1.22% | | Perform Runtime Capabilities Analysis (RCA) on teleport sample | 1470.8±161.91µs | 1445.2±72.36µs | -1.74% | | Perform Runtime Capabilities Analysis (RCA) on the core and std libraries | 29.4±0.55ms | **29.0±0.37ms** | **-1.36%** | | Teleport evaluation | 91.1±3.60µs | 87.8±4.42µs | -3.62% |