diff --git a/Cargo.lock b/Cargo.lock index 3700bdd95e..9dea5fcac0 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1179,7 +1179,7 @@ checksum = "6dbf3de79e51f3d586ab4cb9d5c3e2c14aa28ed23d180cf89b4df0454a69cc87" [[package]] name = "hugr" -version = "0.20.0-rc.0" +version = "0.20.0" dependencies = [ "bumpalo", "criterion", @@ -1193,7 +1193,7 @@ dependencies = [ [[package]] name = "hugr-cli" -version = "0.20.0-rc.0" +version = "0.20.0" dependencies = [ "assert_cmd", "assert_fs", @@ -1209,7 +1209,7 @@ dependencies = [ [[package]] name = "hugr-core" -version = "0.20.0-rc.0" +version = "0.20.0" dependencies = [ "cgmath", "cool_asserts", @@ -1248,7 +1248,7 @@ dependencies = [ [[package]] name = "hugr-llvm" -version = "0.20.0-rc.0" +version = "0.20.0" dependencies = [ "anyhow", "delegate", @@ -1267,7 +1267,7 @@ dependencies = [ [[package]] name = "hugr-model" -version = "0.20.0-rc.0" +version = "0.20.0" dependencies = [ "base64", "bumpalo", @@ -1291,7 +1291,7 @@ dependencies = [ [[package]] name = "hugr-passes" -version = "0.20.0-rc.0" +version = "0.20.0" dependencies = [ "ascent", "derive_more", diff --git a/hugr-cli/CHANGELOG.md b/hugr-cli/CHANGELOG.md index 5d0cf16b19..357d24fd2c 100644 --- a/hugr-cli/CHANGELOG.md +++ b/hugr-cli/CHANGELOG.md @@ -1,7 +1,7 @@ # Changelog -## [0.20.0-rc.0](https://github.com/CQCL/hugr/compare/hugr-cli-v0.15.4...hugr-cli-v0.20.0-rc.0) - 2025-05-09 +## [0.20.0](https://github.com/CQCL/hugr/compare/hugr-cli-v0.15.4...hugr-cli-v0.20.0) - 2025-05-14 ### New Features @@ -9,6 +9,7 @@ - [**breaking**] Add Hugr entrypoints ([#2147](https://github.com/CQCL/hugr/pull/2147)) - [**breaking**] Validate any HugrView, make errors generic ([#2155](https://github.com/CQCL/hugr/pull/2155)) - [**breaking**] Only expose envelope serialization of hugrs and packages ([#2167](https://github.com/CQCL/hugr/pull/2167)) +- Packages do not include the hugr extensions by default ([#2187](https://github.com/CQCL/hugr/pull/2187)) ## [0.15.3](https://github.com/CQCL/hugr/compare/hugr-cli-v0.15.2...hugr-cli-v0.15.3) - 2025-04-02 diff --git a/hugr-cli/Cargo.toml b/hugr-cli/Cargo.toml index dc52603d82..cd7d1fb26a 100644 --- a/hugr-cli/Cargo.toml +++ b/hugr-cli/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "hugr-cli" -version = "0.20.0-rc.0" +version = "0.20.0" edition = { workspace = true } rust-version = { workspace = true } license = { workspace = true } @@ -19,7 +19,7 @@ bench = false clap = { workspace = true, features = ["derive", "cargo"] } clap-verbosity-flag.workspace = true derive_more = { workspace = true, features = ["display", "error", "from"] } -hugr = { path = "../hugr", version = "0.20.0-rc.0" } +hugr = { path = "../hugr", version = "0.20.0" } serde_json.workspace = true clio = { workspace = true, features = ["clap-parse"] } diff --git a/hugr-core/CHANGELOG.md b/hugr-core/CHANGELOG.md index 1857258769..136ceea110 100644 --- a/hugr-core/CHANGELOG.md +++ b/hugr-core/CHANGELOG.md @@ -1,6 +1,6 @@ # Changelog -## [0.20.0-rc.0](https://github.com/CQCL/hugr/compare/hugr-core-v0.15.4...hugr-core-v0.20.0-rc.0) - 2025-05-09 +## [0.20.0](https://github.com/CQCL/hugr/compare/hugr-core-v0.15.4...hugr-core-v0.20.0) - 2025-05-14 ### Bug Fixes @@ -8,6 +8,10 @@ - `as_unary_option` indexing bug ([#2163](https://github.com/CQCL/hugr/pull/2163)) - Skip phantom data for array value serialisation ([#2166](https://github.com/CQCL/hugr/pull/2166)) - Remove deleted nodes from node_map in `SimpleReplacement` ([#2176](https://github.com/CQCL/hugr/pull/2176)) +- [**breaking**] Use unique region_portgraph in convexity check ([#2192](https://github.com/CQCL/hugr/pull/2192)) +- Panic when an extension name is too long. ([#2198](https://github.com/CQCL/hugr/pull/2198)) +- Respect type bounds on local variables when importing. ([#2206](https://github.com/CQCL/hugr/pull/2206)) +- Import and export JSON metadata on module roots. ([#2207](https://github.com/CQCL/hugr/pull/2207)) ### New Features @@ -33,6 +37,15 @@ - Only allow region containers as entrypoints ([#2173](https://github.com/CQCL/hugr/pull/2173)) - Export and import entrypoints via metadata in `hugr-model`. ([#2172](https://github.com/CQCL/hugr/pull/2172)) - [**breaking**] Only expose envelope serialization of hugrs and packages ([#2167](https://github.com/CQCL/hugr/pull/2167)) +- Packages do not include the hugr extensions by default ([#2187](https://github.com/CQCL/hugr/pull/2187)) +- Define text-model envelope formats ([#2188](https://github.com/CQCL/hugr/pull/2188)) +- [**breaking**] Remove description on opaque ops. ([#2197](https://github.com/CQCL/hugr/pull/2197)) +- Import CFG regions without adding an entry block. ([#2200](https://github.com/CQCL/hugr/pull/2200)) +- [**breaking**] Remove boundary map in SimpleReplacement ([#2208](https://github.com/CQCL/hugr/pull/2208)) +- Export macro for hugr serde wrappers with custom extensions ([#2209](https://github.com/CQCL/hugr/pull/2209)) +- Allow any dataflow parent as SiblingSubgraph replacement ([#2210](https://github.com/CQCL/hugr/pull/2210)) +- [**breaking**] Hide FuncDefn/cl fields, add accessors and ::new(...) ([#2213](https://github.com/CQCL/hugr/pull/2213)) +- Add SiblingSubgraph::set_outgoing_ports ([#2217](https://github.com/CQCL/hugr/pull/2217)) ### Refactor @@ -52,6 +65,7 @@ ### Testing - Disable IO-dependent tests when running miri ([#2123](https://github.com/CQCL/hugr/pull/2123)) +- check envelope roundtrips rather than json in `HugrView::verify` ([#2186](https://github.com/CQCL/hugr/pull/2186)) ## [0.15.3](https://github.com/CQCL/hugr/compare/hugr-core-v0.15.2...hugr-core-v0.15.3) - 2025-04-02 diff --git a/hugr-core/Cargo.toml b/hugr-core/Cargo.toml index 7bc38921a8..499410d764 100644 --- a/hugr-core/Cargo.toml +++ b/hugr-core/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "hugr-core" -version = "0.20.0-rc.0" +version = "0.20.0" edition = { workspace = true } rust-version = { workspace = true } @@ -27,7 +27,7 @@ bench = false name = "model" [dependencies] -hugr-model = { version = "0.20.0-rc.0", path = "../hugr-model" } +hugr-model = { version = "0.20.0", path = "../hugr-model" } cgmath = { workspace = true, features = ["serde"] } delegate = { workspace = true } diff --git a/hugr-llvm/CHANGELOG.md b/hugr-llvm/CHANGELOG.md index 3632dc9aba..ad75b6c6ce 100644 --- a/hugr-llvm/CHANGELOG.md +++ b/hugr-llvm/CHANGELOG.md @@ -5,7 +5,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). -## [0.20.0-rc.0](https://github.com/CQCL/hugr/compare/hugr-llvm-v0.15.4...hugr-llvm-v0.20.0-rc.0) - 2025-05-09 +## [0.20.0](https://github.com/CQCL/hugr/compare/hugr-llvm-v0.15.4...hugr-llvm-v0.20.0) - 2025-05-14 ### Bug Fixes @@ -24,6 +24,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Add LLVM emission for prelude.noop ([#2160](https://github.com/CQCL/hugr/pull/2160)) - [**breaking**] Add Hugr entrypoints ([#2147](https://github.com/CQCL/hugr/pull/2147)) - [**breaking**] Return a node mapping in HugrInternals::region_portgraph ([#2164](https://github.com/CQCL/hugr/pull/2164)) +- Restore old array lowering ([#2194](https://github.com/CQCL/hugr/pull/2194)) +- [**breaking**] Hide FuncDefn/cl fields, add accessors and ::new(...) ([#2213](https://github.com/CQCL/hugr/pull/2213)) ## [0.15.4](https://github.com/CQCL/hugr/compare/hugr-llvm-v0.15.3...hugr-llvm-v0.15.4) - 2025-05-07 diff --git a/hugr-llvm/Cargo.toml b/hugr-llvm/Cargo.toml index 93047c72e5..5a96450f4d 100644 --- a/hugr-llvm/Cargo.toml +++ b/hugr-llvm/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "hugr-llvm" -version = "0.20.0-rc.0" +version = "0.20.0" description = "A general and extensible crate for lowering HUGRs into LLVM IR" edition.workspace = true @@ -26,7 +26,7 @@ workspace = true [dependencies] inkwell = { version = "0.6.0", default-features = false } -hugr-core = { path = "../hugr-core", version = "0.20.0-rc.0" } +hugr-core = { path = "../hugr-core", version = "0.20.0" } anyhow = "1.0.98" itertools.workspace = true delegate.workspace = true diff --git a/hugr-model/CHANGELOG.md b/hugr-model/CHANGELOG.md index 1f0d2d5ad3..f3c7c2326f 100644 --- a/hugr-model/CHANGELOG.md +++ b/hugr-model/CHANGELOG.md @@ -1,12 +1,14 @@ # Changelog -## [0.20.0-rc.0](https://github.com/CQCL/hugr/compare/hugr-model-v0.19.1...hugr-model-v0.20.0-rc.0) - 2025-05-09 +## [0.20.0](https://github.com/CQCL/hugr/compare/hugr-model-v0.19.0...hugr-model-v0.20.0) - 2025-05-14 ### New Features - [**breaking**] Mark all Error enums as non_exhaustive ([#2056](https://github.com/CQCL/hugr/pull/2056)) - [**breaking**] Bump MSRV to 1.85 ([#2136](https://github.com/CQCL/hugr/pull/2136)) - Export and import entrypoints via metadata in `hugr-model`. ([#2172](https://github.com/CQCL/hugr/pull/2172)) +- Define text-model envelope formats ([#2188](https://github.com/CQCL/hugr/pull/2188)) +- Import CFG regions without adding an entry block. ([#2200](https://github.com/CQCL/hugr/pull/2200)) ## [0.19.0](https://github.com/CQCL/hugr/compare/hugr-model-v0.18.1...hugr-model-v0.19.0) - 2025-05-07 diff --git a/hugr-model/Cargo.toml b/hugr-model/Cargo.toml index 60c8b61376..cc11a2320d 100644 --- a/hugr-model/Cargo.toml +++ b/hugr-model/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "hugr-model" -version = "0.20.0-rc.0" +version = "0.20.0" readme = "README.md" documentation = "https://docs.rs/hugr-model/" description = "Data model for Quantinuum's HUGR intermediate representation" diff --git a/hugr-passes/CHANGELOG.md b/hugr-passes/CHANGELOG.md index e9a59539b5..0526b83c60 100644 --- a/hugr-passes/CHANGELOG.md +++ b/hugr-passes/CHANGELOG.md @@ -1,7 +1,7 @@ # Changelog -## [0.20.0-rc.0](https://github.com/CQCL/hugr/compare/hugr-passes-v0.15.4...hugr-passes-v0.20.0-rc.0) - 2025-05-09 +## [0.20.0](https://github.com/CQCL/hugr/compare/hugr-passes-v0.15.4...hugr-passes-v0.20.0) - 2025-05-14 ### New Features @@ -22,6 +22,7 @@ - [**breaking**] Return a node mapping in HugrInternals::region_portgraph ([#2164](https://github.com/CQCL/hugr/pull/2164)) - [**breaking**] Validate any HugrView, make errors generic ([#2155](https://github.com/CQCL/hugr/pull/2155)) - [**breaking**] Explicit hugr type param to ComposablePass ([#2179](https://github.com/CQCL/hugr/pull/2179)) +- [**breaking**] Hide FuncDefn/cl fields, add accessors and ::new(...) ([#2213](https://github.com/CQCL/hugr/pull/2213)) ### Refactor diff --git a/hugr-passes/Cargo.toml b/hugr-passes/Cargo.toml index 5bca634744..4a6a006458 100644 --- a/hugr-passes/Cargo.toml +++ b/hugr-passes/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "hugr-passes" -version = "0.20.0-rc.0" +version = "0.20.0" edition = { workspace = true } rust-version = { workspace = true } license = { workspace = true } @@ -19,7 +19,7 @@ workspace = true bench = false [dependencies] -hugr-core = { path = "../hugr-core", version = "0.20.0-rc.0" } +hugr-core = { path = "../hugr-core", version = "0.20.0" } portgraph = { workspace = true } ascent = { version = "0.8.0" } derive_more = { workspace = true, features = ["display", "error", "from"] } diff --git a/hugr-py/Cargo.toml b/hugr-py/Cargo.toml index cd4dbcb29f..44ec5a3656 100644 --- a/hugr-py/Cargo.toml +++ b/hugr-py/Cargo.toml @@ -21,8 +21,6 @@ bench = false [dependencies] bumpalo = { workspace = true, features = ["collections"] } -hugr-model = { version = "0.20.0-rc.0", path = "../hugr-model", features = [ - "pyo3", -] } +hugr-model = { version = "0.20.0", path = "../hugr-model", features = ["pyo3"] } paste.workspace = true pyo3 = { workspace = true, features = ["extension-module", "abi3-py310"] } diff --git a/hugr/CHANGELOG.md b/hugr/CHANGELOG.md index c2b38ec46f..418e92685c 100644 --- a/hugr/CHANGELOG.md +++ b/hugr/CHANGELOG.md @@ -1,6 +1,21 @@ # Changelog -## [0.20.0-rc.0](https://github.com/CQCL/hugr/compare/hugr-v0.15.4...hugr-v0.20.0-rc.0) - 2025-05-09 +## [0.20.0](https://github.com/CQCL/hugr/compare/hugr-v0.15.4...hugr-v0.20.0) - 2025-05-14 + +This release contains a big list of changes reworking multiple core definitions of HUGR. +Some of this changes include: + +- ๐Ÿงน Cleanup of the internal hugr traits, making it possible to create virtual + Hugrs that are not backed by a portgraph or use different node index types. +- ๐Ÿšช The functional root of a Hugr is now called the *entrypoint*. This node may + exist somewhere inside the region hierarchy, so we can now model edges that + connect beyond the descendants of the entrypoint. +- ๐ŸŒฒ The hugr region hierarchy is now always rooted by a `Module` operation. +- โœ‚ Made `SimpleReplacement` even simpler and easy to use. +- ๐Ÿ”ง The `Rewrite` trait has been split into `VerifyPatch` and `Patch` parts. +- โœ‰๏ธ Hugr and package serialization is now done entirely using Envelopes. We + provide some backward-compatibility layers that will be removed in the future. +- ๐Ÿฆ€ The Minimum Supported Rust Version (MSRV) has been updated to `1.85`. ### Bug Fixes @@ -8,6 +23,10 @@ - `as_unary_option` indexing bug ([#2163](https://github.com/CQCL/hugr/pull/2163)) - Skip phantom data for array value serialisation ([#2166](https://github.com/CQCL/hugr/pull/2166)) - Remove deleted nodes from node_map in `SimpleReplacement` ([#2176](https://github.com/CQCL/hugr/pull/2176)) +- [**breaking**] Use unique region_portgraph in convexity check ([#2192](https://github.com/CQCL/hugr/pull/2192)) +- Panic when an extension name is too long. ([#2198](https://github.com/CQCL/hugr/pull/2198)) +- Respect type bounds on local variables when importing. ([#2206](https://github.com/CQCL/hugr/pull/2206)) +- Import and export JSON metadata on module roots. ([#2207](https://github.com/CQCL/hugr/pull/2207)) ### New Features @@ -38,12 +57,25 @@ - [**breaking**] Bump MSRV to 1.85 ([#2136](https://github.com/CQCL/hugr/pull/2136)) - [**breaking**] Removed runtime extension sets. ([#2145](https://github.com/CQCL/hugr/pull/2145)) - [**breaking**] Only expose envelope serialization of hugrs and packages ([#2167](https://github.com/CQCL/hugr/pull/2167)) +- Packages do not include the hugr extensions by default ([#2187](https://github.com/CQCL/hugr/pull/2187)) +- Define text-model envelope formats ([#2188](https://github.com/CQCL/hugr/pull/2188)) +- [**breaking**] Remove description on opaque ops. ([#2197](https://github.com/CQCL/hugr/pull/2197)) +- Import CFG regions without adding an entry block. ([#2200](https://github.com/CQCL/hugr/pull/2200)) +- [**breaking**] Remove boundary map in SimpleReplacement ([#2208](https://github.com/CQCL/hugr/pull/2208)) +- Export macro for hugr serde wrappers with custom extensions ([#2209](https://github.com/CQCL/hugr/pull/2209)) +- Allow any dataflow parent as SiblingSubgraph replacement ([#2210](https://github.com/CQCL/hugr/pull/2210)) +- [**breaking**] Hide FuncDefn/cl fields, add accessors and ::new(...) ([#2213](https://github.com/CQCL/hugr/pull/2213)) +- Add SiblingSubgraph::set_outgoing_ports ([#2217](https://github.com/CQCL/hugr/pull/2217)) ### Refactor - do not use .portgraph in mermaid/graphviz ([#2177](https://github.com/CQCL/hugr/pull/2177)) - [**breaking**] Removed global portgraph-related methods from `HugrInternals` ([#2180](https://github.com/CQCL/hugr/pull/2180)) +### Testing + +- check envelope roundtrips rather than json in `HugrView::verify` ([#2186](https://github.com/CQCL/hugr/pull/2186)) + ## [0.15.4](https://github.com/CQCL/hugr/compare/hugr-v0.15.3...hugr-v0.15.4) - 2025-05-07 ### New Features diff --git a/hugr/Cargo.toml b/hugr/Cargo.toml index 01281bb704..e1dd555e74 100644 --- a/hugr/Cargo.toml +++ b/hugr/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "hugr" -version = "0.20.0-rc.0" +version = "0.20.0" edition = { workspace = true } rust-version = { workspace = true } @@ -30,10 +30,10 @@ llvm-test = ["hugr-llvm/llvm14-0", "hugr-llvm/test-utils"] zstd = ["hugr-core/zstd"] [dependencies] -hugr-model = { path = "../hugr-model", version = "0.20.0-rc.0" } -hugr-core = { path = "../hugr-core", version = "0.20.0-rc.0" } -hugr-passes = { path = "../hugr-passes", version = "0.20.0-rc.0" } -hugr-llvm = { path = "../hugr-llvm", version = "0.20.0-rc.0", optional = true } +hugr-model = { path = "../hugr-model", version = "0.20.0" } +hugr-core = { path = "../hugr-core", version = "0.20.0" } +hugr-passes = { path = "../hugr-passes", version = "0.20.0" } +hugr-llvm = { path = "../hugr-llvm", version = "0.20.0", optional = true } [dev-dependencies] lazy_static = { workspace = true }