{"record":{"id":"01a1f31d16442bdd","repo":"windmill-labs/windmill","slug":"legacykey-in-wmill-yaml-is-deprecated-us","errorCode":null,"errorMessage":"⚠️  '${legacyKey}' in wmill.yaml is deprecated. Use 'workspaces' instead.\\n   Run 'wmill config migrate' to update your configuration automatically.","messagePattern":"⚠️  '(.+?)' in wmill\\.yaml is deprecated\\. Use 'workspaces' instead\\.\\\\n   Run 'wmill config migrate' to update your configuration automatically\\.","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"cli/src/core/conf.ts","lineNumber":259,"sourceCode":"    if (conf && !conf.workspaces) {\n      let legacyKey: string | null = null;\n      let legacyData: LegacyBranchesConfig | undefined;\n\n      if (conf.gitBranches) {\n        legacyKey = \"gitBranches\";\n        legacyData = conf.gitBranches;\n      } else if (conf.environments) {\n        legacyKey = \"environments\";\n        legacyData = conf.environments;\n      } else if (conf.git_branches) {\n        legacyKey = \"git_branches\";\n        legacyData = conf.git_branches;\n      }\n\n      if (legacyKey && legacyData) {\n        conf.workspaces = convertGitBranchesToWorkspaces(legacyData);\n        if (!legacyConfigWarned) {\n          log.warn(\n            `⚠️  '${legacyKey}' in wmill.yaml is deprecated. Use 'workspaces' instead.\\n` +\n            `   Run 'wmill config migrate' to update your configuration automatically.`\n          );\n          legacyConfigWarned = true;\n        }\n      }\n    } else if (conf?.workspaces) {\n      // If both workspaces and any legacy key exist, warn and use workspaces\n      for (const legacyKey of [\"gitBranches\", \"environments\", \"git_branches\"] as const) {\n        if ((conf as any)[legacyKey]) {\n          log.warn(\n            `⚠️  Both 'workspaces' and '${legacyKey}' found in wmill.yaml. Using 'workspaces' and ignoring '${legacyKey}'.`\n          );\n        }\n      }\n    }\n    // Clean legacy keys from in-memory config\n    delete conf?.gitBranches;","sourceCodeStart":241,"sourceCodeEnd":277,"githubUrl":"https://github.com/windmill-labs/windmill/blob/e474e8803ce2ff5c2df09a58dab51d45f5c922ca/cli/src/core/conf.ts#L241-L277","documentation":"One-time migration notice from readConfigFile: wmill.yaml defines workspaces via a legacy key (gitBranches, environments or git_branches) instead of 'workspaces'. The config is transparently converted in memory (convertGitBranchesToWorkspaces); the warning (once per process via legacyConfigWarned) tells how to persist the migration.","triggerScenarios":"Thrown at cli/src/core/conf.ts:259 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Run 'wmill config migrate' to rewrite wmill.yaml to the 'workspaces' key","Or manually rename the legacy key to 'workspaces' with the same shape","Ignore — behavior is unchanged thanks to in-memory conversion"],"exampleFix":null,"handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"e474e8803ce2ff5c2df09a58dab51d45f5c922ca","analyzedAt":"2026-09-03T12:38:19.024Z","contentChangedAt":"2026-09-03T12:38:19.024Z","schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}