Skip to content

1.0 beta - #13296

Merged
tiborvass merged 263 commits into
mainfrom
1.0-beta
Jun 8, 2026
Merged

1.0 beta#13296
tiborvass merged 263 commits into
mainfrom
1.0-beta

Conversation

@shykes

@shykes shykes commented Jun 1, 2026 •

Copy link
Copy Markdown
Contributor

Overview

Development branch for Dagger 1.0. Beta releases (1.0.0-beta.x) are released from this branch until it's ready to merge into main.

Features

  • Workspaces: project-level configuration separate from module definition
  • SDKs v2: SDKs now own more of the module development experience. Including user-facing commands and docs.
  • Modules v2: modules can do more out of the box, for more projects, thanks to more powerful APIs
  • CLI-first cloud. Dagger Cloud can be entirely managed and consumed from the CLI. Corollary: coding agents can fully leverage Dagger Cloud.
  • Simplified CLI: general cleanup and UX improvements.

Breaking changes

  • Docs rewrite. We aim to redirect all old URLs, but some concepts of guides may be dropped or broken.
  • Some commands will break. We maintain hidden aliases and deprecation notices for most changed commands. But some commands simply won't work anymore, for example dagger toolchain or dagger init --blueprint
  • Modules using blueprints and toolchains may be loaded as a workspace, but not as a module.
  • Legacy config files can be loaded with full compatibility - but changing them (ie. to install new modules) requires migration. Migration is automated with dagger workspace migrate

Schedule

  • Merge to main, target date: Friday 2026-06-05
  • Release first usable beta build: Monday 2026-06-01 ✅ 1.0.0-beta.2 released
  • Release stable 1.0: June 2026

Task list

  • Disable workspace inheritance from transient dependencies
  • Change default locking to pinned
  • Resolve final config file names (possible change to dagger.toml, dagger.lock, dagger-module.json
  • CLI: dagger without args should show regular usage, not pop into the shell
  • Global config: create environments and install modules that apply to one or more workspaces - from a config in your home directory (think: npm install -g)
  • Docs! Finish the docs
  • (stretch) merge collections & artifacts support
  • Workspace.git
  • Migrate our own CI to use the beta (keep old config files to support 0.x also)
  • Investigate dagger generate private git dependency auth regression (git authentication failed; dagger develop worked)
  • Investigate legacy user defaults still appearing in the user TUI; migrate/compat should map them to module settings without printing user defaults
  • Rework dagger -W <remote> check cloud/local selection; decide per workspace remote and dirty commit state, regardless of explicit -W
  • Investigate dagger migrate scanning extra dagger.json files in ignored build output (for example Rust target) and failing with GraphQL errors; likely should ignore gitignored directories
  • Investigate dagger migrate on 1.0-beta with v1.0.0-beta.2: plain migrate fails on codegen settings hints; forced/apply migrate fails before writing changes with the go sdk does not currently support selecting a specific version from a nested legacy fixture such as sdk.source = "go@main".
  • Investigate dagger update not supporting version bumps across tags.
  • Workspace config for remote execution, to Dagger Cloud or a custom endpoint
  • WS config for LLM: model, API endpoint

@shykes
shykes requested a review from a team as a code owner June 1, 2026 19:18
grouville and others added 29 commits June 1, 2026 12:45
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Workspace setting hint tests were constructing nested TypeDef values with raw pointers. That shape no longer matches runtime: object and list TypeDefs carry dagql object identity, and the hint code should be exercised against that shape.

Build the test fixtures through a tiny dagql server with synthetic result calls. This keeps the test focused while making it fail for the same reasons production values would fail.

Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
The workspace design notes and local QA docs are working documents, so small formatting drift makes them harder to scan and easier to misread. The important bit here is not changing the design, it is keeping the examples and lists rendered predictably in Markdown.

Annotate ambiguous code fences, nest list details under the steps they explain, and normalize a few example blocks. This keeps the docs readable without changing the underlying proposals.

Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
My lockfile branch was always rebased on top of main (current workflow).
but the lockfile PR branch is not

Some of the last commits on main do conflict with my branch, with fixes i had
to revert to have a clean history when force-pushing the workspace
branch

I had 2 choices:
1) we move away from the workspace branch
2) i reverted some changes and the conflicts from main, ill handle them
   via the rebase from lockfile

Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
The workspace branch removed the legacy `dagger toolchain` command and
moved the remaining intended behavior into workspace/module-oriented
coverage. During the rebase, `core/integration/toolchain_test.go` was
kept even though it belonged to the old command surface. The file now
fails immediately because `dagger toolchain install ...` is no longer
a valid CLI path.

Delete `core/integration/toolchain_test.go` instead of trying to
preserve its old generated-bindings or toolchain-codegen expectations.
The generated-bindings variant was checked and still fails with
`dag.Hello undefined`, which matches the workspace branch model: legacy
`toolchains` are projected into workspace modules, while generic module
loading rejects or strips legacy workspace-only fields. Reintroducing
toolchain modules into `ModuleSource.loadDependencyModules` would
restore the old path rather than exercising the new workspace path.

Keep the regression that still maps to the workspace compat model:
changing a legacy toolchain constructor customization default must
invalidate omitted-argument cache entries. That coverage now lives under
`TestWorkspaceCompat/TestLegacyToolchainCompat`, alongside the other
legacy dagger.json workspace compatibility tests. Also keep the small
import fix needed by the workspace helpers after the move.

Verified with:

  dagger --progress=plain call engine-dev test --pkg ./core/integration --run='TestWorkspaceCompat/TestLegacyToolchainCompat'
  git diff --cached --check

Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Workspace.path should always describe the actual workspace directory. It
had been carrying the path where workspace detection started in some
fallback paths, which made nested invocations report a subdirectory even
though Workspace.directory(path: ".") still resolved to the detected
workspace root.

This change preserves those two concepts separately. Workspace now keeps
an internal Cwd value for the client current working directory within
the detected workspace, and exposes it through a new Workspace.cwd
field. WorkspaceCwd has its own path field plus file and directory
helpers whose relative paths resolve from that cwd, while absolute paths
still resolve from the workspace boundary.

Workspace detection now reports the workspace path and detection-start
cwd independently. The .git fallback uses the git root as the workspace
path and records the nested start directory in Cwd. Remote workspaces
fold the detector root back into Path before building the core Workspace
so the remote rootfs can stay anchored at the cloned tree.

Uninitialized workspace config writes still happen where the user
invoked Dagger. configHostPath uses Cwd for uninitialized workspaces,
ensureWorkspaceInitialized clears Cwd after the config boundary is
created, and local workspace installs compute module source paths
relative to the actual config path.

The PR also adds integration and unit coverage for nested cwd behavior,
explicit workspace selection, remote cwd detection, contextual workspace
shape, and install/init behavior, then regenerates the GraphQL docs and
Go SDK bindings.

Fixes #13051

Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
workspace_compat_env_test.go had planning-only FIXME tests for legacy compat .env behavior. That left the conversion rules for .env keys under-tested, especially around whether defaults match source-language names, GraphQL names, or flexible module prefixes.

Replace those placeholders with executable integration coverage. TestArgName now creates a small Python module with snake_case source names and verifies compat .env defaults are applied through the normalized GraphQL argument names for both constructor and function arguments. It also verifies the original snake_case source names are not accepted as aliases, so the policy is explicit instead of incidental.

TestCompatEnvPrefixLookupPolicy now covers inner .env files, outer .env files, prefixed inner files, and dashed module names. The table locks down the accepted compact, snake_case, and lower-camel module prefix forms already implemented by EnvFile namespace handling. The stale lookupPrefix FIXME comment in the constructor coverage is removed because this prefix behavior is now covered directly.

Verified with dagger --progress=plain call engine-dev test --pkg ./core/integration --run='TestWorkspaceCompat/(TestArgName|TestCompatEnvPrefixLookupPolicy)'.

Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
The workspace migration integration suite still had several placeholder cases around preview, migration scope, idempotency, and destructive apply behavior. Filling those stubs exposed two concrete implementation gaps: the CLI tried to materialize a WorkspaceMigration ID even though the object is only a planning wrapper, and migration changesets could overwrite pre-existing target files while preparing the migrated module config.

This updates dagger migrate to use the returned Changeset directly instead of reloading the WorkspaceMigration by ID. It also validates every target path the migration plans to write before building or exporting the changeset, returning a clear error when an existing file such as .dagger/modules/<name>/dagger.json would be overwritten.

The integration coverage now checks report-mode migration preview via the migration changeset, confirms apply writes workspace config without copying external source trees, verifies nested compat migration uses the already-loaded compat workspace instead of rediscovering an outer dagger.json, asserts a second migrate is a no-op, and verifies target collisions leave existing user data and the legacy config untouched.

Verified with: dagger --progress=report call engine-dev test --pkg ./core/integration --run='TestWorkspaceMigration/(TestWorkspaceMigratePreviewAndApply|TestWorkspaceMigrateOutcomes|TestWorkspaceMigrateScope|TestWorkspaceMigrateSafety)'

Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
The contextual workspace integration suite still had placeholder subtests for several important selection cases: compat inference, nested native workspaces, negative standalone legacy modules, native-over-compat precedence, and a findUp boundary case. Those gaps meant the engine could regress in how it chooses the ambient Workspace before module code runs without a direct test catching it.

Fill those FIXMEs with focused Dang fixtures that assert the selected Workspace path, address, readable boundary content, and failure mode. The new CLI invocations in this file use --progress=report as requested, while the existing cache-log helper keeps --progress=logs because those subtests assert cache log visibility.

The new negative standalone-module case exposed that Workspace constructor args were being auto-injected even when the only detected workspace was the uninitialized git/root fallback. Tighten Workspace arg injection so module functions only receive an ambient Workspace from an initialized native workspace or a legacy compat workspace. currentWorkspace itself remains available for uninitialized workspace APIs such as init/config flows.

The native-over-compat case also exposed that initialized nested workspaces still let the CWD dagger.json lookup escape upward and nominate an outer legacy module. Stop CWD module nomination from crossing an initialized workspace boundary, so an inner native workspace wins cleanly over an outer compat-eligible project.

Update the Workspace API path-safety/findUp fixtures that previously used standalone modules as a convenience so they use initialized workspace modules instead. That keeps those API tests aligned with the stricter auto-injection contract.

Verification:
- dagger --progress=report call engine-dev test --pkg ./core/integration --run='TestContextualWorkspace'
- dagger --progress=report call engine-dev test --pkg ./core/integration --run='TestWorkspaceAPI/(TestWorkspacePathSafety|TestWorkspaceFindUp)'
- dagger --progress=report call engine-dev test --pkg ./engine/server

Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
workspace_config_test.go still had placeholder coverage for module settings policy, detailed settings semantics, and the CurrentWorkspace configuration lifecycle. That left important behavior around [modules.<name>.settings] and config boundary selection undocumented at the integration level.

Fill those stubs with concrete cases for the current contract: unknown settings keys are ignored unless a constructor actually needs them, settings key lookup is case-insensitive, typed bool/int/list values are coerced through runtime calls, malformed typed values fail with the relevant constructor setting, explicit CLI args override only the fields they provide, sibling modules keep separate settings tables, and invalid env/file/directory/service references fail at the point the configured object is resolved.

Also cover CurrentWorkspace.Init through the GraphQL API and workspace config reads from nested directories with both outer and inner workspace configs, proving the nearest initialized config boundary is selected.

While exercising the existing config write/read tests, writing entrypoint=false exposed that compact serialization omits false boolean fields, so a later config read treated the value as missing. Preserve the compact file format, but teach ReadConfigValue to report false defaults for missing boolean fields that have a well-defined false value: defaults_from_dotenv, modules.<name>.entrypoint, and modules.<name>.legacy-default-path. Add a unit test for those default reads.

The superconstructor workspace fixtures now use sources relative to .dagger/config.toml, matching the workspace source resolution model, and nested Dagger calls added in this file use --progress=report.

Verification:
- dagger --progress=report call engine-dev test --pkg ./core/integration --run='TestWorkspace/(TestWorkspaceConfigRead|TestWorkspaceConfigWrite|TestWorkspaceModuleSettingsRuntime|TestConfigAlias|TestWorkspaceConfigRequiresInit|TestCurrentWorkspaceConfigBoundary|TestWorkspaceInitCommand|TestWorkspaceModuleSettingsPolicy|TestWorkspaceModuleSettingsSemantics|TestWorkspaceConfigurationLifecycle)'
- dagger --progress=report call engine-dev test --pkg ./core/workspace

Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
core/integration/workspace_compat_test.go still had placeholder coverage for the legacy workspace compatibility seam. That left the core cases around compat detection, nested legacy-workspace direct-load errors, explicit -W behavior, migration handoff, and compat-vs-migrated runtime equivalence undocumented in executable tests.

Fill those cases with small Dang fixtures and report-mode Dagger CLI helpers local to the compat test file. The new detection coverage proves that legacy blueprint configs, toolchain configs, and non-dot source configs load through compat workspace behavior, while sdk-only root-source modules and initialized native workspace configs do not emit the compat inference warning. The direct-load coverage now checks both local workspace module sources and remote git-backed workspace module sources so the user-facing migration guidance stays explicit for each path.

The migration coverage now verifies that a compat project is converted into .dagger/config.toml plus migrated module config, sdk-only root-source modules remain a no-op, migration gaps write .dagger/migration-report.md, and a combined main-module/toolchain project behaves the same before and after dagger migrate -y. The compat warning assertion is also aligned with the current user-facing warning text.

Verified with:
  dagger --progress=report call engine-dev test --pkg ./core/integration --run='TestWorkspaceCompat/(TestCompatDetection|TestCompatWarning|TestLegacyWorkspaceDirectLoadErrors|TestCompatMigration|TestCompatAndMigratedWorkspaceMatch)'

Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
core/integration/module_loading_test.go still contained placeholder coverage for native module source resolution, ambient workspace loading, validation, precedence, dedupe, and entrypoint conflict behavior. That left the module-loading contract largely described in comments instead of executable tests.

Fill those placeholders while preserving the file's existing suite structure. The new tests use small Dang modules plus report-mode Dagger CLI helpers local to this file so the runtime assertions stay readable and do not reuse the older legacy command shims. The coverage now exercises relative extra-module source resolution, missing and non-directory module paths, no-entrypoint ambient workspaces, invalid multi-entrypoint workspace configs, CWD/extra/ambient precedence, no-module mode, duplicate workspace nominations, symlink/canonical dedupe, and ambient entrypoint conflicts.

One placeholder asked for multiple distinct extra-module entrypoints. The public CLI currently exposes only one --mod entrypoint, so that subtest is marked skipped with an explicit note instead of inventing a fake public scenario. The engine arbitration layer already has direct coverage for that internal metadata shape.

Verification:
  dagger --progress=report call engine-dev test --pkg ./core/integration --run='TestModuleLoading/(TestModuleSourceResolution/(context directory is empty when path has no module|module under unicode path initializes and loads|source may point to ancestor within context|relative extra module path resolves from invocation cwd|missing module path fails clearly|non-directory module path fails clearly)|TestAmbientWorkspaceModuleLoading|TestAmbientWorkspaceValidation|TestModuleLoadingPrecedence|TestModuleLoadingDedupeAndConflicts/(multiple distinct extra entrypoints are rejected|multiple distinct ambient entrypoints are rejected)|TestEntrypointRootRouting)'

Known development-branch red tests:
  dagger --progress=report call engine-dev test --pkg ./core/integration --run='TestModuleLoading'

That full run currently fails on the newly added dedupe assertions for canonical/symlinked module paths and duplicate workspace nominations. Those failures are left as product signal rather than papered over in the test file.

Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
The workspace selection integration suite was still a set of FIXME stubs, which left the declared --workspace/-W contract mostly covered by lower-level unit tests and nearby workspace suites. That made it hard to evolve contextual inference, native workspace config loading, remote workspace refs, and env overlay propagation without losing the explicit-selection behavior users exercise through the CLI.

Fill the suite with end-to-end CLI coverage while preserving its existing structure: declared local and remote workspace selection, --workdir ordering, precedence over ambient workspace and CWD module nomination, command-policy rejection, local-only mutation behavior, metadata commands, env overlay application and errors, and nested client inheritance. The tests use file-local helpers for report-mode Dagger CLI execution plus small native workspace fixtures, matching the style of the surrounding workspace tests without broadening shared helper APIs.

Some assertions intentionally describe the desired branch behavior even if the implementation is still red. In particular, the nested-client cases verify inheritance from forwarded session metadata instead of adapting to fallback detection. Verification: gofmt, no remaining FIXMEs in this file, git diff --check, and an earlier compile-only dagger --progress=report call go test --pkgs=./core/integration --run=TestWorkspaceSelection --count=0 passed before the final string-only nested fixture simplification.

Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
The workspace environment management suite was still a user-facing design spec made of FIXME stubs. That left env lifecycle commands, env-scoped config reads and writes, raw env escape hatches, and runtime/config consistency without executable integration coverage.

Replace the stubs with host-side CLI tests that preserve the existing test structure. The new coverage checks deterministic env listing, idempotent env creation, env removal errors, effective config reads under --env, env-scoped write storage and typing, validation of the allowed overlay surface, raw env.* config access, and runtime behavior for env-applied module constructor settings.

The tests use a small file-local host CLI helper that always invokes the dev CLI with --progress=report while keeping stdout separate from progress stderr for deterministic assertions. Shared workspace config and settings fixtures are reused from nearby tests so this file stays aligned with the existing workspace suite design.

Verification: gofmt, git diff --check, no remaining FIXME stubs in this file, dagger --progress=report call go test --pkgs=./core/integration --run=TestWorkspaceEnv --count=0, and dagger --progress=report call test-split test-specific --pkg=./core/integration --run=TestWorkspace/TestWorkspaceEnvLifecycleCommands. A direct dagger go test runtime slice was not useful because that lower-level wrapper does not provide the dev dagger CLI on PATH for host-side helpers.
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Problem
The workspace integration tests still had planning-era comments saying coverage was incomplete or describing sections as planning scaffolds. Those comments were left over from the FIXME-fill work and no longer reflected the state of the files, making the test ownership notes harder to trust.

Solution
Remove the stale planning/status language instead of replacing it with new completion claims. The remaining comments keep the durable scope and intent for each file without trying to encode project-progress state.

Implementation details
- Removed the obsolete "coverage is still incomplete" workspace alignment comments from the workspace-focused integration test files.
- Removed planning scaffold comments above filled-in workspace config and migration tests.
- Trimmed intent comments that still referred to finishing missing cases, while keeping the stable ownership descriptions.
- This is a comment-only cleanup; test behavior is unchanged.

Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Problem:
The new builtin Dang dependency module integration test initializes both a
top-level Dang module and a Dang child module through the shared module test
helpers. Those helpers run `dagger module init` and then write the requested
SDK source file by calling `sdkSourceAt`, which delegates to `sdkSourceFile` to
pick the SDK's source path. The helper knew about Go, Python, TypeScript, and
Java, but not Dang, so any test using `withModInit` or `withModInitAt` with
`sdk == "dang"` panicked locally before the test could exercise module loading.

The CI failure surfaced as:

```shell
panic: unknown sdk "dang"
```

from `sdkSourceFile`, while running `TestModule/TestBuiltinDangDependencyModules`.

Solution:
Teach the shared module helper where Dang source lives. Existing Dang workspace
and module tests consistently use `main.dang` as the source file created by
Dang module initialization, so the helper now maps the Dang SDK to that path.

Implementation details:
Add a `case "dang"` branch to `sdkSourceFile` returning `main.dang`. This keeps
the generic `withModInit` and `withModInitAt` helpers usable for Dang in the
same way they already work for Go, Python, TypeScript, and Java. The change is
intentionally limited to the helper path table; the failing test did not need a
test-specific workaround or a separate Dang-only initialization flow.

Verification:
Ran the targeted Dagger-in-Dagger integration check:

```shell
dagger --progress=plain call engine-dev test --pkg ./core/integration --run='TestModule/TestBuiltinDangDependencyModules' 2>&1
```

It passed with:

```shell
ok  	github.com/dagger/dagger/core/integration	131.010s
```

Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Legacy dagger.json entries that contain blueprints or toolchains are workspace
inputs on the workspace branch. Loading one directly with `-m` no longer
represents the compat path: it is the explicit direct-load rejection path, and
the CLI points users at `dagger -W <path>`.

The `outer_envfile_outer_workdir` cases in the compat blueprint and toolchain
env-default tests were still invoking `dagger -m ./app ...` from the outer
workdir. That made the tests fail while resolving the extra module, before they
reached the behavior they are intended to cover: selecting the legacy app
workspace from an outer workdir and reading the outer `.env` defaults.

Use `dagger -W ./app` in those two cases so the legacy `app/dagger.json` is
selected as the workspace under test. This keeps the tests aligned with the
workspace migration model while preserving direct `-m` coverage in the legacy
direct-load error tests and plain-module `-m` coverage in the other compat env
policy tests.

Implementation details:

- update `TestCompatBlueprintDefaults/outer_envfile_outer_workdir` to call
  `dagger -W ./app call message`
- update `TestCompatToolchainDefaults/outer_envfile_outer_workdir` to call
  `dagger -W ./app call defaults message`
- leave comments in both table entries explaining why `-W` is required for
  legacy workspace fields

Verified with:

```shell
`dagger --progress=plain call engine-dev test --pkg ./core/integration --run 'TestWorkspaceCompat/TestCompat(BlueprintDefaults|ToolchainDefaults)/outer_envfile_outer_workdir'`
```

Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Workspace.moduleList was returning a plain dagql array of WorkspaceModule
values built directly from the workspace config. That was enough for simple
field reads, but it skipped the normal object-result path that gives each
returned object a stable DagQL identity. The workspace CLI metadata paths depend
on those objects behaving like normal GraphQL objects, especially when the
selected workspace differs from the process working directory.

The visible failure was in workspace module listing coverage. The selected
workspace was discovered correctly, but entries returned by moduleList were
materialized as raw values instead of object results. That made the list result
behave differently from the rest of the schema and left selection-sensitive
metadata commands exposed to the wrong object context.

Fix this by having moduleList return dagql.ObjectResultArray[*WorkspaceModule].
For each configured module entry, moduleList now selects a private
__workspaceModule query field with the module name, entrypoint flag, and source
string. That keeps WorkspaceModule construction on the regular DagQL selection
path, so every list item has the object identity and call chain expected by the
schema and CLI.

Implementation details:

- register a private Query.__workspaceModule field during workspace schema
  installation
- keep Workspace.moduleList responsible for reading and sorting the live
  workspace config
- convert each sorted WorkspaceModule value into a DagQL object result by
  selecting Query.__workspaceModule
- preserve the existing live-config behavior and cache policy of moduleList

This deliberately avoids fabricating result calls by hand. The list entries are
now produced through the same DagQL selector machinery used by normal object
construction, which is easier to reason about and matches existing schema
patterns more closely.

Verified with:

```shell
dagger --progress=plain call engine-dev test --pkg ./core/integration --run 'TestWorkspaceModules/(TestWorkspaceModuleInstall|TestWorkspaceModuleListing)|TestWorkspaceSelection/TestSelectedWorkspaceMetadataCommands/workspace_list_uses_the_selected_workspace_instead_of_cwd'
```

The run passed:

```text
ok github.com/dagger/dagger/core/integration 55.341s
```

Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Legacy workspace toolchains and blueprints still need their constructor
`+defaultPath` arguments to resolve from the project/workspace context that
consumes them. A previous implementation handled that by checking
`Module.LegacyDefaultPath` inside `ModuleFunction.loadContextualArg` and then
selecting `currentWorkspace.file`/`currentWorkspace.directory` directly at
function-call time.

That made the compat behavior work, but it put the policy in the wrong layer.
Function argument loading already resolves `Directory` and `File` defaults through
`Module.ContextSource`. The workspace loader also already has the information
needed to decide which source should provide default-path context: for legacy
`dagger.json` fields it is the selected legacy project/workspace, and for
related modules of an explicit -m entrypoint it is the consuming module source.
Keeping a second currentWorkspace-based path in modfunc meant legacy modules
could ignore the context source selected while loading the module, which was
fragile for wider workspaces, explicit -W selection, and remote/local module
selection precedence.

Move the legacy compat behavior back into module loading. Pending legacy
toolchains and blueprints now pass `defaultPathContextSourceRef` when they are
loaded through `moduleSource.asModule`. Workspace config entries marked
legacy-default-path do the same. `moduleSource.asModule` already uses that
argument to load the implementation code from the module source while setting
Module.ContextSource to the supplied default-path source, so normal contextual
argument loading can resolve `Directory`, `File`, and `Git` inputs through the same
path as every other module.

With that in place, remove `loadLegacyDefaultPathArg` from core/modfunc.go and
leave `Module.LegacyDefaultPath` as a marker for legacy-projected modules and
cache key variation rather than a call-time resolver switch. The compat caller
still controls the actual context source: local compat resolution maps "." to
the legacy project root, while related modules of an explicit entrypoint keep
using the entrypoint module source as their default-path context.

Add server-side unit coverage for the pending module records so the intended
context source is visible before the dagql asModule call is made. This catches
regressions where a legacy module is marked but no `defaultPathContextSourceRef`
is passed along.

Verified with:
```shell
 dagger --progress=plain call engine-dev test --pkg ./engine/server --run 'Test(PendingLegacyModule|WorkspaceConfigPendingModules)'
```

which passed with:

```shell
    ok github.com/dagger/dagger/engine/server 0.030s
```

and:

```shell
    dagger --progress=plain call engine-dev test --pkg ./core/integration --run 'TestWorkspaceCompat/TestLegacyBlueprintInit/local_legacy_blueprint_init_still_works|TestWorkspaceCompat/TestCompat(BlueprintDefaults|ToolchainDefaults)/outer_envfile_outer_workdir'
```

which passed with:

```shell
    ok github.com/dagger/dagger/core/integration 47.617s
```

Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
Problem
-------
Legacy `dagger.json` lets each `toolchains[]` entry carry per-edge
metadata that describes how the parent project consumes that toolchain:

  - `ignoreChecks`     — exclude check names/globs from `dagger check`
  - `ignoreGenerators` — exclude generator names/globs from `dagger generate`
  - `ignoreServices`   — exclude services from `dagger up`

The recent workspace refactor flattened `toolchains[]` into sibling
workspace modules. These per-edge fields had no destination in the new
`.dagger/config.toml` format, were silently dropped, and the silent drop
regressed real behavior on legacy projects (filters silently ignored).

Decision
--------
After review with Solomon, the chosen direction is migration + new UX,
not runtime retrocompat. The new workspace-config format gains
first-class equivalents and `dagger migrate` translates the legacy
fields into them. Runtime compat for these three fields is intentionally
dropped — users on a legacy `dagger.json` must run `dagger migrate` to
recover the behavior.

New TOML syntax
---------------

  [modules.foo]
  up.skip       = ["redis", "infra:database"]
  generate.skip = ["other-generators:*"]
  check.skip    = ["flaky-check"]

Solution
--------
1. New schema on `ModuleEntry`: three nested `Skip []string` fields,
   one per action (up/generate/check). Read by the corresponding schema
   resolver from the served workspace's parsed `.dagger/config.toml`.
2. The legacy compat reader (`toolchainIgnorePatterns`, which scanned
   `src.ConfigToolchains`) is removed from the resolvers — that's the
   "no retrocompat" decision in code form.
3. `CompatWorkspace.WorkspaceConfig()` (used by `dagger migrate`)
   folds each legacy `tc.IgnoreChecks` / `IgnoreGenerators` /
   `IgnoreServices` onto the corresponding skip slice on the emitted
   `ModuleEntry`, so a migrated project's TOML carries the equivalent
   shape.

Non-obvious choices
-------------------
- Nested struct (`ModuleEntry.Up.Skip`) rather than flat tag
  `toml:"up.skip"`: pelletier go-toml v1 splits dotted TOML keys into a
  tree before binding to struct tags by single segment, so a flat tag
  literally never matches the dotted-key form Solomon specified.
- Migration reads `compatWorkspace.Config.Toolchains` directly inside
  `WorkspaceConfig()` rather than carrying the ignore lists through
  `CompatWorkspaceModule`. The ignore data is only needed at migration
  time — keeping it off the projection struct avoids polluting a
  runtime type with migration-only fields.

Tests
-----
Coverage matches the established pattern (one direct test per feature
area + one migration test), so each resolver is exercised by both
formats.

Direct (`.dagger/config.toml` written with new TOML, runtime asserted):

  - generators_test.go::GeneratorsSuite.TestWorkspaceGenerateSkip
  - up_test.go::UpSuite.TestWorkspaceUpSkip
  - checks_test.go::ChecksSuite.TestWorkspaceCheckSkip

Migration (legacy `dagger.json` → `dagger migrate -y` → assert TOML +
runtime):

  - workspace_compat_test.go::WorkspaceCompatSuite.TestCompatMigrationToolchainSkipFields
    feeds a legacy `dagger.json` containing
    `toolchains[].ignoreGenerators`, runs `dagger migrate -y`, asserts
    the produced `.dagger/config.toml` contains the new
    `generate.skip = [...]` syntax, then runs `dagger generate -l` and
    `dagger generate <pattern>` to assert runtime filtering honors the
    migrated config end-to-end.

Unit:

  - legacy_test.go::TestWorkspaceConfigMigratesToolchainSkipFields
    constructs a `CompatWorkspace` with all three legacy ignore
    fields, calls `WorkspaceConfig()`, and asserts both struct shape
    and TOML round-trip via `SerializeConfig`/`ParseConfig`.

The legacy `TestToolchainIgnoreGenerators` and `TestUpIgnoreServices`
tests (which exercised compat-mode runtime for the dropped legacy
fields) are removed; their coverage is subsumed by the direct +
migration tests above.

`TestUpPortMapping` is `t.Skip`-ed pending the next commit (top-level
`[ports.<host>]` syntax + migration of legacy
`toolchains[].portMappings`).

Signed-off-by: Guillaume de Rouville <[email protected]>
Signed-off-by: Yves Brissaud <[email protected]>
dawg and others added 4 commits June 2, 2026 18:40
Remove module catalog placeholders for repos that do not load and rewrite the remaining official module pages around purpose, usage, and check or generate workflows.

Signed-off-by: dawg <[email protected]>
Replace broken workflow tables with plain lists, remove the module index start-here block, and explain how each module connects to dagger check, dagger generate, and workspace settings.

Signed-off-by: dawg <[email protected]>
Expose local git state from the current Workspace without requiring users to model the workspace as a remote-oriented GitRepository.

Workspace.git returns a WorkspaceGit object. WorkspaceGit.head returns the checked-out HEAD as a GitRef, and WorkspaceGit.uncommitted returns the same Changeset shape and dirty/clean semantics as GitRepository.uncommitted.

On 1.0-beta, workspace detection is already rooted at the git boundary, so Workspace.git validates the .git entry at call time instead of persisting a separate HasGit bit. The repository is materialized from the workspace root, not the current workspace cwd, so nested cwd calls still report whole-repository dirty state.

Git worktrees remain an explicit first-pass boundary because their .git file points at metadata outside the workspace boundary.

Generated GraphQL docs and SDK bindings were refreshed with:

    DAGGER_CLOUD_ENGINE=1 dagger --cloud generate --progress=plain -y

Verification:

    GOMAXPROCS=2 go test ./core/workspace ./core/schema

    DAGGER_CLOUD_ENGINE=1 dagger --cloud -m toolchains/engine-dev call test --progress=plain --pkg=./core/integration --run=TestWorkspace/TestWorkspaceGit --test-verbose --timeout=20m

Signed-off-by: Solomon Hykes <[email protected]>
@dagger-codex

dagger-codex Bot commented Jun 3, 2026 •

Copy link
Copy Markdown
Contributor

Outstanding tester feedback/topics from the 1.0 beta Discord thread that do not look explicit in this PR task list yet:

  • SDK helper regression coverage gap

    • TLDR: SDK wrapper helpers broke under beta because the fix lacked beta-schema/helper-build regression coverage.
    • Vito: "don't actually know how to verify it works though" (Discord)
    • Solomon: "the hardcoded wrapper go image & go.mod didn't fit. how come tests missed it?" (Discord)
    • Suggested tracking: beta-schema e2e for sdk-sdk/dang-sdk helper wrappers, plus a GOTOOLCHAIN=local or static image-vs-go.mod guard.
  • Nested sessions + view filters

    • TLDR: Nested sessions may apply schema views with the wrong client version, hiding/exposing the wrong APIs.
    • Vito: "in nested sessions the client version is essentially ignored, would be nice to apply view filters there too somehow" (Discord)
    • Suggested tracking: engine follow-up for applying view filters according to the requesting/nested client version.
  • Unpinned dependency behavior in dagger.json

    • TLDR: Decide whether unpinned module deps are valid compatibility or a 1.0-beta regression.
    • Solomon: "unpinned dependencies are allowed in dagger.json. Possibly a 1.0-beta regression?" (Discord)
    • Vito: "i wouldn't be surprised if that always worked... unpinned SDK module refs work fine too" (Discord)
    • Suggested tracking: decide whether this is intended compatibility or a 1.0-beta regression, then codify it.
  • Cloud automation for SDK dependency bumps

    • TLDR: Cloud could prevent SDK dependency drift by auto-testing dependency bumps and opening PRs.
    • Solomon: "detecting the dependency bump, proactively testing it, and opening a PR to make the bump if checks pass" (Discord)
    • Suggested tracking: product/Cloud follow-up, not necessarily a blocker for this PR.
  • Tester-role/request tracking, ops-only

    • TLDR: Tester recruitment needs an ops-owned list/role, separate from code PR tracking.
    • Daniel: "Can I become a tester?" (Discord)
    • Daniel clarifying tester-role ask (Discord)
    • Suggested tracking: Discord/ops list, not a code task.

eunomie and others added 7 commits June 4, 2026 02:07
…egen (#13309)

* fix: authenticate private git module dependencies during codegen

`dagger generate` runs an SDK module's generator (e.g. github.com/dagger/go-sdk)
as module code, and codegen itself runs in a further nested exec. Resolving the
module's declared git dependencies (and git-based SDK) happens under those nested
clients, whose context may hold neither the user's git config nor a git binary.
The git resolver only forwards the host's implicit credentials for the main
client, so resolving a private dependency failed with "git authentication
failed" — even though `dagger develop` and `dagger -m <private-ref>` both worked.

Mark module dependency/SDK resolution on the context: it is trusted resolution
performed on the user's behalf (the refs come from a module's dagger.json). The
git resolver uses this marker to source the user's credentials even when the
immediate caller is a nested client (implemented in core/schema/git.go).

Signed-off-by: Yves Brissaud <[email protected]>

* fix: fall back to originating client git credentials for trusted dep resolution

When resolving a module's declared git dependency or SDK under a nested client
(e.g. a git-less codegen exec spawned during `dagger generate`), the git resolver
could not obtain the user's credentials: the immediate caller isn't the main
client, and the nearest non-module parent may be a codegen exec that holds
neither the user's git config/credential helper nor a git binary.

For trusted module dependency/SDK resolution (marked via
WithModuleDependencyResolution), try the non-module parent client's credentials
first and fall back to the session's originating (main) client — for both HTTP
credential helpers and the default SSH auth socket. Untrusted/arbitrary git
access from module runtime code is unaffected and still does not implicitly use
host credentials.

Signed-off-by: Yves Brissaud <[email protected]>

* chore: re-gen

Signed-off-by: Yves Brissaud <[email protected]>

---------

Signed-off-by: Yves Brissaud <[email protected]>
Introduce the 1.0 file layout by moving workspace config to root dagger.toml, workspace lock state to root dagger.lock, and current module config to dagger-module.toml.

Keep legacy dagger.json as the frozen JSON module format for compatibility, while loading and writing the current module format through the existing TOML plumbing.

Migrate legacy workspaces into the new layout, preserve module dependency pins in dagger-module.toml, move legacy .dagger/lock forward with fallback reads, and keep migration reports under .dagger as one-time review artifacts.

Scope migration to the selected legacy project and its conventional .dagger/modules tree so unrelated testdata, examples, and nested projects are not rewritten from a parent migration.

Remove modules.resolve from the lockfile model so module loading follows the same runtime Git/container lookup policy as the rest of the engine.

Regenerate schema, SDK, API, and docs surfaces so the public contract matches the new names.

Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: kpenfound <[email protected]>
Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
Resolve clean local workspaces to their current git commit before looking up Cloud Checks results. Replay past results only when a remote workspace address is available and the workspace is clean; otherwise run checks locally.

Add explicit --past, --no-past, and --run controls, and refresh the generated CLI reference docs.

Signed-off-by: Solomon Hykes <[email protected]>
* Merge main into 1.0-beta

Conflict resolution details with original conflict hunks and resolved hunks.

1. Deleted module mega-test vs main never-cache regression

Original conflict: 1.0-beta deleted the old mega-test as part of the split, while main added a regression to that deleted file.

```diff
diff --git a/core/integration/module_test.go b/core/integration/module_test.go
index 3926492..e86849c 100644
--- a/core/integration/module_test.go
+++ b/core/integration/module_test.go
@@ -7531,6 +7531,24 @@ func (m *Test) ObjsWithNothing() ([]*Test, error) {
 	require.JSONEq(t, `{"objsWithNothing":[null,{"dirs":[null]}]}`, out)
 }

+func (ModuleSuite) TestNeverCacheModuleObjectReturn(ctx context.Context, t *testctx.T) {
+	c := connect(ctx, t)
+
+	modGen := modInit(t, c, "go", `package main
+
+type Test struct{}
+
+// +cache="never"
+func (m *Test) Touch() *Test {
+	return m
+}
+`)
+
+	out, err := modGen.With(daggerCall("touch")).Stdout(ctx)
+	require.NoError(t, err)
+	require.Contains(t, out, "Test@")
+}
+
 func (ModuleSuite) TestFunctionCacheControl(ctx context.Context, t *testctx.T) {
```

Resolution: keep beta's deleted mega-test, port the regression to the split runtime behavior test, and put the test module function in beta's existing runtime cache-control fixture.

```diff
diff --git a/core/integration/module_runtime_behavior_test.go b/core/integration/module_runtime_behavior_test.go
@@ -378,6 +378,14 @@ func (ModuleSuite) TestReturnNil(ctx context.Context, t *testctx.T) {
 	require.JSONEq(t, `{"objsWithNothing":[null,{"dirs":[null]}]}`, out)
 }

+func (ModuleSuite) TestNeverCacheModuleObjectReturn(ctx context.Context, t *testctx.T) {
+	c := connect(ctx, t)
+	modGen := moduleFixture(t, c, "go/runtime-cache-control")
+	out, err := modGen.With(daggerCall("touch")).Stdout(ctx)
+	require.NoError(t, err)
+	require.Contains(t, out, "Test@")
+}
+
 func (ModuleSuite) TestFunctionCacheControl(ctx context.Context, t *testctx.T) {
diff --git a/core/integration/testdata/modules/go/runtime-cache-control/main.go b/core/integration/testdata/modules/go/runtime-cache-control/main.go
@@ -17,6 +17,11 @@ func (m *Test) TestNeverCache() string {
 	return rand.Text()
 }

+// +cache="never"
+func (m *Test) Touch() *Test {
+	return m
+}
+
 // My rad doc on TestAlwaysCache
```

2. Shell helper command path

Original conflict: main moved the helper to `dagger shell`, while beta added `daggerShellAt` and root-shell `-m` support.

```diff
diff --cc core/integration/shell_test.go
@@@ -32,16 -22,8 +32,20 @@@ func TestShell(t *testing.T)
  }

  func daggerShell(script string) dagger.WithContainerFunc {
 +	return daggerShellAt("", script)
 +}
 +
 +func daggerShellAt(modPath, script string) dagger.WithContainerFunc {
  	return func(c *dagger.Container) *dagger.Container {
++<<<<<<< HEAD:core/integration/shell_test.go
 +		execArgs := []string{"dagger"}
 +		if modPath != "" {
 +			execArgs = append(execArgs, "-m", modPath)
 +		}
 +		return c.WithExec(execArgs, dagger.ContainerWithExecOpts{
++=======
+		return c.WithExec([]string{"dagger", "shell"}, dagger.ContainerWithExecOpts{
++>>>>>>> origin/main:core/integration/module_shell_test.go
  			Stdin:                         script,
  			ExperimentalPrivilegedNesting: true,
  		})
@@ -50,7 +54,7 @@ func daggerShellAt(modPath, script string) dagger.WithContainerFunc {

 func daggerShellNoMod(script string) dagger.WithContainerFunc {
 	return func(c *dagger.Container) *dagger.Container {
-		return c.WithExec([]string{"dagger", "-M"}, dagger.ContainerWithExecOpts{
+		return c.WithExec([]string{"dagger", "shell", "-M"}, dagger.ContainerWithExecOpts{
 			Stdin:                         script,
 			ExperimentalPrivilegedNesting: true,
 		})
 	}
 }
```

Resolution: combine main's explicit `dagger shell` invocation with beta's `daggerShellAt` helper. `daggerShellAt` now starts from `dagger shell` and appends `-m <path>` when needed, while `daggerShellNoMod` uses `dagger shell -M`.

```diff
diff --git a/core/integration/shell_test.go b/core/integration/shell_test.go
@@ -37,18 +37,18 @@ func daggerShell(script string) dagger.WithContainerFunc {

 func daggerShellAt(modPath, script string) dagger.WithContainerFunc {
 	return func(c *dagger.Container) *dagger.Container {
-		execArgs := []string{"dagger"}
+		execArgs := []string{"dagger", "shell"}
 		if modPath != "" {
 			execArgs = append(execArgs, "-m", modPath)
 		}
 		return c.WithExec(execArgs, dagger.ContainerWithExecOpts{
 			Stdin:                         script,
 			ExperimentalPrivilegedNesting: true,
 		})
 	}
 }

 func daggerShellNoMod(script string) dagger.WithContainerFunc {
 	return func(c *dagger.Container) *dagger.Container {
-		return c.WithExec([]string{"dagger", "-M"}, dagger.ContainerWithExecOpts{
+		return c.WithExec([]string{"dagger", "shell", "-M"}, dagger.ContainerWithExecOpts{
 			Stdin:                         script,
 			ExperimentalPrivilegedNesting: true,
 		})
 	}
 }
```

3. Deleted container cookbook page vs volatile variable docs

Original conflict: beta deleted the old cookbook page in the docs restructure; main added volatile variable guidance there.

```diff
diff --git a/docs/current_docs/cookbook/containers.mdx b/docs/current_docs/cookbook/containers.mdx
index 4bf6e79..b97d036 100644
--- a/docs/current_docs/cookbook/containers.mdx
+++ b/docs/current_docs/cookbook/containers.mdx
@@ -18,3 +18,24 @@ Dagger allows you to build, publish, and export container images, also known as
 <ExportContainerImageToHost />

 <SetEnvVar />
+
+## Use volatile variables for exec-time metadata
+
+`withVolatileVariable` sets a non-secret environment variable for future `withExec` calls without invalidating exec cache when only the variable's value changes.
+
+Typical examples include CI and reporting metadata such as:
+- commit SHA
+- branch or ref
+- CI run ID
+
+:::warning
+`withVolatileVariable` is an expert-only escape hatch. Use it only when you are certain that changing the variable alone must not invalidate cached `withExec` results. If that assumption is wrong, Dagger may reuse stale or incorrect cached results.
+:::
```

Resolution: keep the cookbook deletion and move the content to the beta Container type page, which now owns Container behavior docs.

```diff
diff --git a/docs/current_docs/extending/types/container.mdx b/docs/current_docs/extending/types/container.mdx
@@ -60,3 +60,30 @@ The default address can be any valid container image reference, such as:
 - `alpine:3.19` - Docker Hub image with specific version
 - `ghcr.io/owner/image:tag` - GitHub Container Registry image
 - `gcr.io/project/image:tag` - Google Container Registry image
+
+## Volatile variables
+
+`withVolatileVariable` sets a non-secret environment variable for future
+`withExec` calls without invalidating exec cache when only the variable's value
+changes.
+
+Typical examples include CI and reporting metadata such as commit SHAs, branch
+or ref names, and CI run IDs.
+
+:::warning
+`withVolatileVariable` is an expert-only escape hatch. Use it only when you are
+certain that changing the variable alone must not invalidate cached `withExec`
+results. If that assumption is wrong, Dagger may reuse stale or incorrect
+cached results.
+:::
```

4. Deleted function-caching page vs volatile variable cache note

Original conflict: beta deleted the old function caching module page; main added a cache note there.

```diff
diff --git a/docs/current_docs/extending/modules/function-caching.mdx b/docs/current_docs/extending/modules/function-caching.mdx
index 707c1a3..6622233 100644
--- a/docs/current_docs/extending/modules/function-caching.mdx
+++ b/docs/current_docs/extending/modules/function-caching.mdx
@@ -252,6 +252,8 @@ This means:
 If you need a specific step to always re-run, add a cache-busting input to that step (for example, a
 timestamp environment variable used only for that operation).

+If you need non-secret metadata to be visible to a `withExec` step without invalidating cache when only that metadata changes, use `withVolatileVariable` on the `Container`. This is an expert-only escape hatch: cached `withExec` results may be reused even when the volatile value changes, and reruns caused by other inputs will see the latest volatile value. See the [container cookbook](../../cookbook/containers.mdx#use-volatile-variables-for-exec-time-metadata).
+
 ### Secrets and caching
```

Resolution: keep the page deletion and move the cache behavior note to beta's new cache explainer, with a link to the new Container section.

```diff
diff --git a/docs/current_docs/extending/how-dagger-works/cache.mdx b/docs/current_docs/extending/how-dagger-works/cache.mdx
@@ -14,6 +14,20 @@ Different inputs: Dagger reruns the affected work.

 This is why module API design affects speed.

+## Function Cache Hits
+
+A function cache hit skips the function entirely, so none of its internal steps
+run. A cache miss runs the function, but individual container/file steps inside
+it may still be cache hits if their inputs are unchanged.
+
+If you need a specific step to always re-run, add a cache-busting input to that
+step. If you need non-secret metadata to be visible to a `withExec` step without
+invalidating cache when only that metadata changes, use
+`withVolatileVariable` on the `Container`. Cached `withExec` results may be
+reused even when the volatile value changes, and reruns caused by other inputs
+will see the latest volatile value. See
+[Container volatile variables](../types/container.mdx#volatile-variables).
+
 ## Inputs Matter
```

5. Dang dependency version

Original conflict: beta had an earlier Dang pseudo-version; main had a newer one.

```diff
diff --cc go.mod
@@@ -152,7 -151,7 +152,11 @@@ require
  	github.com/urfave/cli v1.22.17
  	github.com/vektah/gqlparser/v2 v2.5.32
  	github.com/vito/bubbline v0.0.0-20250312195236-5f4f49d6ebcb
++<<<<<<< HEAD
 +	github.com/vito/dang v0.0.0-20260527191113-ad5bca2669a9
++=======
+	github.com/vito/dang v0.0.0-20260602175442-56ec0c007a23
++>>>>>>> origin/main
  	github.com/vito/go-interact v1.0.2
```

Resolution: take main's newer Dang because the merged `core/sdk/dang_helpers.go` uses the newer `dang.FieldDecl` API; go.sum follows the same version choice.

```diff
diff --git a/go.mod b/go.mod
@@ -152,7 +152,7 @@ require (
 	github.com/urfave/cli v1.22.17
 	github.com/vektah/gqlparser/v2 v2.5.32
 	github.com/vito/bubbline v0.0.0-20250312195236-5f4f49d6ebcb
-	github.com/vito/dang v0.0.0-20260527191113-ad5bca2669a9
+	github.com/vito/dang v0.0.0-20260602175442-56ec0c007a23
 	github.com/vito/go-interact v1.0.2
```

6. Generated ConfigSchema client comments

Original conflict: repeated in the generated engine-dev/dagger-engine clients. Beta listed the new workspace schema files; main kept the old list but shifted the source line.

```diff
diff --cc modules/dev/internal/dagger/engine-dev.gen.go
@@@ -278,8 -277,8 +277,13 @@@ func (r *EngineDev) ClientDockerConfig(
  }

  // Generate the json schema for a dagger config file
++<<<<<<< HEAD
 +// Currently supported: "dagger.json", "dagger-module.toml", "dagger.toml", "engine.json"
 +func (r *EngineDev) ConfigSchema(filename string) *File { // engine-dev (../../../../toolchains/engine-dev/main.go:359:1)
++=======
+ // Currently supported: "dagger.json", "engine.json"
+ func (r *EngineDev) ConfigSchema(filename string) *File { // engine-dev (../../../../toolchains/engine-dev/main.go:362:1)
++>>>>>>> origin/main
```

Resolution: keep beta's expanded schema filename list and main's shifted line number, matching the merged source at `toolchains/engine-dev/main.go:362`.

```diff
diff --git a/modules/dev/internal/dagger/engine-dev.gen.go b/modules/dev/internal/dagger/engine-dev.gen.go
@@ -278,8 +278,8 @@ func (r *EngineDev) ClientDockerConfig() *Secret {
 }

 // Generate the json schema for a dagger config file
-// Currently supported: "dagger.json", "dagger-module.toml", "dagger.toml", "engine.json"
-func (r *EngineDev) ConfigSchema(filename string) *File { // engine-dev (../../../../toolchains/engine-dev/main.go:359:1)
+// Currently supported: "dagger.json", "dagger-module.toml", "dagger.toml", "engine.json"
+func (r *EngineDev) ConfigSchema(filename string) *File { // engine-dev (../../../../toolchains/engine-dev/main.go:362:1)
```

7. Helper removed by beta split but referenced by merged main test

Original conflict effect: main's engine persistence test now used the helper from lockfile tests, while beta removed that helper with the lockfile split.

```diff
diff --git a/core/integration/engine_persistence_test.go b/core/integration/engine_persistence_test.go
@@ -1127,6 +1127,7 @@ git -C /root/srv/repo.git update-server-info
 		hostname := identity.NewID() + ".test"
 		gitSvc, repoBaseURL := gitSmartHTTPServiceDirAuth(ctx, t, c, hostname, gitDir, "", nil)
 		repoURL := repoBaseURL + "/repo.git"
+		gitHost := moduleResolveServiceHost(t, repoURL)
```

Resolution: add the small URL host helper beside the test that now needs it, without restoring the removed lockfile helper section.

```diff
diff --git a/core/integration/engine_persistence_test.go b/core/integration/engine_persistence_test.go
@@ -11,6 +11,7 @@ import (
 	"context"
 	"crypto/rand"
 	"fmt"
+	"net/url"
 	"os"
@@ -25,6 +26,17 @@ import (
 	"dagger.io/dagger"
 )

+func moduleResolveServiceHost(t *testctx.T, rawURL string) string {
+	t.Helper()
+	parsed, err := url.Parse(rawURL)
+	require.NoError(t, err)
+	host := parsed.Hostname()
+	require.NotEmpty(t, host)
+	return host
+}
+
 func (CachePersistenceSuite) TestDiskPersistenceAcrossRestart(ctx context.Context, t *testctx.T) {
```

CI follow-up: release publish dry-run in cache persistence now loads the synthetic release repo as a workspace with `-W "$MODULE_REF"` instead of as an extra module with `-m "$MODULE_REF"`. The synthetic root still uses workspace-only toolchains, so this matches the CLI migration path while preserving the dry-run assertions.

Signed-off-by: Tibor Vass <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>

* Run dagger generate

Signed-off-by: Tibor Vass <[email protected]>
Signed-off-by: Solomon Hykes <[email protected]>
* core: expose source-backed workspace constructors

Add the public synthetic workspace entry points on source objects: Directory.asWorkspace and GitRepository.asWorkspace. The root Query.workspace constructor is removed from the public schema so callers construct workspaces from the object that owns the root.

Rootfs-backed workspaces keep filesystem APIs available, return slash-normalized cwd values, and reject local-only config/module/env mutations that require a host workspace.

Signed-off-by: Solomon Hykes <[email protected]>

* cmd/dagger: handle slash-style workspace cwd

Treat public workspace cwd values as slash-style API paths when deriving local roots from cwd or addresses. Nested cwd suffixes must match the working directory/address exactly, and escaping cwd values are rejected.

This fixes the review failure where the CLI still expected relative cwd values like . and app after the Workspace API switched to / and /app.

Signed-off-by: Solomon Hykes <[email protected]>

* test: cover synthetic workspace roots

Add integration coverage for directory- and git-backed synthetic workspaces, including cwd resolution, unsupported local-only operations, empty module lists, and git metadata behavior.

Update existing workspace tests to assert the public cwd format as slash-style paths such as / and /services/api.

Signed-off-by: Solomon Hykes <[email protected]>

* docs: record synthetic workspace API cleanup

Add reviewer notes for the source-object constructor UX used by this PR and capture the remaining cleanup work for separating filesystem workspace APIs from local host mutation APIs.

The note documents the current compatibility contract instead of presenting the future cleanup as an accidental merge blocker.

Signed-off-by: Solomon Hykes <[email protected]>

* chore: regenerate workspace API outputs

Regenerate GraphQL reference docs and SDK clients after moving synthetic workspace construction to Directory.asWorkspace and GitRepository.asWorkspace.

Generated with:

    dagger --x-release=v0.21.4 generate -y

This matches the Dagger version used by CI for generation.

Signed-off-by: Solomon Hykes <[email protected]>

* chore: regenerate php-sdk:api

Signed-off-by: Tibor Vass <[email protected]>

---------

Signed-off-by: Solomon Hykes <[email protected]>
Signed-off-by: Tibor Vass <[email protected]>
Co-authored-by: Solomon Hykes <[email protected]>
Co-authored-by: Tibor Vass <[email protected]>
dagger-codex Bot pushed a commit that referenced this pull request Jun 5, 2026
Conflict resolution details with original conflict hunks and resolved hunks.

1. Deleted module mega-test vs main never-cache regression

Related PRs: beta #11812, main #13298.

Original conflict: 1.0-beta deleted the old module mega-test after splitting module coverage, while main added the never-cache object-return regression to the deleted file.

```diff
diff --git a/core/integration/module_test.go b/core/integration/module_test.go
@@ -7531,6 +7531,24 @@ func (m *Test) ObjsWithNothing() ([]*Test, error) {
+
+func (ModuleSuite) TestNeverCacheModuleObjectReturn(ctx context.Context, t *testctx.T) {
+    c := connect(ctx, t)
+    modGen := modInit(t, c, "go", `package main
+
+type Test struct{}
+
+// +cache="never"
+func (m *Test) Touch() *Test {
+    return m
+}
+`)
+    out, err := modGen.With(daggerCall("touch")).Stdout(ctx)
+    require.NoError(t, err)
+    require.Contains(t, out, "Test@")
+}
```

Resolution: keep beta's deleted mega-test because the regression is already ported to beta's split runtime behavior test and runtime cache-control fixture from the previous merge.

```diff
diff --git a/core/integration/module_runtime_behavior_test.go b/core/integration/module_runtime_behavior_test.go
@@
 func (ModuleSuite) TestNeverCacheModuleObjectReturn(ctx context.Context, t *testctx.T) {
     c := connect(ctx, t)
     modGen := moduleFixture(t, c, "go/runtime-cache-control")
     out, err := modGen.With(daggerCall("touch")).Stdout(ctx)
     require.NoError(t, err)
     require.Contains(t, out, "Test@")
 }
diff --git a/core/integration/testdata/modules/go/runtime-cache-control/main.go b/core/integration/testdata/modules/go/runtime-cache-control/main.go
@@
 // +cache="never"
 func (m *Test) Touch() *Test {
     return m
 }
```

2. Shell helper command path

Related PRs: beta #11812, main #13239.

Original conflict: main's helper calls `dagger shell`, while beta's helper supports root-shell module paths through `daggerShellAt`.

```diff
diff --cc core/integration/shell_test.go
@@
 func daggerShellAt(modPath, script string) dagger.WithContainerFunc {
     return func(c *dagger.Container) *dagger.Container {
++<<<<<<< HEAD:core/integration/shell_test.go
+        execArgs := []string{"dagger", "shell"}
+        if modPath != "" {
+            execArgs = append(execArgs, "-m", modPath)
+        }
+        return c.WithExec(execArgs, dagger.ContainerWithExecOpts{
++=======
+        return c.WithExec([]string{"dagger", "shell"}, dagger.ContainerWithExecOpts{
++>>>>>>> origin/main:core/integration/module_shell_test.go
```

Resolution: combine both concerns: always invoke `dagger shell`, and append beta's `-m <path>` only when the helper receives a module path. `daggerShellNoMod` already remains `dagger shell -M`.

```diff
diff --git a/core/integration/shell_test.go b/core/integration/shell_test.go
@@
 func daggerShellAt(modPath, script string) dagger.WithContainerFunc {
     return func(c *dagger.Container) *dagger.Container {
         execArgs := []string{"dagger", "shell"}
         if modPath != "" {
             execArgs = append(execArgs, "-m", modPath)
         }
         return c.WithExec(execArgs, dagger.ContainerWithExecOpts{
```

3. Release dry-run workspace loading

Related PRs: beta #13327, main #13285.

Original conflict: beta fixed the cache-persistence release dry-run to load the synthetic repo as a workspace; main still loaded it as an extra module. The synthetic repo root uses workspace-only toolchains, so `-m` fails with the workspace migration error.

```diff
diff --cc core/integration/engine_persistence_test.go
@@
 script := `set +e
++<<<<<<< HEAD
+/bin/dagger --progress=plain -W "$MODULE_REF" call release publish --tag "$RELEASE_TAG" --commit "$RELEASE_COMMIT" --dry-run=true markdown > /tmp/publish.log 2>&1
++=======
+/bin/dagger --progress=plain -m "$MODULE_REF" call release publish --tag "$RELEASE_TAG" --commit "$RELEASE_COMMIT" --dry-run=true markdown > /tmp/publish.log 2>&1
++>>>>>>> origin/main
```

Resolution: keep beta's `-W "$MODULE_REF"` workspace load, preserving the previous CI fix and the dry-run assertions.

```diff
diff --git a/core/integration/engine_persistence_test.go b/core/integration/engine_persistence_test.go
@@
 /bin/dagger --progress=plain -W "$MODULE_REF" call release publish --tag "$RELEASE_TAG" --commit "$RELEASE_COMMIT" --dry-run=true markdown > /tmp/publish.log 2>&1
```

4. Module workspace config fields

Related PRs: beta #13300, main #13329.

Original conflict: main added legacy argument customizations to `Module`, while beta renamed and documented workspace settings from `dagger.toml`.

```diff
diff --cc core/module.go
@@
++<<<<<<< HEAD
+    // Workspace setting values from dagger.toml [modules.<name>.settings].
++=======
+    // LegacyArgCustomizations are workspace dagger.json argument customizations
+    // applied through asModule.
+    LegacyArgCustomizations []*modules.ModuleConfigArgument
+
+    // Config values from workspace config.toml [modules.<name>.config].
++>>>>>>> origin/main
     // Typed map: strings, bools, ints, floats as-is from TOML.
     // When set, constructor args are resolved from this map first.
     WorkspaceConfig map[string]any
```

Resolution: keep both fields: main's `LegacyArgCustomizations` is still used by merged `modulesource.go`, and beta's `WorkspaceConfig` comment reflects the current 1.0-beta `dagger.toml` settings model.

```diff
diff --git a/core/module.go b/core/module.go
@@
     // LegacyArgCustomizations are workspace dagger.json argument customizations
     // applied through asModule.
     LegacyArgCustomizations []*modules.ModuleConfigArgument

     // Workspace setting values from dagger.toml [modules.<name>.settings].
     // Typed map: strings, bools, ints, floats as-is from TOML.
     // When set, constructor args are resolved from this map first.
     WorkspaceConfig map[string]any
```

5. Dang API rename vs beta closure fix

Related PRs: beta #13296, main #13318.

Original conflict: main upgraded Dang and renamed class APIs to object APIs; beta used the constructor closure to preserve imports in rehydrated method calls.

```diff
diff --cc core/sdk/dang_helpers.go
@@
 parentConstructor := parentModBase.(*dang.ConstructorFunction)
++<<<<<<< HEAD
+parentModType := parentConstructor.ClassType
+// Use the class file's captured env so rehydrated method calls keep the
+// imports that were in scope when the type was declared.
+parentClosure := parentConstructor.Closure
++=======
+parentModType := parentConstructor.ObjectType
++>>>>>>> origin/main
@@
++<<<<<<< HEAD
+bodyEnv := dang.CreateCompositeEnv(parentModEnv, parentClosure)
++=======
+bodyEnv := dang.CreateOverlayValueScope(parentModEnv, env)
++>>>>>>> origin/main
```

Resolution: take main's newer Dang API names and dependency, but keep beta's captured `Closure` for conversion and body evaluation. The newer `ConstructorFunction` still exposes `Closure`, so this preserves both the API upgrade and the import-scope fix.

```diff
diff --git a/core/sdk/dang_helpers.go b/core/sdk/dang_helpers.go
@@
 parentConstructor := parentModBase.(*dang.ConstructorFunction)
 parentModType := parentConstructor.ObjectType
 // Use the class file's captured env so rehydrated method calls keep the
 // imports that were in scope when the type was declared.
 parentClosure := parentConstructor.Closure
@@
 parentModEnv := dang.NewObject(parentModType)
@@
 bodyEnv := dang.CreateOverlayValueScope(parentModEnv, parentClosure)
 bodyEnv.EnterSelf(parentModEnv)
 _, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ObjectBodyForms, bodyEnv)
```

6. Dang dependency version

Related PRs: beta #13306, main #13318.

Original conflict: beta had the older Dang pseudo-version; main had the newer version required by the merged object API names.

```diff
diff --cc go.mod
@@
++<<<<<<< HEAD
+    github.com/vito/dang v0.0.0-20260602175442-56ec0c007a23
++=======
+    github.com/vito/dang v0.0.0-20260603200027-0175bae9eb8f
++>>>>>>> origin/main
```

Resolution: take main's newer Dang dependency and matching go.sum entries because the source resolution uses the newer object API.

```diff
diff --git a/go.mod b/go.mod
@@
     github.com/vito/dang v0.0.0-20260603200027-0175bae9eb8f
```

7. Generated ConfigSchema comments

Related PRs: beta #13300, main #13035.

Original conflict: beta's generated clients document the expanded workspace config filenames; main's generated clients kept the old file list. Both sides already agreed on the shifted source line.

```diff
diff --cc modules/dev/internal/dagger/engine-dev.gen.go
@@
 // Generate the json schema for a dagger config file
++<<<<<<< HEAD
+// Currently supported: "dagger.json", "dagger-module.toml", "dagger.toml", "engine.json"
++=======
+// Currently supported: "dagger.json", "engine.json"
++>>>>>>> origin/main
 func (r *EngineDev) ConfigSchema(filename string) *File { // engine-dev (../../../../toolchains/engine-dev/main.go:362:1)
```

Resolution: keep beta's expanded filename list in every generated engine-dev/dagger-engine client because `toolchains/engine-dev/main.go` supports the workspace config files.

```diff
diff --git a/modules/dev/internal/dagger/engine-dev.gen.go b/modules/dev/internal/dagger/engine-dev.gen.go
@@
 // Generate the json schema for a dagger config file
 // Currently supported: "dagger.json", "dagger-module.toml", "dagger.toml", "engine.json"
 func (r *EngineDev) ConfigSchema(filename string) *File { // engine-dev (../../../../toolchains/engine-dev/main.go:362:1)
```

8. Current docs restructure vs main docs updates

Related PRs: beta #11812, main #13320 and #13223.

Original conflict: beta's current docs have been restructured and versioned for 1.0-beta, while main still modified or imported content from the older current-docs layout. The modify/delete conflicts were all old current-docs pages such as cookbook pages, old module pages, old quickstarts, old type pages, and old best-practice pages.

```diff
diff --git a/docs/current_docs/cookbook/containers.mdx b/docs/current_docs/cookbook/containers.mdx
deleted in HEAD, modified in origin/main
```

Resolution: keep beta's current-docs restructure and deletions. Non-conflicting main additions such as versioned docs and static reference assets stay in the merge, but old pre-restructure `current_docs` pages are not reintroduced.

```diff
diff --git a/docs/current_docs/cookbook/containers.mdx b/docs/current_docs/cookbook/containers.mdx
deleted file mode 100644
```

9. Existing 1.0-beta docs pages vs main old imports/links

Related PRs: beta #13338, main #13320 and #13223.

Original conflict: for pages that still exist on both sides, main tried to import old cookbook partials or link to old `dagger.json`/core-concepts pages, while beta uses current 1.0-beta aliases and workspace-era wording.

```diff
diff --cc docs/current_docs/extending/types/container.mdx
@@
++<<<<<<< HEAD:docs/current_docs/extending/types/container.mdx
+import ContainerType from "@daggerTypes/_container.mdx";
++=======
+import ContainerType from "../../partials/types/_container.mdx";
+import BuildImageFromDockerfile from '../../partials/cookbook/builds/_image-from-dockerfile.mdx';
++>>>>>>> origin/main:docs/current_docs/getting-started/types/container.mdx
```

Resolution: keep beta's existing 1.0-beta docs files for those content conflicts, including `@daggerTypes` aliases, workspace/checks links, and `dagger-module.toml` wording.

```diff
diff --git a/docs/current_docs/extending/types/container.mdx b/docs/current_docs/extending/types/container.mdx
@@
 import ContainerType from "@daggerTypes/_container.mdx";
```

Signed-off-by: Solomon Hykes <[email protected]>
…ash in fd0021b

This merge commit restores the history link between 1.0-beta branch and main.
It was lost with merge commit fd0021b which
squashed the branch e45e7e4

Git tree on #13327 before squash-merging into 1.0-beta:

```
* e45e7e4 Run dagger generate
*   a01677a Merge main into 1.0-beta
|\
| * 1588421 chore: update daggerverse from 0.21.0 to 0.21.4 (#13328)
| * 20b2554 Simplify function call return handling (#13319)
| * 316ca15 Fix snapshot owner lease attach/remove race (#13321)
| * 6cfdcb4 fix(layercopy): follow source symlinks when copying directory contents (#13326)
| * 16e85ca Container exists expand option (#13310)
| * 54f9811 chore: post-release during v0.21.4 (#13316)
| * de85595 ci: bump default engine version to v0.21.3 (#13315)
| * 81bb907 chore: prep for v0.21.4 (#13314)
| * 0fd148e Show root usage when dagger has no args
| * 219b696 Volatile vars (#13223)
| * fae340c fix(layercopy): materialize resolved parent dirs when writing through… (#13308)
| * b720144 bump dang (#13306)
| * 41a7910 fix(engine): lease parent layer content for tarball export (#13307)
| * b2d43ba fix(core): attach never-cached module function results (#13298)
| * 6a7b3a7 fix incorrect artifact caching issue when releasing  (#13285)
| * 2452472 fix(core/dotenv): accept `export`-prefixed lines in .env files (#13293)
| * 24b06e7 fix: allow empty setSecret name (#13304)
| * f7ea195 fix: handle 1Password secrets with spaces (#13297)
* | 74e1a66 another pass on docs (#13325)
...
|/
* 8cc840f fix(sdk/typescript): resolve referenced values in decorator arguments (#13292)
```

Ran `git merge -s ours 1588421` on 1.0-beta to get this desired git tree:

```
*   ??gitsha?? [1.0-beta] restore merge history with main@15884210ff lost due to squash in fd0021b
|\
| * 1588421 chore: update daggerverse from 0.21.0 to 0.21.4 (#13328)
| ...
* | 94ebacb update sdk docs, type-system docs, and interfaces (#13338)
* | 64eba3f [1.0-beta] feat: support synthetic workspaces (#13217)
* | fd0021b Merge main into 1.0-beta (#13327)
* | c6dd435 fix(cli): refine cloud check replay
* | 74e1a66 another pass on docs (#13325)
```
dagger-codex Bot pushed a commit that referenced this pull request Jun 6, 2026
Conflict resolution details with original conflict hunks and resolved hunks.

1. Module workspace config fields

Related PRs: beta #13300, main #13329.

Original conflict: main added legacy argument customizations to `Module`, while beta renamed and documented workspace settings from `dagger.toml`.

```diff
diff --cc core/module.go
@@
  	LegacyDefaultPath bool

+ 	// LegacyArgCustomizations are workspace dagger.json argument customizations
+ 	// applied through asModule.
+ 	LegacyArgCustomizations []*modules.ModuleConfigArgument
+
- 	// Config values from workspace config.toml [modules.<name>.config].
+ 	// Workspace setting values from dagger.toml [modules.<name>.settings].
  	// Typed map: strings, bools, ints, floats as-is from TOML.
  	// When set, constructor args are resolved from this map first.
  	WorkspaceConfig map[string]any
```

Resolution: keep both fields: main's `LegacyArgCustomizations` is still used by merged `modulesource.go`, and beta's `WorkspaceConfig` comment reflects the current 1.0-beta `dagger.toml` settings model.

```diff
diff --git a/core/module.go b/core/module.go
@@
 	LegacyDefaultPath bool

 	// LegacyArgCustomizations are workspace dagger.json argument customizations
 	// applied through asModule.
 	LegacyArgCustomizations []*modules.ModuleConfigArgument

 	// Workspace setting values from dagger.toml [modules.<name>.settings].
 	// Typed map: strings, bools, ints, floats as-is from TOML.
 	// When set, constructor args are resolved from this map first.
 	WorkspaceConfig map[string]any
```

2. Dang API rename vs beta closure fix

Related PRs: beta #13296, main #13318.

Original conflict: main upgraded Dang and renamed class APIs to object APIs; beta used the constructor closure to preserve imports in rehydrated method calls.

```diff
diff --cc core/sdk/dang_helpers.go
@@
 	parentConstructor := parentModBase.(*dang.ConstructorFunction)
+<<<<<<< HEAD
+	parentModType := parentConstructor.ClassType
+	// Use the class file's captured env so rehydrated method calls keep the
+	// imports that were in scope when the type was declared.
+	parentClosure := parentConstructor.Closure
+=======
+	parentModType := parentConstructor.ObjectType
+>>>>>>> origin/main
@@
+<<<<<<< HEAD
+	bodyEnv := dang.CreateCompositeEnv(parentModEnv, parentClosure)
+=======
+	bodyEnv := dang.CreateOverlayValueScope(parentModEnv, env)
+>>>>>>> origin/main
 	bodyEnv.EnterSelf(parentModEnv)
-	_, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ClassBodyForms, bodyEnv)
+	_, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ObjectBodyForms, bodyEnv)
```

Resolution: take main's newer Dang API names, but keep beta's captured `Closure` for conversion and body evaluation.

```diff
diff --git a/core/sdk/dang_helpers.go b/core/sdk/dang_helpers.go
@@
 	parentConstructor := parentModBase.(*dang.ConstructorFunction)
 	parentModType := parentConstructor.ObjectType
 	// Use the class file's captured env so rehydrated method calls keep the
 	// imports that were in scope when the type was declared.
 	parentClosure := parentConstructor.Closure
@@
 	bodyEnv := dang.CreateOverlayValueScope(parentModEnv, parentClosure)
 	bodyEnv.EnterSelf(parentModEnv)
 	_, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ObjectBodyForms, bodyEnv)
```

3. Current docs restructure vs main docs updates

Related PRs: beta #11812, main #13320 and #13223.

Original conflict: beta's current docs have been restructured and versioned for 1.0-beta, while main still modified or imported content from the older current-docs layout. The modify/delete conflicts were all old current-docs pages such as cookbook pages, old module pages, old quickstarts, old type pages, and old best-practice pages.

```diff
diff --git a/docs/current_docs/cookbook/containers.mdx b/docs/current_docs/cookbook/containers.mdx
deleted in HEAD, modified in origin/main
```

Resolution: keep beta's current-docs restructure and deletions. Non-conflicting main additions such as versioned docs and static reference assets stay in the merge, but old pre-restructure `current_docs` pages are not reintroduced.

```diff
diff --git a/docs/current_docs/cookbook/containers.mdx b/docs/current_docs/cookbook/containers.mdx
deleted file mode 100644
```

4. Existing 1.0-beta docs pages vs main old imports/links

Related PRs: beta #13338, main #13320 and #13223.

Original conflict: for pages that still exist on both sides, main tried to import old cookbook partials or link to old `dagger.json`/core-concepts pages, while beta uses current 1.0-beta aliases and workspace-era wording.

```diff
diff --cc docs/current_docs/extending/types/container.mdx
@@
+<<<<<<< HEAD:docs/current_docs/extending/types/container.mdx
+import ContainerType from "@daggerTypes/_container.mdx";
+=======
+import ContainerType from "../../partials/types/_container.mdx";
+import BuildImageFromDockerfile from '../../partials/cookbook/builds/_image-from-dockerfile.mdx';
+>>>>>>> origin/main:docs/current_docs/getting-started/types/container.mdx
```

Resolution: keep beta's existing 1.0-beta docs files for those content conflicts, including `@daggerTypes` aliases, workspace/checks links, and `dagger-module.toml` wording.

```diff
diff --git a/docs/current_docs/extending/types/container.mdx b/docs/current_docs/extending/types/container.mdx
@@
 import ContainerType from "@daggerTypes/_container.mdx";
```

Signed-off-by: Solomon Hykes <[email protected]>
dagger-codex Bot pushed a commit that referenced this pull request Jun 6, 2026
Conflict resolution details with original conflict hunks and resolved hunks.

1. Module workspace config fields

Related PRs: beta #13300, main #13329.

Original conflict: main added legacy argument customizations to `Module`, while beta renamed and documented workspace settings from `dagger.toml`.

```diff
diff --cc core/module.go
@@
        LegacyDefaultPath bool

+       // LegacyArgCustomizations are workspace dagger.json argument customizations
+       // applied through asModule.
+       LegacyArgCustomizations []*modules.ModuleConfigArgument
+
-       // Config values from workspace config.toml [modules.<name>.config].
+       // Workspace setting values from dagger.toml [modules.<name>.settings].
        // Typed map: strings, bools, ints, floats as-is from TOML.
        // When set, constructor args are resolved from this map first.
        WorkspaceConfig map[string]any
```

Resolution: keep both fields. Main's `LegacyArgCustomizations` is still used by merged `modulesource.go`, and beta's `WorkspaceConfig` comment reflects the current 1.0-beta `dagger.toml` settings model.

```diff
diff --git a/core/module.go b/core/module.go
@@
        LegacyDefaultPath bool

        // LegacyArgCustomizations are workspace dagger.json argument customizations
        // applied through asModule.
        LegacyArgCustomizations []*modules.ModuleConfigArgument

        // Workspace setting values from dagger.toml [modules.<name>.settings].
        // Typed map: strings, bools, ints, floats as-is from TOML.
        // When set, constructor args are resolved from this map first.
        WorkspaceConfig map[string]any
```

2. Dang API rename vs beta closure fix

Related PRs: beta #13296, main #13318.

Original conflict: main upgraded Dang and renamed class APIs to object APIs; beta used the constructor closure to preserve imports in rehydrated method calls.

```diff
diff --cc core/sdk/dang_helpers.go
@@
        parentConstructor := parentModBase.(*dang.ConstructorFunction)
+<<<<<<< HEAD
+       parentModType := parentConstructor.ClassType
+       // Use the class file's captured env so rehydrated method calls keep the
+       // imports that were in scope when the type was declared.
+       parentClosure := parentConstructor.Closure
+=======
+       parentModType := parentConstructor.ObjectType
+>>>>>>> origin/main
@@
+<<<<<<< HEAD
+       bodyEnv := dang.CreateCompositeEnv(parentModEnv, parentClosure)
+=======
+       bodyEnv := dang.CreateOverlayValueScope(parentModEnv, env)
+>>>>>>> origin/main
        bodyEnv.EnterSelf(parentModEnv)
-       _, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ClassBodyForms, bodyEnv)
+       _, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ObjectBodyForms, bodyEnv)
```

Resolution: take main's newer Dang API names, but keep beta's captured `Closure` for conversion and body evaluation.

```diff
diff --git a/core/sdk/dang_helpers.go b/core/sdk/dang_helpers.go
@@
        parentConstructor := parentModBase.(*dang.ConstructorFunction)
        parentModType := parentConstructor.ObjectType
        // Use the class file's captured env so rehydrated method calls keep the
        // imports that were in scope when the type was declared.
        parentClosure := parentConstructor.Closure
@@
        bodyEnv := dang.CreateOverlayValueScope(parentModEnv, parentClosure)
        bodyEnv.EnterSelf(parentModEnv)
        _, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ObjectBodyForms, bodyEnv)
```

3. Current docs promotion vs beta current-docs surface

Related PRs: beta #13338, main #13345.

Original conflict: main promoted 1.0-beta docs into `current_docs`, while beta already had the active 1.0-beta current-docs surface with beta links and `dagger.toml` workspace wording.

```diff
diff --cc docs/current_docs/adopting/workspace-setup.mdx
@@
+<<<<<<< HEAD
+You've seen Dagger work on [hello-dagger](/quickstart). Now set it up on your own project.
+=======
+You've seen Dagger work on [hello-dagger](../getting-started/quickstart.mdx). Now set it up on your own project.
+>>>>>>> origin/main
@@
+<<<<<<< HEAD
+`dagger mod install` creates a workspace configuration (`dagger.toml`) if needed and adds the selected module.
+=======
+`dagger mod install` creates a workspace configuration (`.dagger/config.toml`) if needed and adds the selected module.
+>>>>>>> origin/main
```

Resolution: keep the previously resolved beta/current-docs tree for `docs/current_docs` and `docs/sidebars.ts`. That preserves the current 1.0-beta links, aliases, and `dagger.toml` terminology while still accepting main's non-current docs payload.

```diff
diff --git a/docs/current_docs/adopting/workspace-setup.mdx b/docs/current_docs/adopting/workspace-setup.mdx
@@
 You've seen Dagger work on [hello-dagger](/quickstart). Now set it up on your own project.
@@
 `dagger mod install` creates a workspace configuration (`dagger.toml`) if needed and adds the selected module.
```

4. Versioned docs archive vs beta docs deletions and test-fixture moves

Related PRs: beta #13217 and #13338, main #13345.

Original conflict: main archived old current docs under `docs/versioned_docs`, while beta had deleted those old current-docs pages or moved some snippets into integration test fixtures.

```diff
diff --cc docs/current_docs/getting-started/ci-integrations/github-actions.mdx
@@
+<<<<<<< HEAD
+deleted in 1.0-beta current docs
+=======
+renamed to docs/versioned_docs/version-0.21.4/getting-started/ci-integrations/github-actions.mdx
+>>>>>>> origin/main

diff --cc docs/current_docs/cookbook/snippets/secret-variable/java/.gitignore
@@
+<<<<<<< HEAD
+renamed to core/integration/testdata/modules/java/path-context-git-04/.gitignore
+=======
+renamed to docs/versioned_docs/version-0.16.3/api/snippets/functions/arguments-array/java/.gitignore
+>>>>>>> origin/main
```

Resolution: keep beta's current-docs deletions and integration test fixture moves, and keep main's versioned docs/archive files under `docs/versioned_docs`.

```diff
diff --git a/core/integration/testdata/modules/java/path-context-git-04/.gitignore b/core/integration/testdata/modules/java/path-context-git-04/.gitignore
@@
+# beta integration fixture path remains

diff --git a/docs/versioned_docs/version-0.21.4/getting-started/ci-integrations/github-actions.mdx b/docs/versioned_docs/version-0.21.4/getting-started/ci-integrations/github-actions.mdx
@@
+# main versioned docs archive path remains
```

## Notes

- No separate `dagger generate -y` commit was added for this fresh merge. Current `origin/main` already includes the generated outputs that should be represented by the merge tree.

Signed-off-by: Solomon Hykes <[email protected]>
dagger-codex Bot pushed a commit that referenced this pull request Jun 8, 2026
Merges `main` into `1.0-beta`, resolving conflicts from the docs restructure/versioning work, the Dang API bump, and workspace/module config changes.

Grouped sections below are explicit groupings: hunks are grouped only when they come from the same conflicting PRs and use the same resolution rule. Each grouped section includes example hunks so the resolution rule is visible.

## Docs conflicts

### `docs/current_docs/` and `docs/sidebars.ts`

Related PRs: beta #13338, main #13345.

This is a grouped conflict category. Main #13345 promoted the 1.0-beta docs into `current_docs`, while beta #13338 already had the active 1.0-beta current-docs surface. I kept the beta/current-docs surface for `docs/current_docs` and `docs/sidebars.ts`, including beta route aliases and `dagger.toml` terminology. Main's promoted docs payload is still accepted outside this current-docs surface as versioned/static docs.

Example hunk 1: workspace setup keeps beta's current route and `dagger.toml` wording instead of main's relative link and `.dagger/config.toml` wording.

```diff
diff --cc docs/current_docs/adopting/workspace-setup.mdx
@@
+<<<<<<< HEAD
+You've seen Dagger work on [hello-dagger](/quickstart). Now set it up on your own project.
+=======
+You've seen Dagger work on [hello-dagger](../getting-started/quickstart.mdx). Now set it up on your own project.
+>>>>>>> origin/main
@@
+<<<<<<< HEAD
+`dagger mod install` creates a workspace configuration (`dagger.toml`) if needed and adds the selected module.
+=======
+`dagger mod install` creates a workspace configuration (`.dagger/config.toml`) if needed and adds the selected module.
+>>>>>>> origin/main
```

Resolved:

```diff
diff --git a/docs/current_docs/adopting/workspace-setup.mdx b/docs/current_docs/adopting/workspace-setup.mdx
@@
 You've seen Dagger work on [hello-dagger](/quickstart). Now set it up on your own project.
@@
 `dagger mod install` creates a workspace configuration (`dagger.toml`) if needed and adds the selected module.
```

Example hunk 2: Argo Workflows follows the same current-docs rule, keeping beta's current aliases and `dagger.toml` terminology instead of main's promoted relative links and old workspace config path.

```diff
diff --cc docs/current_docs/adopting/triggers/argo-workflows.mdx
@@
+<<<<<<< HEAD
+For checks with no workflow YAML at all, enable [Cloud Checks](/adopting/triggers) with `dagger ws autocheck on`.
+=======
+For checks with no workflow YAML at all, enable [Cloud Checks](./index.mdx) with `dagger ws autocheck on`.
+>>>>>>> origin/main
@@
+<<<<<<< HEAD
+- A repository with a Dagger workspace (`dagger.toml`) — see [Workspace Setup](/adopting/workspace-setup)
+=======
+- A repository with a Dagger workspace (`.dagger/config.toml`) — see [Workspace Setup](../workspace-setup.mdx)
+>>>>>>> origin/main
```

Resolved:

```diff
diff --git a/docs/current_docs/adopting/triggers/argo-workflows.mdx b/docs/current_docs/adopting/triggers/argo-workflows.mdx
@@
 For checks with no workflow YAML at all, enable [Cloud Checks](/adopting/triggers) with `dagger ws autocheck on`.
@@
 - A repository with a Dagger workspace (`dagger.toml`) — see [Workspace Setup](/adopting/workspace-setup)
```

### `docs/versioned_docs/` archive

Related PRs: beta #13338, main #13345.

This is a grouped conflict category. Main #13345 archived old docs under `docs/versioned_docs`, while beta #13338 removed old pages from the active current-docs tree. I kept beta's current-doc deletions and kept main's archive files under `docs/versioned_docs`; those are different final destinations, so both sides are represented without resurrecting old pages under `docs/current_docs`.

Example hunk:

```diff
diff --cc docs/current_docs/getting-started/ci-integrations/github-actions.mdx
@@
+<<<<<<< HEAD
+deleted in 1.0-beta current docs
+=======
+renamed to docs/versioned_docs/version-0.21.4/getting-started/ci-integrations/github-actions.mdx
+>>>>>>> origin/main
```

Resolved:

```diff
diff --git a/docs/versioned_docs/version-0.21.4/getting-started/ci-integrations/github-actions.mdx b/docs/versioned_docs/version-0.21.4/getting-started/ci-integrations/github-actions.mdx
@@
+# main versioned docs archive path remains
```

## Code conflicts

### `core/sdk/dang_helpers.go`

Related PRs: beta #13296, main #13318.

Main upgraded Dang and renamed class APIs to object APIs. Beta fixed rehydrated method calls by preserving the constructor closure so imports remain in scope. I used main's newer Dang API names and kept beta's captured `Closure` behavior.

```diff
diff --cc core/sdk/dang_helpers.go
@@
        parentConstructor := parentModBase.(*dang.ConstructorFunction)
+<<<<<<< HEAD
+       parentModType := parentConstructor.ClassType
+       // Use the class file's captured env so rehydrated method calls keep the
+       // imports that were in scope when the type was declared.
+       parentClosure := parentConstructor.Closure
+=======
+       parentModType := parentConstructor.ObjectType
+>>>>>>> origin/main
@@
+<<<<<<< HEAD
+       bodyEnv := dang.CreateCompositeEnv(parentModEnv, parentClosure)
+=======
+       bodyEnv := dang.CreateOverlayValueScope(parentModEnv, env)
+>>>>>>> origin/main
        bodyEnv.EnterSelf(parentModEnv)
-       _, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ClassBodyForms, bodyEnv)
+       _, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ObjectBodyForms, bodyEnv)
```

Resolved:

```diff
diff --git a/core/sdk/dang_helpers.go b/core/sdk/dang_helpers.go
@@
        parentConstructor := parentModBase.(*dang.ConstructorFunction)
        parentModType := parentConstructor.ObjectType
        // Use the class file's captured env so rehydrated method calls keep the
        // imports that were in scope when the type was declared.
        parentClosure := parentConstructor.Closure
@@
        bodyEnv := dang.CreateOverlayValueScope(parentModEnv, parentClosure)
        bodyEnv.EnterSelf(parentModEnv)
        _, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ObjectBodyForms, bodyEnv)
```

### `core/module.go`

Related PRs: beta #13300, main #13329.

Main added `LegacyArgCustomizations`, which is used by merged `modulesource.go` code. Beta renamed workspace configuration terminology for `dagger.toml` settings. I kept both the new field and beta's settings terminology.

```diff
diff --cc core/module.go
@@
        LegacyDefaultPath bool

+       // LegacyArgCustomizations are workspace dagger.json argument customizations
+       // applied through asModule.
+       LegacyArgCustomizations []*modules.ModuleConfigArgument
+
-       // Config values from workspace config.toml [modules.<name>.config].
+       // Workspace setting values from dagger.toml [modules.<name>.settings].
        // Typed map: strings, bools, ints, floats as-is from TOML.
        // When set, constructor args are resolved from this map first.
        WorkspaceConfig map[string]any
```

Resolved:

```diff
diff --git a/core/module.go b/core/module.go
@@
        LegacyDefaultPath bool

        // LegacyArgCustomizations are workspace dagger.json argument customizations
        // applied through asModule.
        LegacyArgCustomizations []*modules.ModuleConfigArgument

        // Workspace setting values from dagger.toml [modules.<name>.settings].
        // Typed map: strings, bools, ints, floats as-is from TOML.
        // When set, constructor args are resolved from this map first.
        WorkspaceConfig map[string]any
```

## Test fixture conflicts

Related PRs: beta #13217, main #13345.

This is a grouped conflict category. Beta moved snippet files into integration test fixtures, while main #13345 archived the old docs snippets under `docs/versioned_docs`. I kept beta's integration fixture paths and kept main's versioned docs archive paths.

Example hunk:

```diff
diff --cc docs/current_docs/cookbook/snippets/secret-variable/java/.gitignore
@@
+<<<<<<< HEAD
+renamed to core/integration/testdata/modules/java/path-context-git-04/.gitignore
+=======
+renamed to docs/versioned_docs/version-0.16.3/api/snippets/functions/arguments-array/java/.gitignore
+>>>>>>> origin/main
```

Resolved:

```diff
diff --git a/core/integration/testdata/modules/java/path-context-git-04/.gitignore b/core/integration/testdata/modules/java/path-context-git-04/.gitignore
@@
+# beta integration fixture path remains

diff --git a/docs/versioned_docs/version-0.16.3/api/snippets/functions/arguments-array/java/.gitignore b/docs/versioned_docs/version-0.16.3/api/snippets/functions/arguments-array/java/.gitignore
@@
+# main versioned docs archive path remains
```

## Notes

- No separate `dagger generate -y` commit was added for this fresh merge. Current `origin/main` already includes the generated outputs that should be represented by the merge tree.

Signed-off-by: Solomon Hykes <[email protected]>
shykes and others added 2 commits June 8, 2026 19:08
Merges `main` into `1.0-beta`, resolving conflicts from the docs restructure/versioning work, the Dang API bump, and workspace/module config changes.

Grouped sections below are explicit groupings: hunks are grouped only when they come from the same conflicting PRs and use the same resolution rule. Each grouped section includes example hunks so the resolution rule is visible.

## Docs conflicts

### `docs/current_docs/` and `docs/sidebars.ts`

Related PRs: beta #13338, main #13345.

This is a grouped conflict category. Main #13345 promoted the 1.0-beta docs into `current_docs`, while beta #13338 already had the active 1.0-beta current-docs surface. I kept the beta/current-docs surface for `docs/current_docs` and `docs/sidebars.ts`, including beta route aliases and `dagger.toml` terminology. Main's promoted docs payload is still accepted outside this current-docs surface as versioned/static docs.

Example hunk 1: workspace setup keeps beta's current route and `dagger.toml` wording instead of main's relative link and `.dagger/config.toml` wording.

```diff
diff --cc docs/current_docs/adopting/workspace-setup.mdx
@@
+<<<<<<< HEAD
+You've seen Dagger work on [hello-dagger](/quickstart). Now set it up on your own project.
+=======
+You've seen Dagger work on [hello-dagger](../getting-started/quickstart.mdx). Now set it up on your own project.
+>>>>>>> origin/main
@@
+<<<<<<< HEAD
+`dagger mod install` creates a workspace configuration (`dagger.toml`) if needed and adds the selected module.
+=======
+`dagger mod install` creates a workspace configuration (`.dagger/config.toml`) if needed and adds the selected module.
+>>>>>>> origin/main
```

Resolved:

```diff
diff --git a/docs/current_docs/adopting/workspace-setup.mdx b/docs/current_docs/adopting/workspace-setup.mdx
@@
 You've seen Dagger work on [hello-dagger](/quickstart). Now set it up on your own project.
@@
 `dagger mod install` creates a workspace configuration (`dagger.toml`) if needed and adds the selected module.
```

Example hunk 2: Argo Workflows follows the same current-docs rule, keeping beta's current aliases and `dagger.toml` terminology instead of main's promoted relative links and old workspace config path.

```diff
diff --cc docs/current_docs/adopting/triggers/argo-workflows.mdx
@@
+<<<<<<< HEAD
+For checks with no workflow YAML at all, enable [Cloud Checks](/adopting/triggers) with `dagger ws autocheck on`.
+=======
+For checks with no workflow YAML at all, enable [Cloud Checks](./index.mdx) with `dagger ws autocheck on`.
+>>>>>>> origin/main
@@
+<<<<<<< HEAD
+- A repository with a Dagger workspace (`dagger.toml`) — see [Workspace Setup](/adopting/workspace-setup)
+=======
+- A repository with a Dagger workspace (`.dagger/config.toml`) — see [Workspace Setup](../workspace-setup.mdx)
+>>>>>>> origin/main
```

Resolved:

```diff
diff --git a/docs/current_docs/adopting/triggers/argo-workflows.mdx b/docs/current_docs/adopting/triggers/argo-workflows.mdx
@@
 For checks with no workflow YAML at all, enable [Cloud Checks](/adopting/triggers) with `dagger ws autocheck on`.
@@
 - A repository with a Dagger workspace (`dagger.toml`) — see [Workspace Setup](/adopting/workspace-setup)
```

### `docs/versioned_docs/` archive

Related PRs: beta #13338, main #13345.

This is a grouped conflict category. Main #13345 archived old docs under `docs/versioned_docs`, while beta #13338 removed old pages from the active current-docs tree. I kept beta's current-doc deletions and kept main's archive files under `docs/versioned_docs`; those are different final destinations, so both sides are represented without resurrecting old pages under `docs/current_docs`.

Example path conflict, not a content hunk:

- Beta removed the old live current-docs page: `docs/current_docs/getting-started/ci-integrations/github-actions.mdx`
- Main archived that old page at: `docs/versioned_docs/version-0.21.4/getting-started/ci-integrations/github-actions.mdx`

Resolution:

- keep the file removed from `docs/current_docs`
- keep main's archived copy under `docs/versioned_docs/version-0.21.4/`

No line-level content hunk was resolved for this page; the conflict was about whether the old current-docs path should remain live or only exist in the versioned archive.## Code conflicts

### `core/sdk/dang_helpers.go`

Related PRs: beta #13296, main #13318.

Main upgraded Dang and renamed class APIs to object APIs. Beta fixed rehydrated method calls by preserving the constructor closure so imports remain in scope. I used main's newer Dang API names and kept beta's captured `Closure` behavior.

```diff
diff --cc core/sdk/dang_helpers.go
@@
        parentConstructor := parentModBase.(*dang.ConstructorFunction)
+<<<<<<< HEAD
+       parentModType := parentConstructor.ClassType
+       // Use the class file's captured env so rehydrated method calls keep the
+       // imports that were in scope when the type was declared.
+       parentClosure := parentConstructor.Closure
+=======
+       parentModType := parentConstructor.ObjectType
+>>>>>>> origin/main
@@
+<<<<<<< HEAD
+       bodyEnv := dang.CreateCompositeEnv(parentModEnv, parentClosure)
+=======
+       bodyEnv := dang.CreateOverlayValueScope(parentModEnv, env)
+>>>>>>> origin/main
        bodyEnv.EnterSelf(parentModEnv)
-       _, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ClassBodyForms, bodyEnv)
+       _, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ObjectBodyForms, bodyEnv)
```

Resolved:

```diff
diff --git a/core/sdk/dang_helpers.go b/core/sdk/dang_helpers.go
@@
        parentConstructor := parentModBase.(*dang.ConstructorFunction)
        parentModType := parentConstructor.ObjectType
        // Use the class file's captured env so rehydrated method calls keep the
        // imports that were in scope when the type was declared.
        parentClosure := parentConstructor.Closure
@@
        bodyEnv := dang.CreateOverlayValueScope(parentModEnv, parentClosure)
        bodyEnv.EnterSelf(parentModEnv)
        _, err = dang.EvaluateFormsWithPhases(ctx, parentConstructor.ObjectBodyForms, bodyEnv)
```

### `core/module.go`

Related PRs: beta #13300, main #13329.

Main added `LegacyArgCustomizations`, which is used by merged `modulesource.go` code. Beta renamed workspace configuration terminology for `dagger.toml` settings. I kept both the new field and beta's settings terminology.

```diff
diff --cc core/module.go
@@
        LegacyDefaultPath bool

+       // LegacyArgCustomizations are workspace dagger.json argument customizations
+       // applied through asModule.
+       LegacyArgCustomizations []*modules.ModuleConfigArgument
+
-       // Config values from workspace config.toml [modules.<name>.config].
+       // Workspace setting values from dagger.toml [modules.<name>.settings].
        // Typed map: strings, bools, ints, floats as-is from TOML.
        // When set, constructor args are resolved from this map first.
        WorkspaceConfig map[string]any
```

Resolved:

```diff
diff --git a/core/module.go b/core/module.go
@@
        LegacyDefaultPath bool

        // LegacyArgCustomizations are workspace dagger.json argument customizations
        // applied through asModule.
        LegacyArgCustomizations []*modules.ModuleConfigArgument

        // Workspace setting values from dagger.toml [modules.<name>.settings].
        // Typed map: strings, bools, ints, floats as-is from TOML.
        // When set, constructor args are resolved from this map first.
        WorkspaceConfig map[string]any
```

## Test fixture conflicts

Related PRs: beta #13217, main #13345.

This is a grouped conflict category. Beta moved snippet files into integration test fixtures, while main #13345 archived the old docs snippets under `docs/versioned_docs`. These are path conflicts, not line-level content hunks. I kept beta's integration fixture paths and kept main's versioned docs archive paths.

Example path conflict, not a content hunk:

- Beta moved the old docs snippet into an integration fixture path: `core/integration/testdata/modules/java/path-context-git-04/.gitignore`
- Main archived that old docs snippet at: `docs/versioned_docs/version-0.16.3/api/snippets/functions/arguments-array/java/.gitignore`
- The old live docs path was: `docs/current_docs/cookbook/snippets/secret-variable/java/.gitignore`

Resolution:

- keep beta's integration fixture file
- keep main's versioned docs archive file
- do not restore the old live `docs/current_docs` snippet path

No line-level content hunk was resolved for this example; the conflict was about preserving the right final paths on both sides.

## Notes

- No separate `dagger generate -y` commit was added for this fresh merge. Current `origin/main` already includes the generated outputs that should be represented by the merge tree.

Signed-off-by: Solomon Hykes <[email protected]>
@tiborvass
tiborvass requested review from a team as code owners June 8, 2026 20:34
@tiborvass
tiborvass merged commit a6e7683 into main Jun 8, 2026
75 of 77 checks passed
@tiborvass
tiborvass deleted the 1.0-beta branch June 8, 2026 21:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants