From 296f021963e22745af6ce3a8251964df7fc67101 Mon Sep 17 00:00:00 2001 From: mschwab Date: Tue, 9 Jun 2026 14:21:00 -0700 Subject: [PATCH 1/5] ci(studio): add SDK gen check for OpenAPI spec changes (ASTD-218) Add web-sdk-gen CI job that force-regenerates the TypeScript SDK from all OpenAPI specs and typechecks nemo-studio-ui against the result. Expand studio-ci.yaml trigger paths to include openapi/** and plugins/*/openapi/** so PRs that touch only OpenAPI specs (Python service PRs, plugin PRs) run Studio CI. Root cause: PR #66 broke main because new add_job_routes() calls produced duplicate operationIds, generating duplicate TS function names. studio-ci.yaml only triggered on web/** changes so the failure wasn't caught before merge. Signed-off-by: mschwab --- .github/actions/changes/action.yaml | 1 + .github/workflows/ci.yaml | 28 ++++++++++++++++++++++++++++ 2 files changed, 29 insertions(+) diff --git a/.github/actions/changes/action.yaml b/.github/actions/changes/action.yaml index 16e1d632db..b2e637234f 100644 --- a/.github/actions/changes/action.yaml +++ b/.github/actions/changes/action.yaml @@ -39,6 +39,7 @@ runs: filters: | openapi: - 'openapi/**' + - 'plugins/*/openapi/**' tests: - 'tests/**' - 'pytest.ini' diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 67691a7f3c..8b55cc49ff 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -504,6 +504,34 @@ jobs: - name: Lint run: pnpm lint + web-sdk-gen: + name: Web SDK generation check + needs: [changes] + if: > + !cancelled() && ( + github.event_name == 'workflow_dispatch' || + needs.changes.outputs.openapi == 'true' || + needs.changes.outputs.web-studio == 'true' + ) + runs-on: ubuntu-latest + defaults: + run: + working-directory: web + shell: bash + steps: + - uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3 + - uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e # v6.4.0 + with: + node-version: "22" + - name: Install pnpm via corepack + run: npm i -g corepack@0.31.0 && corepack enable pnpm + - name: Install dependencies + run: pnpm install --frozen-lockfile + - name: Generate SDK from OpenAPI specs + run: pnpm --filter @nemo/sdk gen:all-force + - name: Typecheck studio against generated SDK + run: pnpm --filter nemo-studio-ui typecheck + web-studio-deps: name: Web studio deps check needs: [changes] From bd5bb6fc365296bec8a3184e0835fc3b62d0d1f5 Mon Sep 17 00:00:00 2001 From: mschwab Date: Tue, 9 Jun 2026 14:27:01 -0700 Subject: [PATCH 2/5] ci(studio): typecheck SDK generated output directly (ASTD-218) Add tsconfig.json + typecheck script to @nemo/sdk so CI typechecks the generated TypeScript files directly after gen:all-force, rather than relying on nemo-studio-ui's transitive dependency resolution (which has skipLibCheck:true and no guaranteed path through @nemo/sdk source). This makes the web-sdk-gen check definitive: duplicate operationIds that produce duplicate TS function names now fail at the SDK typecheck step. Signed-off-by: mschwab --- .github/workflows/ci.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 8b55cc49ff..ce71d6f514 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -529,6 +529,8 @@ jobs: run: pnpm install --frozen-lockfile - name: Generate SDK from OpenAPI specs run: pnpm --filter @nemo/sdk gen:all-force + - name: Typecheck SDK generated output + run: pnpm --filter @nemo/sdk typecheck - name: Typecheck studio against generated SDK run: pnpm --filter nemo-studio-ui typecheck From 8527917e6a6e356e97dd6ef73037026d999593e2 Mon Sep 17 00:00:00 2001 From: mschwab Date: Tue, 9 Jun 2026 14:34:01 -0700 Subject: [PATCH 3/5] ci(studio): drop studio typecheck from web-sdk-gen job (ASTD-218) nemo-studio-ui typecheck has pre-existing failures from evaluator/safe- synthesizer SDK API renames unrelated to this change. @nemo/sdk typecheck alone is sufficient to catch the duplicate operationId issue. Signed-off-by: mschwab --- .github/workflows/ci.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index ce71d6f514..027d17512d 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -531,8 +531,6 @@ jobs: run: pnpm --filter @nemo/sdk gen:all-force - name: Typecheck SDK generated output run: pnpm --filter @nemo/sdk typecheck - - name: Typecheck studio against generated SDK - run: pnpm --filter nemo-studio-ui typecheck web-studio-deps: name: Web studio deps check From 8ac4cb1f8aef2d7836b793a04dad4f3a23a42f8c Mon Sep 17 00:00:00 2001 From: mschwab Date: Wed, 10 Jun 2026 10:19:52 -0700 Subject: [PATCH 4/5] fix(ci): update config-reference-docs hook to .mdx extension (ASTD-218) Signed-off-by: mschwab --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index dd56484d71..8cfd4a0a7c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -55,7 +55,7 @@ repos: hooks: - id: config-reference-docs name: Check config reference doc is up to date - entry: bash -c 'uv run generate-config-docs && git diff --exit-code docs/set-up/config-reference.md' + entry: bash -c 'uv run generate-config-docs && git diff --exit-code docs/set-up/config-reference.mdx' language: system pass_filenames: false files: | @@ -63,7 +63,7 @@ repos: script/generate_config_docs\.py| packages/nmp_common/.*| services/.*/src/.*/config\.py| - docs/set-up/config-reference\.md + docs/set-up/config-reference\.mdx )$ - repo: https://github.com/norwoodj/helm-docs From eeb2c21384fc5dff063327b324468df8ff8d1deb Mon Sep 17 00:00:00 2001 From: mschwab Date: Wed, 10 Jun 2026 10:27:52 -0700 Subject: [PATCH 5/5] fix(ci): add web-sdk-gen to ci-status required checks (ASTD-218) Signed-off-by: mschwab --- .github/workflows/ci.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 027d17512d..fce256ed7b 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -768,6 +768,7 @@ jobs: - web-test - web-format - web-lint + - web-sdk-gen - web-studio-deps - web-studio-e2e - benchmark-guardrails