Release Notes
💥 Breaking
- WASM API
- Reworked the
VirtualPathtype from the ground up. Is no longer an enum, but instead a newtype
wrapper aroundPathBuf.- This allows for better interoperability with the Rust ecosystem, and makes it easier to work
with virtual paths in general. - Additionally, because of this change,
VirtualPathnow has access to allPathBufmethods,
which was not possible before.
- This allows for better interoperability with the Rust ecosystem, and makes it easier to work
- Removed the
from_virtual_pathandto_virtual_pathextism host functions,into_real_path
andinto_virtual_pathwrapper functions, andreal_path!andvirtual_path!macros. Use the
conversion utils instead (below).
- Reworked the
🚀 Updates
- Action graph
- Added a new mechanism where toolchains can specify requirements (other toolchains to be setup)
for the setup environment action.
- Added a new mechanism where toolchains can specify requirements (other toolchains to be setup)
- CLI
- Added OpenTelemetry (OTEL) support, for exporting traces, metrics, and logs over OTLP.
- Added a
--otelglobal option (MOON_OTEL), for exporting traces and metrics. - Added a
--otel-logsglobal option (MOON_OTEL_LOGS), for exporting log events as OTLP logs. - Added a
--otel-service-nameglobal option (MOON_OTEL_SERVICE_NAME), for the reported
service name. - The destination and transport are configured with the standard
OTEL_EXPORTER_OTLP_*
environment variables.
- Added a
- Updated the
moon setupaction to also setup the toolchain environment, if their dependency
root is the same as the workspace root. Nested dependency roots will not be setup, as they are
expected to be setup by their parent project. - Updated the
moon exec(and related pipeline commands) to display action failures in the
summary at the bottom, instead of interleaved within all actions.
- Added OpenTelemetry (OTEL) support, for exporting traces, metrics, and logs over OTLP.
- Config
- Added an unstable
cache.unstable_sharedWorktreeCachesetting to.moon/workspace.*, which
shares the CAS cache between all VCS worktrees on the same machine. Only blobs and manifests are
shared, as they are portable, while hashes, locks, and states remain worktree-specific. The
cache is stored in the base checkout's.moon/cachedirectory, or~/.moon/cache/sharedwhen
the repository root has no checkout (bare clones). Requires thecasOutputsCacheexperiment. - Added environment variable support for cache settings:
MOON_CACHE_CAS_MAX_SIZE,
MOON_CACHE_CAS_VERIFY_INTEGRITY, andMOON_CACHE_SHARED_WORKTREE_CACHE. - Added an
envsetting to.moon/tasks/**/*configs. These environment variables are inherited
by all matching projects, and are merged into each project'senvsetting, with project-level
variables taking precedence. - Added a
workspace.mergeStrategiessetting tomoon.*config, which controls how project
settings are merged with inherited workspace-level settings. Currently supportsenvand
fileGroups, using the same merge strategies as task merging (append,prepend,preserve,
andreplace). - Project globs can now be configured with a trailing file, allowing more precise project
matching. For example,apps/*/package.jsonwill only find Node.js projects, and
src/**/*.csprojwill only find .NET projects. The path without file name will be used as the
project identifier (if not defined).- This change does not apply to root-level projects. Use a
.glob or target a moon
configuration file.
- This change does not apply to root-level projects. Use a
- Added an unstable
- Daemon
- Added task output archiving and hydrating to the daemon. All of these heavy file system
operations will now be offloaded into the background via the daemon. Because of this, you'll
need to inspect the daemon server logs to understand when something fails during archiving or
hydrating, as the main process will no longer block on these operations.
- Added task output archiving and hydrating to the daemon. All of these heavy file system
- Docker
- Improved the scaffolding and pruning workflows, by better handling edge cases, and ensuring its
more reliable.
- Improved the scaffolding and pruning workflows, by better handling edge cases, and ensuring its
- Experiments
- The
asyncAffectedTracking,asyncGraphBuilding, andnativeFileHashingexperiments are now
enabled by default. If you run into issues, please report it, and then disable the experiment to
continue.
- The
- Project graph
- Reworked the project graph to validate cycles per dependency scope partition. Production scoped
dependencies (production,peer) and development scoped dependencies (development,build,
root) are now tracked as separate internal graphs, so relationships that cross the boundary no
longer fail with a cycle error, or silently drop dependency edges.
- Reworked the project graph to validate cycles per dependency scope partition. Production scoped
- WASM API
- Added a
RealPathtype, which is a newtype wrapper aroundPathBufthat represents a real path
on the host file system. This is a sibling to theVirtualPathtype, which represents a virtual
path in the guest WASM environment. - Added
convert_to_virtual_pathandconvert_to_real_pathhelper functions for converting
between real and virtual paths, using a list of host-to-guest path mappings.- Can also use
VirtualPathExt::to_real_pathandRealPathExt::to_virtual_pathextension
traits for the same functionality.
- Can also use
- Added
DefineRequirementsOutput.for_setup_environmentandfor_setup_toolchainfields, which
allow toolchains to specify requirements for the setup environment and setup toolchain actions,
respectively. - Added
PruneDockerInput.project_dependenciesfield, which allows the toolchain to know about
other projects that the focused project(s) depends on, so it can prune their dependencies as
well. - Updated
DefineRequirementsInput.toolchain_configto inherit the project-level settings when
applicable.
- Added a
🧰 Toolchains
- Go
- The
forceoption forbinsentries is now respected, and will always install the binary. - Fixed configured
binsnot being reinstalled when their binaries were uninstalled or deleted
outside of moon. - Reworked relationship inference to match package import paths instead of module paths. Each
project now resolves a canonical import path (nearestgo.modmodule path plus the project's
relative directory), andgo list -depsresults are matched against those by longest prefix.
This makes relationships resolvable in repositories that share a singlego.modacross all
projects. - Sibling modules required by version without a
go.workno longer create project relationships,
since those builds consume the published module rather than the local source. When thego
binary is unavailable, projects with their owngo.modunder a workspacego.workfall back to
resolving relationships from their direct requires. replacedirectives keep their meaning in the new model: a require replaced by a local
directory always links to the project at that location (it consumes local source even without a
go.work), while a require replaced by another module never links.- Imports within a project's own import path are treated as ownership rather than dependencies.
go list -deps ./...enumerates packages belonging to projects nested inside the scanned
project, which previously inferred an edge from the parent to every nested child — forming a
cycle whenever a child declareddependsOnon its parent.
- The
- JavaScript
- Added unstable support for Nub as a package manager:
- Natively uses
nub.lock(pnpm lockfile format), but will locate dependency roots using other
package manager lockfiles that nub can operate on. - Reads workspace members and catalogs from
pnpm-workspace.yamlwhen present, otherwise from
package.json. - Does not require the Node.js toolchain, as nub is a standalone binary.
- Natively uses
- Fixed
bun.lockparsing failing on Git/GitHub dependencies that include both package metadata
(dependencies,bin, etc) and an integrity hash.
- Added unstable support for Nub as a package manager:
- Node
- Deprecated the
syncVersionManagerConfigsetting (it never worked correctly).
- Deprecated the
- Python
- Ensures that package manager toolchains are installed before setting up the environment.
- Added support to the Docker pruning workflow where we remove
.venvdirectories for non-focused
projects (those that were not explicitly scaffolded).
- Rust
- Fixed an issue where Docker scaffolding would leave behind empty
lib.rsormain.rsfiles. - Fixed configured
binsnot being reinstalled when their binaries were uninstalled or deleted
outside of moon. Only missing binaries are now installed.
- Fixed an issue where Docker scaffolding would leave behind empty
🐞 Fixes
- Fixed an issue where the
--stackand--sourceoptions ofmoon query projectsdisplayed each
other's help text. The filtering behavior itself was correct. - Fixed an issue where toolchain executable paths were not properly applied to all child processes.
- Fixed an issue where project and task graph node lookups could resolve the wrong entry, or fail
entirely, after building a partial graph (a subset of projects), as internal node identifiers were
not re-synced when placeholder nodes were removed. - Fixed an issue where the async graph builder would fail with "unknown target" when a task
dependency referenced a project by its alias. - Fixed an issue where the async graph builder would produce differently ordered graphs across runs,
as projects were inserted in completion order instead of a stable order. This could cause unstable
hashes and--dot/--jsonoutput. - Fixed an issue where a task with
runDepsInParallel: falsewould not be linked to all of its
dependencies when a serial ordering edge was skipped to avoid a cycle, allowing the task to run
before a dependency had finished. - Fixed an issue where moon would abort on startup with "Failed to load Git submodules" in
repositories without a.gitmodulesfile, when the git object database was incomplete or
unreachable (e.g. partial clones, or--referenceclones whose alternates are inaccessible).
Submodule detection is now skipped entirely when no.gitmodulesfile exists. - Fixed an issue where the synchronous affected tracker (
experiments.asyncAffectedTracking
disabled) would silently skip transitive dependent tasks when running with--downstreamand
--include-relations, and could even schedule fewer tasks when the change set grew, as affected
marks were accumulated lazily in target iteration order. Affected status is now tracked up front,
mirroring the asynchronous tracker. - Fixed an issue on Windows where path variables (
$workspaceRoot,$workingDir,$projectRoot)
expanded using the Windows path format (C:\path) based on the shell moon was executed from,
instead of the shell the task runs in. When thewindowsShelltask option isbash, they now
expand using the Unix path format (/c/path) that bash expects. - Fixed an issue where
--downstream deepwould also expand the dependents of upstream
dependencies, running tasks that are not dependents of the requested targets (with a deep enough
graph, the entire connected component). Downstream expansion now only flows from the requested
targets through their dependent chains, matching how--downstream directalready behaved. - Fixed an issue where a failed proto installation would not abort the pipeline nor surface its
error. Dependent toolchain actions would run in the broken environment and fail with misleading
errors (like a missingproto-shimbinary) that masked the root cause. Setup proto and setup
environment failures now abort the pipeline immediately, and when multiple actions fail, the first
failure is reported instead of the last.
⚙️ Internal
- Renamed the
TaskMergeStrategytype toMergeStrategyin@moonrepo/types, as it's no longer
exclusive to tasks. - Updated proto to v0.60.2 from 0.58.2.
- Updated Rust to v1.97.0.
- Updated dependencies.
Install moon_cli 2.5.0
Install prebuilt binaries via shell script
curl --proto '=https' --tlsv1.2 -LsSf https://github.com/moonrepo/moon/releases/download/v2.5.0/moon_cli-installer.sh | shInstall prebuilt binaries via powershell script
powershell -ExecutionPolicy Bypass -c "irm https://github.com/moonrepo/moon/releases/download/v2.5.0/moon_cli-installer.ps1 | iex"Download moon_cli 2.5.0
| File | Platform | Checksum |
|---|---|---|
| moon_cli-aarch64-apple-darwin.tar.xz | Apple Silicon macOS | checksum |
| moon_cli-x86_64-apple-darwin.tar.xz | Intel macOS | checksum |
| moon_cli-x86_64-pc-windows-msvc.zip | x64 Windows | checksum |
| moon_cli-aarch64-unknown-linux-gnu.tar.xz | ARM64 Linux | checksum |
| moon_cli-x86_64-unknown-linux-gnu.tar.xz | x64 Linux | checksum |
| moon_cli-aarch64-unknown-linux-musl.tar.xz | ARM64 MUSL Linux | checksum |
| moon_cli-x86_64-unknown-linux-musl.tar.xz | x64 MUSL Linux | checksum |