Skip to content

Commit d76281b

Browse files
authored
Release 17.0.0-beta.13 (#53)
Fixes ----- - `@umbraco-cms/create-umbraco-mcp-server`: resolve bundled package.json via an inlined JSON import. The CLI read its own version with `require("../../package.json")`, which resolved correctly from source but not from the bundled `dist/index.js` — npx-installed CLIs crashed with "Cannot find module '../../package.json'" at module load. Bug shipped undetected through beta.9, beta.10, and beta.11 because every existing E2E imports source (`../../src/...`) and never executes the bundled output. (#50) Features -------- - `UMBRACO_ADMIN_EMAIL` / `UMBRACO_ADMIN_PASSWORD` env var overrides for `discover`, so the API user can be auto-created against an existing Umbraco whose admin credentials differ from PSW's unattended-install defaults. (#50) - `--version` / `-v` flag on the CLI. (#50) - `check-api-user.ts` now distinguishes admin-login failures from bearer-token failures via a discriminated `AutoCreateFailure` type. Only the bearer-token case surfaces the "restart Umbraco (17.3 regression)" advice; admin-login failures point at the env vars. (#50) CI hardening ------------ - PR bundle smoke test: `node dist/index.js --version` runs after the CLI build. Catches module-load regressions in the bundled output in seconds. Would have failed on the PR that introduced the package.json bug. (#50) - Scheduled daily workflow (scheduled-daily.yml, 06:00 UTC): a `published-cli-smoke` job that scaffolds and compiles against the currently-published @latest (and @beta) npm artifact, plus a full `cli-e2e` job so tooling drift (Umbraco updates, PSW updates, .NET SDK changes) surfaces without waiting for a PR. Failure notifications rely on GitHub's built-in scheduled-workflow emails. (#50)
1 parent 8d8ed88 commit d76281b

14 files changed

Lines changed: 225 additions & 33 deletions

File tree

.claude-plugin/marketplace.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@
66
},
77
"metadata": {
88
"description": "Claude Code plugins for the Umbraco MCP Toolkit - professional skills for building MCP servers, testing, and API integration",
9-
"version": "17.0.0-beta.12",
9+
"version": "17.0.0-beta.13",
1010
"homepage": "https://github.com/umbraco/Umbraco-MCP-Base"
1111
},
1212
"plugins": [
1313
{
1414
"name": "umbraco-mcp-skills",
1515
"source": "./plugins",
1616
"description": "Professional skills for building Umbraco MCP servers - tool creation, testing, API patterns, and eval testing",
17-
"version": "17.0.0-beta.12",
17+
"version": "17.0.0-beta.13",
1818
"category": "development",
1919
"author": {
2020
"name": "Phil W",
@@ -35,7 +35,7 @@
3535
"name": "umbraco-mcp-server",
3636
"source": "./plugins-server",
3737
"description": "Skills for CLI operation of Umbraco MCP servers - CLI setup, tool filtering, introspection, and runtime modes",
38-
"version": "17.0.0-beta.12",
38+
"version": "17.0.0-beta.13",
3939
"category": "operations",
4040
"author": {
4141
"name": "Phil W",
Lines changed: 145 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,145 @@
1+
name: Scheduled — Daily CLI checks
2+
3+
# Runs daily to catch regressions that the PR suite can miss.
4+
#
5+
# published-cli-smoke — exercises the currently-published npm artifact
6+
# (catches bundle bugs, missing `files`, broken deps).
7+
#
8+
# cli-e2e — full 19-step deterministic CLI E2E
9+
# (scaffold → init → Umbraco → discover → generate →
10+
# compile → test → worker), same as runs on PRs but
11+
# scheduled so regressions in dev dependencies or
12+
# transitive tooling surface without waiting for a PR.
13+
#
14+
# Failure notifications: relies on GitHub's built-in emails for scheduled
15+
# workflows — the user who last modified this file receives an email when a
16+
# scheduled run fails (if Actions notifications are enabled in their GitHub
17+
# settings). No explicit notification job.
18+
19+
on:
20+
schedule:
21+
- cron: '0 6 * * *' # 06:00 UTC daily
22+
workflow_dispatch: # allow manual runs from the Actions tab
23+
24+
jobs:
25+
published-cli-smoke:
26+
name: Scaffold from published npm
27+
runs-on: ubuntu-latest
28+
timeout-minutes: 15
29+
30+
steps:
31+
- name: Setup Node.js
32+
uses: actions/setup-node@v4
33+
with:
34+
node-version: '22'
35+
36+
- name: Report published version
37+
id: version
38+
run: |
39+
LATEST=$(npm view @umbraco-cms/create-umbraco-mcp-server version)
40+
BETA=$(npm view @umbraco-cms/create-umbraco-mcp-server@beta version 2>/dev/null || echo "")
41+
echo "latest=$LATEST" >> "$GITHUB_OUTPUT"
42+
echo "beta=$BETA" >> "$GITHUB_OUTPUT"
43+
echo "Latest dist-tag: $LATEST"
44+
echo "Beta dist-tag: $BETA"
45+
46+
- name: Scaffold project via npx (latest dist-tag)
47+
working-directory: ${{ runner.temp }}
48+
run: |
49+
npx --yes @umbraco-cms/create-umbraco-mcp-server@latest smoke-latest
50+
test -d smoke-latest
51+
test -f smoke-latest/package.json
52+
test -d smoke-latest/src
53+
54+
- name: Verify CLI reports a version
55+
working-directory: ${{ runner.temp }}
56+
run: |
57+
VERSION=$(npx --yes @umbraco-cms/create-umbraco-mcp-server@latest --version)
58+
test -n "$VERSION"
59+
60+
- name: Install dependencies in scaffolded project
61+
working-directory: ${{ runner.temp }}/smoke-latest
62+
run: npm install
63+
64+
- name: Typecheck scaffolded project
65+
working-directory: ${{ runner.temp }}/smoke-latest
66+
run: npm run compile
67+
68+
- name: Scaffold project via npx (beta dist-tag)
69+
if: steps.version.outputs.beta != ''
70+
working-directory: ${{ runner.temp }}
71+
run: |
72+
npx --yes @umbraco-cms/create-umbraco-mcp-server@beta smoke-beta
73+
test -d smoke-beta
74+
test -f smoke-beta/package.json
75+
76+
- name: Install dependencies in @beta scaffolded project
77+
if: steps.version.outputs.beta != ''
78+
working-directory: ${{ runner.temp }}/smoke-beta
79+
run: npm install
80+
81+
- name: Typecheck @beta scaffolded project
82+
if: steps.version.outputs.beta != ''
83+
working-directory: ${{ runner.temp }}/smoke-beta
84+
run: npm run compile
85+
86+
cli-e2e:
87+
name: CLI full E2E (scheduled)
88+
runs-on: ubuntu-latest
89+
timeout-minutes: 30
90+
91+
services:
92+
sqlserver:
93+
image: mcr.microsoft.com/mssql/server:2022-latest
94+
env:
95+
ACCEPT_EULA: Y
96+
MSSQL_SA_PASSWORD: Moloko99
97+
ports:
98+
- 1433:1433
99+
options: >-
100+
--health-cmd "/opt/mssql-tools18/bin/sqlcmd -S localhost -U sa -P Moloko99 -C -Q 'SELECT 1' || exit 1"
101+
--health-interval 10s
102+
--health-timeout 5s
103+
--health-retries 10
104+
105+
env:
106+
NODE_TLS_REJECT_UNAUTHORIZED: '0'
107+
TEST_SQL_CONNECTION_STRING: "Server=localhost,1433;User Id=sa;Password=Moloko99;TrustServerCertificate=True"
108+
109+
steps:
110+
- name: Checkout
111+
uses: actions/checkout@v4
112+
113+
- name: Setup Node.js
114+
uses: actions/setup-node@v4
115+
with:
116+
node-version: '22'
117+
cache: 'npm'
118+
119+
- name: Setup .NET
120+
uses: actions/setup-dotnet@v4
121+
with:
122+
dotnet-version: '10.0.x'
123+
124+
- name: Setup .NET dev certs
125+
run: dotnet dev-certs https
126+
127+
- name: Install PSW CLI
128+
run: dotnet tool install -g PackageScriptWriter.Cli --prerelease
129+
130+
- name: Cache NuGet packages
131+
uses: actions/cache@v4
132+
with:
133+
path: ~/.nuget/packages
134+
key: nuget-${{ hashFiles('**/*.csproj') }}
135+
restore-keys: nuget-
136+
137+
- name: Install npm dependencies
138+
run: npm ci
139+
140+
- name: Build
141+
run: npm run build && npm run build -w packages/hosted-mcp && npm run build -w packages/create-mcp-server
142+
143+
- name: Run CLI E2E tests
144+
run: npm run test:e2e -w packages/create-mcp-server
145+
timeout-minutes: 20

.github/workflows/test.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,15 @@ jobs:
5252
- name: Build CLI package
5353
run: npm run build -w packages/create-mcp-server
5454

55+
# Smoke-test the bundled CLI: if dist/index.js can't load (e.g. a
56+
# relative-path require resolves differently after bundling), this
57+
# fails in seconds rather than surfacing only after publish.
58+
- name: CLI bundle smoke test
59+
run: |
60+
VERSION=$(node packages/create-mcp-server/dist/index.js --version)
61+
echo "CLI reports version: $VERSION"
62+
test -n "$VERSION"
63+
5564
# ── Unit tests (no infrastructure) ──
5665

5766
- name: SDK unit tests

package-lock.json

Lines changed: 7 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "umbraco-mcp-server-sdk-monorepo",
3-
"version": "17.0.0-beta.12",
3+
"version": "17.0.0-beta.13",
44
"private": true,
55
"description": "Umbraco MCP Server SDK monorepo",
66
"workspaces": [

packages/create-mcp-server/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@umbraco-cms/create-umbraco-mcp-server",
3-
"version": "17.0.0-beta.12",
3+
"version": "17.0.0-beta.13",
44
"type": "module",
55
"description": "Create a new Umbraco MCP server project",
66
"bin": {

0 commit comments

Comments
 (0)