windmill-labs/windmill · warning
⚠️ WARNING: Workspace creation cancelled. You can manually
Error message
⚠️ WARNING: Workspace creation cancelled. You can manually add a workspace to the 'workspaces' section in wmill.yaml or use 'wmill gitsync-settings pull' to pull configuration from an existing workspace.
What it means
Emitted by `validateBranchConfiguration` when, in an interactive session, the current branch matches no configured workspace and the user answers "No" to the `Confirm.prompt` asking to create an empty workspace configuration for the branch. The function returns without modifying `wmill.yaml`; subsequent push/pull behavior relies on the user fixing the config manually. It is a warning, not an abort of the whole CLI process at this point.
Source
Thrown at cli/src/core/conf.ts:510
` Example: "file.variable.yaml" → "file.${sanitizedBranchName}.variable.yaml"`
);
}
// Read current config, add workspace entry, and write it back
const currentConfig = await readConfigFile();
if (!currentConfig.workspaces) {
currentConfig.workspaces = {} as WorkspacesConfig;
}
(currentConfig.workspaces as any)[currentBranch] = {};
await writeFile("wmill.yaml", yamlStringify(currentConfig), "utf-8");
log.info(
`✅ Created empty workspace configuration for '${currentBranch}'`
);
} else {
log.warn(
"⚠️ WARNING: Workspace creation cancelled. You can manually add a workspace to the 'workspaces' section in wmill.yaml or use 'wmill gitsync-settings pull' to pull configuration from an existing windmill workspace git-sync configuration."
);
return;
}
} else {
// Warn about filesystem-unsafe characters in branch name
if (/[\/\\:*?"<>|.]/.test(currentBranch)) {
const sanitizedBranchName = currentBranch.replace(
/[\/\\:*?"<>|.]/g,
"_"
);
log.warn(
`⚠️ WARNING: Branch name "${currentBranch}" contains filesystem-unsafe characters (/ \\ : * ? " < > | .).`
);
log.warn(
` Branch-specific files will use sanitized name: "${sanitizedBranchName}"`
);
}View on GitHub (pinned to e474e8803c)
Solutions
- Manually add a `workspaces` entry for the current branch in `wmill.yaml`.
- Run `wmill gitsync-settings pull` against an existing workspace to import its git-sync configuration.
- Re-run the command and answer "Yes" to the prompt to let the CLI create the entry.
- Switch to a branch that already has a workspace entry.
Example fix
# before
workspaces:
main:
gitBranch: main
# after (current branch: develop)
workspaces:
main:
gitBranch: main
develop:
gitBranch: develop Defensive patterns
Strategy: validation
Validate before calling
const branch = $("git branch --show-current").trim();
const cfg = await Deno.readTextFile("wmill.yaml");
if (!cfg.includes(branch)) console.warn(`No workspace entry for branch "${branch}" — add one to wmill.yaml or accept the interactive prompt`); Prevention
- Accept the interactive prompt once so the entry lands in `wmill.yaml`, then commit it.
- Use `wmill gitsync-settings pull` after setting up a workspace to import its mapping.
- In non-interactive contexts never rely on the prompt — pre-add entries.
When it happens
Trigger: Running `wmill push`/`pull` in a git repo (TTY attached, no `--yes`, no `--workspace`, no `--skip-branch-validation`), branch unmatched by `findWorkspaceByGitBranch`, and the user declines the "Create empty workspace configuration for branch 'X'?" prompt.
Common situations: Developers who don't want the CLI to auto-edit their checked-in `wmill.yaml` during CI-adjacent work, or who realize they are on the wrong branch and prefer to fix the mapping by hand.
Related errors
- Could not resolve parent workspace. Make sure you are in a g
- ⚠️ WARNING: In a Git repository, the 'workspaces' section i
- ⚠️ WARNING: Multiple workspaces map to git branch '${branch
- ⚠️ WARNING: Current Git branch '${currentBranch}' does not
- No instance found, please add one first
AI-assisted analysis of windmill-labs/windmill@e474e8803c (2026-09-03).
Data as JSON: /api/errors/02c21137ec4ed3c7.
Report an issue: GitHub.