Skip to content

Commit 73ca361

Browse files
authored
Updated version to 1.20 (#2684)
1 parent 3379c6a commit 73ca361

File tree

6 files changed

+102
-9
lines changed

6 files changed

+102
-9
lines changed

library/fixed_point/qsharp.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"github": {
77
"owner": "Microsoft",
88
"repo": "qsharp",
9-
"ref": "v1.19.0",
9+
"ref": "v1.20.0",
1010
"path": "library/signed"
1111
}
1212
}

library/signed/qsharp.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
"github": {
77
"owner": "Microsoft",
88
"repo": "qsharp",
9-
"ref": "v1.19.0",
9+
"ref": "v1.20.0",
1010
"path": "library/qtest"
1111
}
1212
}

source/vscode/changelog.md

Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,98 @@
11
# QDK Changelog
22

3+
## v1.20.0
4+
5+
Below are some of the highlights for the 1.20 release of the QDK.
6+
7+
### QIR target profile selection redesign
8+
9+
In previous releases, the target QIR profile setting for code generation in VS Code was a global setting, and if switching between projects with different target profiles the user would need to remember to change the editor setting each time. This was cumbersome and a common source of confusion.
10+
11+
With this release, the target profile can be set per project. If working on a multi-file project with a `qsharp.json` manifest file, the target profile can be specified in the manifest file via the `"targetProfile"` property.
12+
13+
If working in a standalone Q# or OpenQASM file, the target profile can be specified via the `@EntryPoint` attribute in Q# files, or the `qdk.qir.profile` pragma in OpenQASM files. For example, to target a Q# file for `base profile` code generation:
14+
15+
```qsharp
16+
@EntryPoint(Base)
17+
operation Main() : Result[] {
18+
// ...
19+
}
20+
```
21+
22+
If submitting a job to the Azure Quantum service, upon submission the target profile will default to the capabilities of the target hardware if not otherwise specified.
23+
24+
See the [QDK Profile Selection](https://github.com/microsoft/qsharp/wiki/QDK-Profile-Selection) wiki page for more details and examples.
25+
26+
### OpenQASM improvements
27+
28+
- Arrays and complex numbers can now be passed as input and output.
29+
- Qubit aliases and array concatenation are now supported.
30+
- In VS Code, OpenQASM files now support:
31+
- Rename symbol (F2) for user-defined identifiers, gates, functions, etc; built-ins are not renameable.
32+
- Go to Definition (F12) and Find All References (Shift+F12).
33+
- The GitHub Copilot tools for the QDK now support OpenQASM (.qasm) files as well as Q#. You can simulate your program, generate a circuit diagram and generate resource estimates for Q# and OpenQASM programs right from the chat panel.
34+
35+
### Python interop improvements
36+
37+
In addition to primitive types, arrays, and tuples, users can now pass [Q# structs](https://github.com/microsoft/qsharp/wiki/Q%23-Structs). For example, the following shows passing a python object to a Q# operation that takes struct:
38+
39+
<img width="899" src="https://github.com/user-attachments/assets/b711a19e-3814-44bc-9df7-cefca2830609" />
40+
41+
Complex numbers are also supported, allowing the passing of Python complex literals and variables directly to Q# callables, e.g.
42+
43+
```python
44+
import qsharp
45+
46+
qsharp.eval("""
47+
import Std.Math.Complex;
48+
49+
function SwapComponents(c: Complex) : Complex {
50+
new Complex { Real = c.Imag, Imag = c.Real }
51+
}
52+
""")
53+
54+
from qsharp.code import SwapComponents
55+
assert SwapComponents(2 + 3j) == 3 + 2j
56+
```
57+
58+
For more details on Python and Q# interop see our [wiki page](https://github.com/microsoft/qsharp/wiki/Invoking-Q%23-callables-from-Python).
59+
60+
### Richer Copilot help for Q# APIs
61+
62+
In this release, we added a new Copilot tool that can access the documentation generated by all the APIs available in the current project (included the standard library and referenced libraries). This lets Copilot see up-to-date information on the Q# libraries available and how to use them, improving Copilot's working knowledge of Q#. From generated Q# snippets to answering questions about available APIs, Copilot can use this to provide more accurate and up-to-date information.
63+
64+
<img width="723" src="https://github.com/user-attachments/assets/005cf3f5-7364-4ef4-ac00-b558d2d953c8" />
65+
66+
### Language service improvements
67+
68+
Numerous improvements to the language service have been made for correctness and completeness, especially around import and export declarations. The language service now also provides better diagnostics for QIR generation errors. Please log issues if you encounter any problems!
69+
70+
## Other notable changes
71+
72+
- Profile Selection Redesign by [@ScottCarda-MS](https://github.com/ScottCarda-MS) in [#2636](https://github.com/microsoft/qsharp/pull/2636)
73+
- Import and export resolution improvements by [@minestarks](https://github.com/minestarks) in [#2638](https://github.com/microsoft/qsharp/pull/2638)
74+
- Fix parsing of OPENQASM version statement by [@orpuente-MS](https://github.com/orpuente-MS) in [#2650](https://github.com/microsoft/qsharp/pull/2650)
75+
- Fix completions for import and exports by [@minestarks](https://github.com/minestarks) in [#2640](https://github.com/microsoft/qsharp/pull/2640)
76+
- Python - Q# UDT interop by [@orpuente-MS](https://github.com/orpuente-MS) in [#2635](https://github.com/microsoft/qsharp/pull/2635)
77+
- Fix off-by-one error in stack traces by making line and column numbers 1-based for user display by [@Copilot](https://github.com/Copilot) in [#2628](https://github.com/microsoft/qsharp/pull/2628)
78+
- Allow recursive calls to operations that return `Unit` by [@swernli](https://github.com/swernli) in [#2654](https://github.com/microsoft/qsharp/pull/2654)
79+
- Fix panic when running .qsc circuit file by [@orpuente-MS](https://github.com/orpuente-MS) in [#2666](https://github.com/microsoft/qsharp/pull/2666)
80+
- OpenQASM language service: add rename/definition/references, semantic passes, and VS Code wiring by [@idavis](https://github.com/idavis) in [#2656](https://github.com/microsoft/qsharp/pull/2656)
81+
- Add support for qubit alias decls by [@idavis](https://github.com/idavis) in [#2665](https://github.com/microsoft/qsharp/pull/2665)
82+
- Remove Azure Quantum Credits deprecation message from VS Code extension by [@Copilot](https://github.com/Copilot) in [#2668](https://github.com/microsoft/qsharp/pull/2668)
83+
- Support numpy arrays in the Python interop layer by [@orpuente-MS](https://github.com/orpuente-MS) in [#2671](https://github.com/microsoft/qsharp/pull/2671)
84+
- Definition, References, Hover, Rename for import/export decls by [@minestarks](https://github.com/minestarks) in [#2641](https://github.com/microsoft/qsharp/pull/2641)
85+
- Nicer error messages for QIR generation by [@minestarks](https://github.com/minestarks) in [#2664](https://github.com/microsoft/qsharp/pull/2664)
86+
- Improve interface and output for Submit Job Copilot tool by [@minestarks](https://github.com/minestarks) in [#2673](https://github.com/microsoft/qsharp/pull/2673)
87+
- Lower duration and stretch by [@idavis](https://github.com/idavis) in [#2611](https://github.com/microsoft/qsharp/pull/2611)
88+
- OpenQASM support for Copilot tools by [@minestarks](https://github.com/minestarks) in [#2675](https://github.com/microsoft/qsharp/pull/2675)
89+
- Add support for array concatenation in OpenQASM by [@orpuente-MS](https://github.com/orpuente-MS) in [#2676](https://github.com/microsoft/qsharp/pull/2676)
90+
- Copilot Reads Summaries from DocGen Tool by [@ScottCarda-MS](https://github.com/ScottCarda-MS) in [#2672](https://github.com/microsoft/qsharp/pull/2672)
91+
- OpenQASM input and output interop by [@idavis](https://github.com/idavis) in [#2678](https://github.com/microsoft/qsharp/pull/2678)
92+
- Better symbol resolution for OpenQASM LS support by [@idavis](https://github.com/idavis) in [#2679](https://github.com/microsoft/qsharp/pull/2679)
93+
94+
**Full Changelog**: [v1.19.0...v1.20.0](https://github.com/microsoft/qsharp/compare/v1.19.0...v1.20.0)
95+
396
## v1.19.0
497

598
Below are some of the highlights for the 1.19 release of the QDK.

source/vscode/src/changelog.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { EventType, sendTelemetryEvent } from "./telemetry";
66
import { getRandomGuid } from "./utils";
77

88
// The latest version for which we want to show the changelog page
9-
const CHANGELOG_VERSION = "v1.19.0"; // <-- Update this when you want to show a new changelog to users
9+
const CHANGELOG_VERSION = "v1.20.0"; // <-- Update this when you want to show a new changelog to users
1010

1111
export function registerChangelogCommand(
1212
context: vscode.ExtensionContext,

source/vscode/src/registry.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"owner": "microsoft",
99
"repo": "qsharp",
1010
"refs": [
11-
{ "ref": "v1.19.0", "notes": "latest stable" },
11+
{ "ref": "v1.20.0", "notes": "latest stable" },
1212
{ "ref": "main", "notes": "nightly, unstable" }
1313
],
1414
"path": "library/chemistry"
@@ -23,7 +23,7 @@
2323
"owner": "microsoft",
2424
"repo": "qsharp",
2525
"refs": [
26-
{ "ref": "v1.19.0", "notes": "latest stable" },
26+
{ "ref": "v1.20.0", "notes": "latest stable" },
2727
{ "ref": "main", "notes": "nightly, unstable" }
2828
],
2929
"path": "library/signed"
@@ -38,7 +38,7 @@
3838
"owner": "microsoft",
3939
"repo": "qsharp",
4040
"refs": [
41-
{ "ref": "v1.19.0", "notes": "latest stable" },
41+
{ "ref": "v1.20.0", "notes": "latest stable" },
4242
{ "ref": "main", "notes": "nightly, unstable" }
4343
],
4444
"path": "library/fixed_point"
@@ -53,7 +53,7 @@
5353
"owner": "microsoft",
5454
"repo": "qsharp",
5555
"refs": [
56-
{ "ref": "v1.19.0", "notes": "latest stable" },
56+
{ "ref": "v1.20.0", "notes": "latest stable" },
5757
{ "ref": "main", "notes": "nightly, unstable" }
5858
],
5959
"path": "library/rotations"
@@ -68,7 +68,7 @@
6868
"owner": "microsoft",
6969
"repo": "qsharp",
7070
"refs": [
71-
{ "ref": "v1.19.0", "notes": "latest stable" },
71+
{ "ref": "v1.20.0", "notes": "latest stable" },
7272
{ "ref": "main", "notes": "nightly, unstable" }
7373
],
7474
"path": "library/qtest"

version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
import re
88

99
# To be updated every time we start a new major.minor version.
10-
major_minor = "1.19"
10+
major_minor = "1.20"
1111

1212
root_dir = os.path.dirname(os.path.abspath(__file__))
1313
source_dir = os.path.join(root_dir, "source")

0 commit comments

Comments
 (0)