Skip to content

feat(cli): pull per-workflow deletion dependencies into transcend.yml - #403

Merged
iamtheluckyest merged 5 commits into
mainfrom
annalisa/wal-10452-pull-per-workflow-deletion-dependencies
Aug 18, 2026
Merged

feat(cli): pull per-workflow deletion dependencies into transcend.yml#403
iamtheluckyest merged 5 commits into
mainfrom
annalisa/wal-10452-pull-per-workflow-deletion-dependencies

Conversation

@iamtheluckyest

@iamtheluckyest iamtheluckyest commented Aug 11, 2026

Copy link
Copy Markdown
Member

Part 2 of 2 for WAL-10452. Stacked on #402 — review that one first, and retarget this to main once it merges.

What

transcend inventory pull now writes per-workflow deletion dependencies back into transcend.yml, so a config with workflow overrides round-trips.

  • No overrides → list of titles (same YAML as before)
  • Any override → full object list ({ titles } for global, { workflow, titles } for each override)

Overrides on a workflow with no internal name are skipped with a warning, because transcend.yml identifies workflows by internal name and there would be nothing valid to write.

Notes

Test plan

  • pnpm run --dir packages/cli test
  • pnpm run --dir packages/sdk test
  • Typecheck and build both packages
  • Pull an org with a workflow override and confirm the YAML round-trips

Made with Cursor

@linear-code

linear-code Bot commented Aug 11, 2026

Copy link
Copy Markdown

WAL-10452

@pkg-pr-new

pkg-pr-new Bot commented Aug 11, 2026

Copy link
Copy Markdown

Open in StackBlitz

@transcend-io/airgap.js-types

pnpm add https://pkg.pr.new/@transcend-io/airgap.js-types@403
yarn add https://pkg.pr.new/@transcend-io/airgap.js-types@403.tgz

@transcend-io/cli

pnpm add https://pkg.pr.new/@transcend-io/cli@403
yarn add https://pkg.pr.new/@transcend-io/cli@403.tgz

@transcend-io/design-tokens

pnpm add https://pkg.pr.new/@transcend-io/design-tokens@403
yarn add https://pkg.pr.new/@transcend-io/design-tokens@403.tgz

@transcend-io/internationalization

pnpm add https://pkg.pr.new/@transcend-io/internationalization@403
yarn add https://pkg.pr.new/@transcend-io/internationalization@403.tgz

@transcend-io/privacy-types

pnpm add https://pkg.pr.new/@transcend-io/privacy-types@403
yarn add https://pkg.pr.new/@transcend-io/privacy-types@403.tgz

@transcend-io/sdk

pnpm add https://pkg.pr.new/@transcend-io/sdk@403
yarn add https://pkg.pr.new/@transcend-io/sdk@403.tgz

@transcend-io/type-utils

pnpm add https://pkg.pr.new/@transcend-io/type-utils@403
yarn add https://pkg.pr.new/@transcend-io/type-utils@403.tgz

@transcend-io/utils

pnpm add https://pkg.pr.new/@transcend-io/utils@403
yarn add https://pkg.pr.new/@transcend-io/utils@403.tgz

@transcend-io/mcp

pnpm add https://pkg.pr.new/@transcend-io/mcp@403
yarn add https://pkg.pr.new/@transcend-io/mcp@403.tgz

@transcend-io/mcp-server-admin

pnpm add https://pkg.pr.new/@transcend-io/mcp-server-admin@403
yarn add https://pkg.pr.new/@transcend-io/mcp-server-admin@403.tgz

@transcend-io/mcp-server-assessment

pnpm add https://pkg.pr.new/@transcend-io/mcp-server-assessment@403
yarn add https://pkg.pr.new/@transcend-io/mcp-server-assessment@403.tgz

@transcend-io/mcp-server-base

pnpm add https://pkg.pr.new/@transcend-io/mcp-server-base@403
yarn add https://pkg.pr.new/@transcend-io/mcp-server-base@403.tgz

@transcend-io/mcp-server-consent

pnpm add https://pkg.pr.new/@transcend-io/mcp-server-consent@403
yarn add https://pkg.pr.new/@transcend-io/mcp-server-consent@403.tgz

@transcend-io/mcp-server-discovery

pnpm add https://pkg.pr.new/@transcend-io/mcp-server-discovery@403
yarn add https://pkg.pr.new/@transcend-io/mcp-server-discovery@403.tgz

@transcend-io/mcp-server-docs

pnpm add https://pkg.pr.new/@transcend-io/mcp-server-docs@403
yarn add https://pkg.pr.new/@transcend-io/mcp-server-docs@403.tgz

@transcend-io/mcp-server-dsr

pnpm add https://pkg.pr.new/@transcend-io/mcp-server-dsr@403
yarn add https://pkg.pr.new/@transcend-io/mcp-server-dsr@403.tgz

@transcend-io/mcp-server-inventory

pnpm add https://pkg.pr.new/@transcend-io/mcp-server-inventory@403
yarn add https://pkg.pr.new/@transcend-io/mcp-server-inventory@403.tgz

@transcend-io/mcp-server-preferences

pnpm add https://pkg.pr.new/@transcend-io/mcp-server-preferences@403
yarn add https://pkg.pr.new/@transcend-io/mcp-server-preferences@403.tgz

@transcend-io/mcp-server-workflows

pnpm add https://pkg.pr.new/@transcend-io/mcp-server-workflows@403
yarn add https://pkg.pr.new/@transcend-io/mcp-server-workflows@403.tgz

commit: f36ecf6

@iamtheluckyest
iamtheluckyest marked this pull request as ready for review August 11, 2026 14:00
@iamtheluckyest
iamtheluckyest requested review from a team and michaelfarrell76 August 11, 2026 14:00
Comment thread packages/sdk/src/data-inventory/fetchEnrichedDataSilos.ts
Comment on lines +10 to +12
* With no per-workflow overrides, global dependencies stay as a list of titles so existing
* configurations round-trip unchanged. When overrides exist, the whole field is a list of
* objects (`{ titles }` for global, `{ workflow, titles }` for each override).

@iamtheluckyest iamtheluckyest Aug 11, 2026

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not ideal long-term, but I think we have to make a choice in terms of which way to return the data (list of strings or list of objects) and I think this is best to be non-breaking. But long-term, we would want to transition users over to use the list of objects no matter what.

Maybe we have a flag that they pass in that tells us if they want a list of global-only dependencies to be returned as objects? But at some point code would have to be updated to add/remove that flag, so I'm not sure it's a huge benefit (for us or them) over supporting both.

mason-hale
mason-hale previously approved these changes Aug 11, 2026

@mason-hale mason-hale left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good except for one high severity finding cursor found after i did my manual review

);
const workflowConfigsById = hasWorkflowScopedDependencies
? keyBy(
await fetchAllWorkflowConfigs(client, {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i wasn't seeing any issues so had cursor take a pass which found:

TR_PULL_RESOURCE_SCOPE_MAP for data silos is still only:

[TranscendPullResource.DataSilos]: [
  ScopeName.ViewDataMap,
  ScopeName.ViewDataSubjectRequestSettings,
  ScopeName.ViewApiKeys,
],

Fix: add ViewWorkflows to the data-silos pull (and push, if needed) scope map, and note it in comments like the preference-workflow entry.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we don't add ViewWorkflows to the data-silos pull scope map, a default transcend inventory pull can start failing for API keys that only have the currently documented data-silo scopes (ViewDataMap, ViewDataSubjectRequestSettings, ViewApiKeys). As soon as any silo has a per-workflow deletion-dependency override, pull calls workflows to resolve IDs → internal names, and that query is gated on ViewWorkflows. Orgs that pulled successfully before this change would hit an auth error once overrides exist, even though they never asked to pull workflow configs.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the callout! I think I would prefer to solve this differently - I was already on the fence about retuning the internalName alongside the id. It was responsible for the extra call to workflowConfigs which I wouldn't mind eliminating. If we don't make the extra call, we don't need the extra scope. So I decided to add it (PR here). I'll update this one once that is merged.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, this is updated now. A re-review would be appreciated!

Base automatically changed from annalisa/wal-10452-push-per-workflow-deletion-dependencies to main August 17, 2026 13:49
@iamtheluckyest
iamtheluckyest dismissed stale reviews from michaelfarrell76 and mason-hale August 17, 2026 13:49

The base branch was changed.

Reads `dependedOnDataSilosPerWorkflow` and writes each workflow that
overrides the global dependencies as its own entry. Global dependencies
keep the list-of-titles shorthand so existing configs round-trip unchanged.

Overrides on workflows with no internal name are skipped with a warning,
since transcend.yml references workflows by internal name.
Match the either/or codec: keep string[] for global-only configs, and write
global deps as `{ titles }` alongside overrides when any override exists.
@iamtheluckyest
iamtheluckyest force-pushed the annalisa/wal-10452-pull-per-workflow-deletion-dependencies branch from c631cf2 to c02170d Compare August 17, 2026 15:30
Read the internal name from dependedOnDataSilosPerWorkflow so pull no
longer needs a separate workflowConfigs fetch (or ViewWorkflows scope).

@mason-hale mason-hale left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@iamtheluckyest
iamtheluckyest added this pull request to the merge queue Aug 18, 2026
Merged via the queue into main with commit a5e8334 Aug 18, 2026
4 checks passed
@iamtheluckyest
iamtheluckyest deleted the annalisa/wal-10452-pull-per-workflow-deletion-dependencies branch August 18, 2026 17:27
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.

3 participants