Dashboard › craft › Distillation
d8f6a666-5714-4ba3-bc42-8ec0ce9395a0["lore_tm_v1_JRkBpSldDTnFUJPlDYD_WEbdcTNRcMBVLQagiDSaF2E","lore_tm_v1_wAxtiZIOgN4jtufVb13EVqKz28c9fCTxmkwkNAjn4Bg","lore_tm_v1_R_ZuIGyauR0SwdGm2x1ZqaiNi9E_5BPO2jMhaZ1eOso","lore_tm_v1_C9qJ3hpXkJGx7arcIHKtelyhjWC1eEYH1VN9O-wgDuw","lore_tm_v1_xW09MlSNrc5uSXMYc2U7nz6GFTJ4jly4tWkM52QQPwY","lore_tm_v1_8Pz2Bm4b-hL-WYjgmCb1KAAqDuYx75WblZMwBfZ1CSg","lore_tm_v1_3NJFMsyHGxlNh2G1gCN9cYqZIkcFOu6c58oXlXW_rys","lore_tm_v1_rcvwKvKGRJTsFTVLDsW2c6l7EQPEW7kAMs8ovH-yHYo","lore_tm_v1_p-aZ9f5HN45oRctvWqF4uUxBowdW1TpEPE9z06gVgQY","lore_tm_v1_V2I5r-piwjUa2RARC01mqiKnykMOoGSGmyj8icVsBpg","lore_tm_v1_bL4Myc09IPnguMGrJSZR7DnTmLgcy42zAJ7f6UnvRk0","lore_tm_v1_H-I-LA8raZJwPEfhmCD50RKGnipfhOaKfJPwYivxM3g"]
Date: Aug 25, 2026
/home/byk/Code/getsentry/craft-workspace-action-propagation/src/config.ts lines 1-270. CONFIG_FILE_NAME = '.craft.yml'; DEFAULT_RELEASE_BRANCH_NAME = 'release'; WORKSPACES_MIN_VERSION = '2.29.0'.src/config.ts:69-95 stores selected workspace in _activeWorkspaceName: string | undefined; setActiveWorkspace(name) sets it and invalidates _configCache and _globalGitHubConfigCache; getActiveWorkspace() returns it.resolveWorkspaceConfig(base, workspaceName) in src/config.ts:110-160 errors with ConfigurationError for an unknown workspace and lists available workspaces (or reports none configured); applies shallow overrides for every defined workspace release field, does not deep-merge arrays/objects, strips top-level workspaces, and shallow-merges github so partial workspace fields can inherit base owner/repo.resolveWorkspaceConfig() only retains merged github when both owner and repo are present; otherwise deletes it so getGlobalGitHubConfig() can fall back to git-remote detection. A workspace with only projectPath and no base github therefore relies on git detection for owner/repo.isVersionGteMinVersion(minVersionRaw, requiredVersion) parses both versions and compares them after withoutBuildMetadata() removes SemVer build metadata; invalid or absent versions return false, allowing config minVersion values such as 2.29.0+linux.applyWorkspaceSelection() in src/config.ts:205-240 preserves legacy behavior when neither workspaces nor a selection exists; errors if --workspace is selected but config has no workspaces; errors if config defines workspaces but no explicit --workspace <name> or CRAFT_WORKSPACE selection; and requires minVersion >= 2.29.0 before resolving the selected workspace.findConfigFile() searches upward from process.cwd() for .craft.yml, caches a found path in _configPathCache, stops at filesystem root, and has MAX_DEPTH = 1024, logging findConfigFile: Reached maximum allowed directory depth if exceeded./home/byk/Code/getsentry, which contains 34 entries including craft-workspace-action-propagation/, craft-workspaces-schema/, publish-workspace-acceptance/, publish/, sentry/, sentry-javascript/, sentry-python/, snuba/, and symbolic/./home/byk/Code/getsentry/publish-workspace-acceptance; it contains .github/, AGENTS.md, docs/, node_modules/, package.json, README.md, src/, vitest.config.js, and yarn.lock.publish-workspace-acceptance repository is the Sentry Publish Repository: a GitHub Actions approval system for publishing releases across multiple Sentry projects using Craft; it is a pure JavaScript CommonJS project pinned to Node.js 24.0.0.publish-workspace-acceptance uses Yarn classic 1.22.22 via Volta and must not use npm.yarn install; all tests yarn test; watch tests yarn test:watch; single-file test yarn test src/modules/__tests__/update-issue.js; pattern test yarn test -t "pattern"; lint yarn lint; format yarn prettier.src/libs/ holds shared utilities, src/modules/ holds reusable core business logic, and src/publish/ holds GitHub Actions entry points; tests are in __tests__/ directories.details-from-context.js and update-issue.js; test files share their source filename in __tests__/; camelCase variables/functions; UPPER_SNAKE_CASE constants/regex patterns; CommonJS (require/module.exports) source and ES Modules (import/export) tests.module.exports = { functionA, functionB }), while a single default export is module.exports = functionName.yarn prettier should run before committing.default: throw new Error(\Unknown status: '${status}'`);`.fs.existsSync() before reading.v4.0.0 with globals enabled and automatically cleared mocks; source modules should be imported after vi.mock() calls.@actions/core, @actions/github, and @sentry/node; common patterns include await Promise.all([operation1(), operation2()]), destructuring, and spread-object merging.feat/workspace-acceptance has modifications to .github/workflows/publish.yml, src/modules/__tests__/details-from-context.js, and src/modules/details-from-context.js; base commit shown is 83d210b build(deps): bump js-yaml from 4.3.0 to 4.3.1 (#9174). Diff totals: 123 insertions and 7 deletions across 3 files.publish-workspace-acceptance/src/modules/details-from-context.js defines TARGETS_SECTION_PARSER_REGEX, TARGETS_PARSER_REGEX, and CHECKED_TARGETS_PARSER_REGEX; detailsFromContext({ context }) throws Error("Issue context is not defined") unless context.payload.issue exists.detailsFromContext() parses publish titles with ^publish: (?:getsentry\/)?(?<repo>[A-Za-z0-9_.-]+)(?<path>\/[\w./-]+)?(?: \[workspace: (?<workspace>"(?:[^"\\]|\\.)*")\] )?@(?<version>[\w.+-]+)$; invalid titles throw Invalid publish issue title: '<title>'.detailsFromContext() supports an optional human-readable JSON-quoted [workspace: "<name>"] title component; it parses the capture using JSON.parse(), rejects an empty name or names containing \n/\r with Workspace names must be nonempty and cannot contain line breaks, and returns workspace only when nonempty.detailsFromContext() outputs repo, version, path ("." + title path, default "."), dry_run ("1" only if issue labels include dry-run, otherwise ""), merge_target extracted from Merge target: <[\\w.\\-/]+> (otherwise ""), checked targets, and optional workspace..github/workflows/publish.yml comments document that the CI poller always adds ci-ready (removing it first to trigger a fresh labeled event), so the publish gate requires the ci-ready label and avoids racing waiting-for-ci on the same event.ci-ready.publish-workspace-acceptance/src/publish/inputs.js imports @actions/github, @actions/core, and detailsFromContext; its inputs() function parses github.context and emits the object as the result GitHub Actions output via core.setOutput('result', result), then immediately invokes inputs().publish-workspace-acceptance/src/modules/__tests__/details-from-context.js expect a standard issue title publish: getsentry/sentry@21.3.1 and checked target section to produce dry_run: "", merge_target: "custom-branch", path: ".", repo: "sentry", targets: ["github", "npm[@sentry/node]", "docker[latest]"], and version: "21.3.1".details-from-context tests verify version strings containing +, e.g. 4.2.6+sentry1, are parsed correctly; Merge target: (default) leaves merge_target: "".details-from-context tests verify title publish: getsentry/toolkit [workspace: "cli/v2"] @1.2.3 yields workspace cli/v2, and escaped title workspace "cli [preview] \"next\"" yields cli [preview] "next".details-from-context tests reject a legacy title with a space before its version (publish: getsentry/toolkit @1.2.3), empty workspace ([workspace: ""]), multiline workspace ([workspace: "cli\nnext"]), and missing issue payload.--workspace --dry-run must never be mistaken for a workspace name.src/utils/dryRun.ts as defining remote-state-affecting Git methods βthat should ALWAYS be blocked in dry-runβ around line 355; methods blocked in strict dry-run but allowed in worktree mode are separately documented around line 361.src/utils/dryRun.ts: non-dry-run returns a passthrough object; dry-run creates a temporary worktree at /tmp/craft-dry-run-*; cleanup handles signal receipt and worktree removal; dry-run Git commit mock results use commit: 'dry-run-commit-hash'.src/utils/__tests__/helpers.test.ts for ['--workspace', 'cli', '--workspace', '--dry-run'] and for ensuring --workspace --dry-run does not select --dry-run and instead defers to environment fallback.craft-workspace-action-propagation/src/schemas/project_config.ts:180-197 defines optional release-unit fields: github, targets, preReleaseCommand, postReleaseCommand, releaseBranchPrefix, changelog, changelogPolicy ('auto' | 'simple' | 'none'), requireNames, statusProvider, artifactProvider, versioning, and noMerge.WorkspaceSchema is z.object({ ...releaseUnitFields, github: GitHubGlobalConfigSchema.partial().optional() }); every workspace field is optional and inherits top-level values when omitted, while workspace github can override only projectPath, owner, or repo.CraftProjectConfigSchema adds optional minVersion matching /^\d+\.\d+\.\d+.*$/ and optional workspaces: z.record(z.string(), WorkspaceSchema); named workspaces are independently versioned release units requiring --workspace <name> or CRAFT_WORKSPACE, while no workspaces retains backward-compatible single implicit top-level release-unit behavior.