Skip to content

fix(cli): unnecessary subprocess call on every run - #2083

Merged
aws-cdk-automation merged 2 commits into
mainfrom
huijbers/skip-subprocess
Oct 23, 2026
Merged

aws-cdk-automation merged 2 commits into
mainfrom
huijbers/skip-subprocess

Conversation

@rix0rrr

@rix0rrr rix0rrr commented Oct 23, 2026

Copy link
Copy Markdown
Contributor

For determining the version of aws-cdk-lib that a user might be using, the CLI used to run a node subprocess on every invocation.

Instead, we can do the same resolution inside the host node process, saving a subprocess call; saves ~80ms on every CLI invocation.


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

For determining the version of `aws-cdk-lib` that a user might be using,
the CLI used to run a `node` subprocess on every invocation.

Instead, we can do the same resolution inside the host `node` process,
saving a subprocess call; saves ~80ms on every CLI invocation.
@rix0rrr
rix0rrr deployed to automation October 23, 2026 12:30 — with GitHub Actions Active
@rix0rrr
rix0rrr requested a review from a team October 23, 2026 12:30
@rix0rrr
rix0rrr deployed to no-approval October 23, 2026 12:30 — with GitHub Actions Active
@github-actions github-actions Bot added the p2 label Oct 23, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

@aws-cdk-automation
aws-cdk-automation added this pull request to the merge queue Oct 23, 2026
Merged via the queue into main with commit 0c223c4 Oct 23, 2026
81 of 83 checks passed

This branch was successfully deployed

2 active (1 outdated) and 1 inactive deployments
run-tests — 332e85c9 Deployed Oct 23, 2026 by iankhou via integ_cli (cli-integ-tests, 24.19, 8) #7442
no-approval — 332e85c9 Deployed Oct 23, 2026 by iankhou via prepare #7442
automation — 6f27688e Deployed Oct 23, 2026 by rix0rrr via Set AutoQueue on PR #2083 #3851
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants