Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 16 additions & 8 deletions .claude/skills/release-manager/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -153,11 +153,17 @@ Before a release, check finos/morphir-elm for a newer `extension/elm/v*` tag and
finos/morphir-scala for a newer `v*` release, and move the pins.

**WASM extensions (Avro, OpenAPI, Python, Rust).** finos/morphir does not build
the guests. finos/morphir-rust owns the check that a new bundle works with the
released CLI. This repository owns the check that a CLI change does not break the
bundles users already installed: CI downloads the bundles pinned in
the guests. The repository that owns an extension checks that a new bundle works
with the released CLI: finos/morphir-rust for Avro, OpenAPI and Rust, and
finos/morphir-python for Python (crate `rust/crates/morphir-python-binding`,
release tags `extension/python/v<version>`). Python bundles up to
`extension/python/v0.4.0` stay in the finos/morphir-rust releases. This
repository owns the check that a CLI change does not break the bundles users
already installed: CI downloads the bundles pinned in
`.config/published-extension-bundles.toml` and runs the ignored extension tests
against them. Run the same check with the release binary:
against them. A `[bundles.<id>]` pin names the releasing repository in
`repository`; a pin without one comes from finos/morphir-rust. Run the same check
with the release binary:

```bash
mise run ci:fetch-published-bundles
Expand All @@ -169,10 +175,12 @@ MORPHIR_PYTHON_BUNDLE="$B/python" MORPHIR_RUST_BUNDLE="$B/rust" \
--test python_extension --test rust_extension -- --ignored
```

Before a release, check finos/morphir-rust releases for newer `extension/<id>/v*`
tags and move the pins. When the CLI changes the extension protocol on purpose,
publish a compatible bundle from finos/morphir-rust first, then move the pin in
the same pull request as the CLI change.
Before a release, check the releases of each owning repository for newer
`extension/<id>/v*` tags and move the pins: finos/morphir-rust for Avro, OpenAPI
and Rust, finos/morphir-python for Python. A pin that moves to another repository
changes `repository` with its tag, artifact and `sha256`. When the CLI changes the
extension protocol on purpose, publish a compatible bundle from the owning
repository first, then move the pin in the same pull request as the CLI change.

Then prove one bundle by hand in a clean home. `generate` needs a project
configuration, so the steps run inside a directory with a `morphir.toml`:
Expand Down
18 changes: 12 additions & 6 deletions .config/published-extension-bundles.toml
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# Published finos/morphir-rust extension bundles that CI runs the CLI against.
# Published WASM extension bundles that CI runs the CLI against.
#
# These are the bundles users install. A CLI change that breaks one of them turns CI red.
# Each bundle is downloaded from the releases of the repository that owns it. `repository` names
# that repository as `owner/name`; a pin without one comes from finos/morphir-rust.
# `sha256` is the digest of the guest `.wasm`. It is checked against the download, so a release
# asset that someone replaces does not run. For a deliberate protocol change, publish a compatible bundle from finos/morphir-rust first,
# then move the pin here in the same pull request as the CLI change.
# asset that someone replaces does not run. For a deliberate protocol change, publish a compatible
# bundle from the repository that owns it first, then move the pin here in the same pull request
# as the CLI change.

[bundles.avro]
tag = "extension/avro/v0.2.0"
Expand All @@ -15,10 +18,13 @@ tag = "extension/openapi/v0.2.0"
artifact = "morphir-openapi-extension-0.2.0"
sha256 = "ccef0ebcc8f4fff5579c5c28ee4cb44cdec46a6f4ec993a8e6ceb029996f5ec0"

# finos/morphir-python owns the Python extension. Bundles up to extension/python/v0.4.0 remain in
# the finos/morphir-rust releases.
[bundles.python]
tag = "extension/python/v0.4.0"
artifact = "morphir-python-binding-0.4.0"
sha256 = "e5bc0d1593eb1b3f7d33d6a627e07c14c0fd21c9274abc22bd326318c602c36b"
repository = "finos/morphir-python"
tag = "extension/python/v0.4.1"
artifact = "morphir-python-binding-0.4.1"
sha256 = "a04722e16115667fc7c332177805dcb049aef563afcee0e5f80c5fea302f5b4e"

[bundles.rust]
tag = "extension/rust/v0.3.0"
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -311,9 +311,10 @@ jobs:

- name: Fetch the published extensions
# The extensions users install, at the tags and digests pinned in
# .config/published-extension-bundles.toml: four WASM bundles from
# finos/morphir-rust, the Elm process extension from finos/morphir-elm
# and the Scala Elm provider from finos/morphir-scala. The owning
# .config/published-extension-bundles.toml: four WASM bundles from the
# repositories that release them, the Elm process extension from
# finos/morphir-elm and the Scala Elm provider from
# finos/morphir-scala. The owning
# repository checks that a new release
# works with the released CLI; this job checks that a CLI change does
# not break the published releases.
Expand Down
2 changes: 1 addition & 1 deletion AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ Current `mise` releases auto-trust project configuration in normal mode; the exp
- **[finos/morphir-rust](https://github.com/finos/morphir-rust)** — Rust libraries (`morphir-core`, `morphir-common`, etc.) used by the CLI
- **[finos/morphir-examples](https://github.com/finos/morphir-examples)** — Example Morphir projects
- **[finos/morphir-moonbit](https://github.com/finos/morphir-moonbit)** — MoonBit implementation of Morphir tooling
- **[finos/morphir-python](https://github.com/finos/morphir-python)** — Python implementation of Morphir tooling
- **[finos/morphir-python](https://github.com/finos/morphir-python)** — Python implementation of Morphir tooling, and the owner of the Python compiler and the `morphir-python` WASM extension (new `extension/python/v*` releases; bundles up to `v0.4.0` stay in finos/morphir-rust releases)
- **[finos/morphir-scala](https://github.com/finos/morphir-scala)** — Scala implementation of Morphir tooling
- **[finos/morphir-ui](https://github.com/finos/morphir-ui)** — User-interface work for the Morphir project

Expand Down
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Changed
- The `morphir-python` extension now comes from finos/morphir-python, which maintains the
Python compiler. CI tests the CLI against its `extension/python/v0.4.1` bundle; bundles up to
`extension/python/v0.4.0` remain in the finos/morphir-rust releases. Extension bundle pins
can name the repository that owns them.

## [0.4.0-beta.10] - 2026-10-21

### Added
Expand Down
31 changes: 23 additions & 8 deletions INSTALLING.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,17 +85,32 @@ if ($actual -ne $expected) { throw "Checksum verification failed" }

## Install the Python extension

The CLI ships separately from language extensions. With CLI `0.4.0-beta.7` or
later, install the `morphir-python` WASM bundle `extension/python/v0.4.0` to compile
supported Python ADTs, fixed tuples, conditional functions, typed calls and unary
lambdas to Morphir IR v3 or v4 and generate Python. Its version-2 descriptor needs
CLI `0.4.0-beta.7` to publish; with CLI `0.4.0-beta.1` to `0.4.0-beta.6`, use
`extension/python/v0.3.0`. The earlier `v0.1.0` bundle does not compile with this CLI.
See the [Python extension installation guide](https://github.com/finos/morphir-rust/blob/main/docs/tutorials/python-extension.md)
The CLI ships separately from language extensions. The `morphir-python` WASM
extension compiles supported Python ADTs, fixed tuples, conditional functions,
typed calls and unary lambdas to Morphir IR v3 or v4 and generates Python.

[finos/morphir-python](https://github.com/finos/morphir-python) owns the
extension. It holds the compiler crate,
[`morphir-python-binding`](https://github.com/finos/morphir-python/blob/main/rust/crates/morphir-python-binding/README.md),
and publishes new `extension/python/v<version>` bundles in its releases. The
bundles up to `extension/python/v0.4.0` were released from finos/morphir-rust and
stay in the [finos/morphir-rust releases](https://github.com/finos/morphir-rust/releases).

With CLI `0.4.0-beta.7` or later, install the bundle `extension/python/v0.4.0`. Its
version-2 descriptor needs CLI `0.4.0-beta.7` to publish; with CLI `0.4.0-beta.1`
to `0.4.0-beta.6`, use `extension/python/v0.3.0`. The earlier `v0.1.0` bundle does
not compile with this CLI. See the
[Python extension guide](https://github.com/finos/morphir-python/blob/main/docs/python-extension.md)
for download, repository publication and installation commands, and the
[binding README](https://github.com/finos/morphir-rust/blob/main/crates/morphir-python-binding/README.md)
[binding README](https://github.com/finos/morphir-python/blob/main/rust/crates/morphir-python-binding/README.md)
for the supported subset and conformance limits.

finos/morphir-python also packages the same compiler for Python. From the first
`morphir-python` release on PyPI that includes it, `pip install morphir-python`
gives a Python API and a `morphir-python` command that compile and generate
without the Morphir CLI. See the
[Python compiler guide](https://github.com/finos/morphir-python/blob/main/docs/python-compiler.md).

## Build from source

Building from source requires Git, [mise](https://mise.jdx.dev/), and the
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ Morphir consists of a few projects based on the features they provide.
- **[morphir-bosque](https://github.com/finos/morphir-bosque)** - Integration with the Bosque language.
- **[morphir-dotnet](https://github.com/finos/morphir-dotnet)** - Integration with .NET via F#.
- **[morphir-rust](https://github.com/finos/morphir-rust)** - Integration with Rust
- **[morphir-python](https://github.com/finos/morphir-python)** - Integration with Python
- **[morphir-python](https://github.com/finos/morphir-python)** - Integration with Python: the IR library and SDK, the Python compiler and the `morphir-python` extension for the Morphir CLI
- **[morphir-moonbit](https://github.com/finos/morphir-moonbit)** - MoonBit implementation of Morphir tooling
- **[morphir-go](https://github.com/finos/morphir-go)** - Go implementation of Morphir tooling (CLI, WIT pipeline, Go backends)
- **[morphir-ui](https://github.com/finos/morphir-ui)** - User-interface work for the Morphir project
Expand Down
3 changes: 2 additions & 1 deletion crates/morphir/tests/host_compatibility.rs
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,8 @@ fn openapi() {
#[test]
#[ignore = "requires MORPHIR_PUBLISHED_BUNDLES"]
fn python() {
// morphir-python-binding/tests/pipeline.rs: backend_accepts_an_independently_authored_sum.
// finos/morphir-python, rust/crates/morphir-python-binding/tests/pipeline.rs:
// backend_accepts_an_independently_authored_sum.
wasm(
"python",
serde_json::from_str(include_str!(
Expand Down
4 changes: 3 additions & 1 deletion ecosystem/AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ This directory holds **git submodules** for Morphir ecosystem repositories. Use
- **morphir-rust** – Rust workspace (morphir-core, morphir-common, morphir-daemon, morphir-ext, etc.). The **morphir** CLI binary lives in this repo under `crates/morphir`, not in the submodule; it depends on morphir-rust crates via path.
- **morphir-examples** – Example Morphir projects.
- **morphir-moonbit** – MoonBit implementation of Morphir tooling.
- **morphir-python** – Python implementation of Morphir tooling.
- **morphir-python** – Python implementation of Morphir tooling. Owns the Python compiler and the `morphir-python` WASM extension.
- **morphir-scala** – Scala implementation of Morphir tooling. Mill build, cross-compiled to JVM, JS, and Scala Native.
- **morphir-ui** – Morphir's UI monorepo: the morphir-desktop (Electron) and morphir-web apps sharing one Svelte + Effect application (moonrepo + mise + bun toolchain).
- **morphir-typescript** – TypeScript binding for the Morphir IR: the reference semantic model, the version and profile codecs, and its MCK adapter. Shared IR and package runners live in the parent Rust CLI, `morphir mck`. TypeScript retains independent adapters/implementations. PKG-2 moves draft.3 corpus/fixture support to parent Rust MCK and bounded runtime helpers to `morphir-package` in [#852](https://github.com/finos/morphir/issues/852). See [spec/mck/migration.md](../spec/mck/migration.md). Bun workspace; runtime-neutral (Node, Bun, Deno, browser).
Expand Down Expand Up @@ -62,6 +62,8 @@ Valid package names: `morphir-sdk`, `morphir-core`, `morphir-moonbit-bindings`

Python implementation of Morphir tooling. Uses `uv` for package management and `behave` for BDD tests.

It also owns the Python compiler, the Rust crate `rust/crates/morphir-python-binding`, and the `morphir-python` WASM extension built from it (extension id `morphir-python`, short id `python`, artifact `morphir-python-binding-<version>`, release tags `extension/python/v<version>`). Bundles up to `extension/python/v0.4.0` were released from finos/morphir-rust and stay in its releases. finos/morphir does not build the bundle: `[bundles.python]` in `.config/published-extension-bundles.toml` pins a published release and names its repository. The guides are `docs/python-extension.md` and `docs/python-compiler.md` in that repository.

```bash
cd ecosystem/morphir-python && uv sync && uv run behave
```
Expand Down
4 changes: 2 additions & 2 deletions ecosystem/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ This directory contains [git submodules](https://git-scm.com/book/en/v2/Git-Tool
| **morphir-rust** | [finos/morphir-rust](https://github.com/finos/morphir-rust) | main | Rust libraries (morphir-core, morphir-common, etc.) used by the morphir CLI in this repo |
| **morphir-examples** | [finos/morphir-examples](https://github.com/finos/morphir-examples) | main | Example Morphir projects; used for docs, tests, and reference |
| **morphir-moonbit** | [finos/morphir-moonbit](https://github.com/finos/morphir-moonbit) | main | MoonBit implementation of Morphir tooling |
| **morphir-python** | [finos/morphir-python](https://github.com/finos/morphir-python) | main | Python implementation of Morphir tooling |
| **morphir-python** | [finos/morphir-python](https://github.com/finos/morphir-python) | main | Python implementation of Morphir tooling; owns the Python compiler and the `morphir-python` WASM extension |
| **morphir-scala** | [finos/morphir-scala](https://github.com/finos/morphir-scala) | main | Scala implementation of Morphir tooling; Mill build cross-compiled to JVM, JS, and Scala Native |
| **morphir-ui** | [finos/morphir-ui](https://github.com/finos/morphir-ui) | main | Morphir's UI monorepo: the morphir-desktop (Electron) and morphir-web apps sharing one Svelte + Effect application |

Expand Down Expand Up @@ -66,7 +66,7 @@ mise run submodules:status
- **morphir-rust**: The morphir CLI (in `crates/`) depends on morphir-rust crates via Cargo path dependencies (e.g. `morphir-core`, `morphir-common`). The submodule is required to build those crates.
- **morphir-examples**: Used for examples, documentation, and tests. See each submodule's own README for build and usage.
- **morphir-moonbit**: MoonBit implementation with packages for SDK, core types, and WASM bindings. See below for build commands.
- **morphir-python**: Python implementation of Morphir tooling. See the submodule's own README for build and usage.
- **morphir-python**: Python implementation of Morphir tooling. It owns the Python compiler (the Rust crate `rust/crates/morphir-python-binding`) and the `morphir-python` WASM extension that the CLI installs, and releases new `extension/python/v<version>` bundles. Bundles up to `extension/python/v0.4.0` were released from finos/morphir-rust and stay there. The CLI in this repository does not build the extension; CI runs it against the bundle pinned in `.config/published-extension-bundles.toml`. See the submodule's own README, `docs/python-extension.md` and `docs/python-compiler.md` for build and usage.
- **morphir-scala**: Scala implementation of Morphir tooling, built with Mill. See below for build commands.
- **morphir-ui**: Morphir's UI monorepo — the morphir-desktop (Electron) and morphir-web apps sharing one Svelte + Effect application, with `morphir-ir.json` browsing, MORPHIR_HOME-backed configuration, and GitHub token capture. Build from within the submodule (it has its own mise toolchain): `cd ecosystem/morphir-ui && mise install && bun install && moon run :build` (see that repo's README for the full getting-started guide).

Expand Down
4 changes: 2 additions & 2 deletions tests/ci/test_ci_rust_optimizations.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ def test_setup_rust_ci_action_shares_cargo_cache(self) -> None:
self.assertIn("link-arg=-fuse-ld=mold", self.setup_rust_ci_action)

def test_ci_tests_published_bundles_and_builds_no_wasm_guest(self) -> None:
# finos/morphir-rust owns the guest builds. This repository checks that a CLI change
# does not break the bundles users already installed.
# The repository that owns each extension builds its guest. This repository checks
# that a CLI change does not break the bundles users already installed.
self.assertIn("mise run ci:fetch-published-bundles", self.ci_workflow)
self.assertNotIn("--target wasm32-unknown-unknown", self.ci_workflow)
self.assertNotIn("package_extension.py", self.ci_workflow)
Expand Down
Loading
Loading