Repository navigation
fix(create-blocks-app): install one copy of @aws-cdk-blocks/core in a new app - #1661
Merged
Merged
Conversation
2 of 3 tasks
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 08:59 — with
GitHub Actions
Failure
Contributor
📖 Glossary & notes — scoring, indicators, per-metric thresholds (click to expand)
Results — PR vs
|
| Task | Template | Tests | Judge | Cost | Turns | Score | Stop reason |
|---|---|---|---|---|---|---|---|
| async-word-counter | bare | ✅ 13/13 (0) | ❌ $9.21 (+$4.7) | ❌ 37 (+15) | ❌ 10.5 (-11.3) | endTurn | |
| auth-notes | demo | — | — | ❌ $32.28 (+$7.4) | ❌ 79 (+14) | — | in_progress |
| cognito-profile | auth | — | — | ✨ $18.73 (-$10.38) | ✨ 52 (-22) | — | in_progress |
| collab-presence-board | default | ✅ 11/11 (0) | ✨ 9.2 (+0.4) | ✅ 17 (0) | ✅ 25.5 (-4.2) | endTurn | |
| email-digest | demo | 🗑️ removed (was 12/12) | — | — | — | — | — |
| file-gallery | bare | ✅ 12/12 (0) | ✅ 9 (-0.2) | ✨ $1.84 (-$0.89) | ✅ 12 (-1) | ✨ 52.1 (+16.7) | endTurn |
| kb-chat-agent | demo | 🗑️ removed (was 9/9) | — | — | — | — | — |
| observability-api | backend | — | — | ❌ $15.94 (+$12.01) | ❌ 36 (+11) | — | in_progress |
| oidc-dsql-notes | react | — | — | — | — | — | — |
| sql-kb-catalog | nextjs | — | — | ✨ $3.76 (-$4.76) | ✨ 15 (-14) | — | in_progress |
Merge verdict
✅ This bench run does not block the PR.
- ✅ Absolute floor — mean composite 96.5 >= floor 65.
- ✅ Regression vs
main— mean composite delta +9.9 pts vs main is within the 10-pt limit.
The Δ vs base ball above is a fixed ±5-pt display band; the regression gate uses BENCH_MAX_REGRESSION. The ball is cosmetic — the gate threshold is what blocks.
Caveats & exclusions
- 🧰 Excluded (harness_error, not scored) — 5: 4× cancelled, 1× preflight_failed. Cells:
auth-notes/demo,cognito-profile/auth,observability-api/backend,oidc-dsql-notes/react,sql-kb-catalog/nextjs
pranavosu
force-pushed
the
fix/rc-single-core-and-readme-imports
branch
from
November 19, 2026 16:40
49521ef to
151341c
Compare
harsh62
previously approved these changes
Nov 19, 2026
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:08 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:08 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:08 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:08 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:08 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:08 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:08 — with
GitHub Actions
Error
… new app Templates declared @types/node ^20.19.43. The optional peer chain of @aws-cdk-blocks/core (unctx -> unplugin -> vitest) ends in @types/node ^22.0.0 || >=24.0.0, so npm nested a copy of core under every block and none at the root. Templates and the backend/Amplify setups now declare ^22.12.0, matching their Node >=22 engine. The canary now fails when a scaffold installs more than one core, and sets the lowercase npm_config_userconfig as well, so the scaffold's own npm install reads the canary registry instead of ~/.npmrc.
pranavosu
force-pushed
the
fix/rc-single-core-and-readme-imports
branch
from
November 19, 2026 17:28
151341c to
3613866
Compare
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:49 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:49 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:49 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:49 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:49 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:49 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:49 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:49 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:49 — with
GitHub Actions
Error
pranavosu
had a problem deploying
to
agent-bench
November 19, 2026 17:49 — with
GitHub Actions
Error
svidgen
approved these changes
Nov 20, 2026
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
A new app scaffolded by
create-blocks-appinstalls one copy of@aws-cdk-blocks/coreunder every block (21 to 25 copies) and none at the top level.corekeeps module-level registries, so the copies don't share state:getSdkIdentifiers()returns{}for every block, locally and in Lambda.instanceof ApiErroron the server.@aws-cdk-blocks/corecan't be imported from app code (TS2307,ERR_MODULE_NOT_FOUND).The cause is the templates'
@types/node^20.19.43.core's optional peer chain (unctx→unplugin→vitest) ends in@types/node^22.0.0 || >=24.0.0. npm takes optional peers into account when placing packages, so it can't putcoreat the top of the app. Published 0.9.0 has the same problem today.Separately, the
KVStoreandDatabaseREADME examples import from@aws-cdk-blocks/core,bb-auth,bb-kv-storeandbb-database, which a scaffolded app doesn't declare, so a copied example doesn't compile. TheKVStoreREADME also points totransaction()in two packages that don't exist.Issue #, if available: none
Changes
create-blocks-appdeclare@types/node^22.12.0. That is the lowest version that satisfies bothvite(^20.19.0 || >=22.12.0) andvitest(^22.0.0 || >=24.0.0), and it matches the templates' Node>=22engine.scripts/canary/run-canary.ts:@aws-cdk-blocks/core.npm_config_userconfig.npm run canaryexportsnpm_config_userconfig=~/.npmrc, and the scaffold's ownnpm installread that instead of the canary's.npmrc, so the app installed@aws-cdk-blocks/*from the public registry rather than from the local build. CI may be affected the same way: the canary passes daily while testing already-published packages.bb-kv-storeandbb-databaseREADMEs import their examples fromaws-cdk-blocks; the/kyselyand/testingentry points still come from@aws-cdk-blocks/bb-database. TheKVStoreREADME links toDatabasetransactions.bb-kv-store/scripts/generate-readme-test.mjscompiles the README snippets against the package's own types. It now resolves each name imported fromaws-cdk-blocksto the module the umbrella re-exports it from: this package's mock entry, theAuthstand-in, or@aws-cdk-blocks/core. The umbrella depends on this package, so importing it directly from the generated test made the build fail with TS5055.Validation
I ran the canary locally against
npm run publish:localand the local registry:@types/nodecoresql^20.19.43sql^22.12.0cdk synthpassapi-only^22.12.0cdk synthpassreact^22.12.0cdk synthpassAfter the
userconfigfix, every@aws-cdk-blocks/*entry in the scaffolded app's lockfile resolves from the local registry (24 of 24, previously 0 of 30).Rebased on
mainafter the package rename (chore: rename packages to @aws-cdk-blocks, umbrella to unscoped aws-cdk-blocks #1627): names are@aws-cdk-blocks/*and theaws-cdk-blocksumbrella.npm run buildandnpm run lintpass. Tests pass forbb-kv-store(321, including the README snippet test),bb-database(372) andblocks(634 + 52), and thesqlcanary passes again from the local registry with onecore.npm run lintpasses.packages/blockstests pass.packages/create-blocks-apptests pass, except "refuses to scaffold into an npm workspace that does not list the app's cdk-blocks/ folder", which also fails locally on unmodifiedmain.The README import changes were exercised in a scaffolded
sqlapp against thecanary-rc-1-0build: the Database Quick start compiles and runs with theaws-cdk-blocksimports.Checklist
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.