chore: fix release publishing OOM#71
Conversation
Greptile SummaryThis PR fixes a Node.js OOM crash in the release workflow by raising the heap limit to 8192 MB for TypeScript SDK builds, bumps all Cargo workspace packages to 1.6.0, adds
Confidence Score: 4/5Safe to merge; all changed code paths are additive or targeted bug fixes with no regressions to existing behavior. The OOM fix, Cargo lock alignment, and Rust CLI additions are all correct and low-risk. The only gaps are that the manager SDK step in publish-client-sdks and the generate:manager-api local script were not given the same heap bump, leaving them vulnerable to the same class of failure if those SDKs grow. .github/workflows/release.yml — the Build and publish manager API SDK step at line 254 and package.json's generate:manager-api script both lack the new NODE_OPTIONS set for their platform SDK counterparts.
|
| Filename | Overview |
|---|---|
| .github/workflows/release.yml | Raises heap limit in publish-npm and publish-client-sdks platform step; manager SDK step in publish-client-sdks is missing the same limit. |
| package.json | Adds NODE_OPTIONS to generate:platform-api script; generate:manager-api is not updated consistently. |
| Cargo.lock | Workspace package versions bumped from 1.5.1 to 1.6.0 across all alien-* crates; no logic changes. |
| crates/alien-cli/src/commands/deployments.rs | Adds --json flag to ls and get, threads allow_bootstrap through resolve_manager_client to suppress interactive prompts in non-TTY/JSON mode. |
| crates/alien-cli/src/commands/logs.rs | Constrains Deepstore text search to body.message only via DEFAULT_LOG_SEARCH_FIELDS; applied consistently to both fetch and follow paths. |
| crates/alien-cli/src/commands/releases.rs | Updated call-site for resolve_manager_client to pass allow_bootstrap=true; no behavioral change. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[alien deployments ls/get] --> B{--json flag?}
B -- Yes --> C[allow_bootstrap = false\nno interactive prompts]
B -- No --> D[allow_bootstrap = true\nprompt for project if needed]
C --> E[resolve_manager_client]
D --> E
E --> F[Fetch from manager API]
F --> G{json mode?}
G -- Yes --> H[print_json output]
G -- No --> I[Render human-readable table/detail]
J[alien logs --query TEXT] --> K[fetch_logs / follow_logs]
K --> L[SearchParams\nsearch_fields: body.message]
L --> M[Deepstore search\nscoped to body.message only]
Comments Outside Diff (1)
-
.github/workflows/release.yml, line 254-261 (link)Manager SDK build missing memory limit
The
publish-client-sdksjob now setsNODE_OPTIONS: "--max-old-space-size=8192"for the platform SDK step, but the immediately following "Build and publish manager API SDK" step has no correspondingNODE_OPTIONS. If the manager SDK reaches similar complexity, it will hit the same default 4 GB heap limit and fail at publish time with no indication of why.Prompt To Fix With AI
This is a comment left during a code review. Path: .github/workflows/release.yml Line: 254-261 Comment: **Manager SDK build missing memory limit** The `publish-client-sdks` job now sets `NODE_OPTIONS: "--max-old-space-size=8192"` for the platform SDK step, but the immediately following "Build and publish manager API SDK" step has no corresponding `NODE_OPTIONS`. If the manager SDK reaches similar complexity, it will hit the same default 4 GB heap limit and fail at publish time with no indication of why. How can I resolve this? If you propose a fix, please make it concise.
Prompt To Fix All With AI
Fix the following 2 code review issues. Work through them one at a time, proposing concise fixes.
---
### Issue 1 of 2
.github/workflows/release.yml:254-261
**Manager SDK build missing memory limit**
The `publish-client-sdks` job now sets `NODE_OPTIONS: "--max-old-space-size=8192"` for the platform SDK step, but the immediately following "Build and publish manager API SDK" step has no corresponding `NODE_OPTIONS`. If the manager SDK reaches similar complexity, it will hit the same default 4 GB heap limit and fail at publish time with no indication of why.
### Issue 2 of 2
package.json:16
**`generate:manager-api` not updated to match**
`generate:platform-api` now runs with `NODE_OPTIONS=--max-old-space-size=8192`, but the adjacent `generate:manager-api` script does not. Developers running either script locally will get different memory limits for what are structurally identical codegen pipelines.
Reviews (1): Last reviewed commit: "fix: stabilize release publishing" | Re-trigger Greptile
| "build:images": "echo 'Use GitHub Actions workflows (.github/workflows/images*.yml) for canonical image builds'", | ||
| "generate": "turbo run generate", | ||
| "generate:platform-api": "speakeasy generate sdk --lang typescript --schema ./client-sdks/platform/openapi.json --out client-sdks/platform/typescript && pnpm -C ./client-sdks/platform/typescript build", | ||
| "generate:platform-api": "speakeasy generate sdk --lang typescript --schema ./client-sdks/platform/openapi.json --out client-sdks/platform/typescript && NODE_OPTIONS=--max-old-space-size=8192 pnpm -C ./client-sdks/platform/typescript build", |
There was a problem hiding this comment.
generate:manager-api not updated to match
generate:platform-api now runs with NODE_OPTIONS=--max-old-space-size=8192, but the adjacent generate:manager-api script does not. Developers running either script locally will get different memory limits for what are structurally identical codegen pipelines.
Prompt To Fix With AI
This is a comment left during a code review.
Path: package.json
Line: 16
Comment:
**`generate:manager-api` not updated to match**
`generate:platform-api` now runs with `NODE_OPTIONS=--max-old-space-size=8192`, but the adjacent `generate:manager-api` script does not. Developers running either script locally will get different memory limits for what are structurally identical codegen pipelines.
How can I resolve this? If you propose a fix, please make it concise.Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
Linear: ALIEN-188
Summary
Root cause
The release workflow failed while building @alienplatform/platform-api because tsc exhausted Node's default heap around 4 GB. ../platform already builds the same SDK with --max-old-space-size=8192.
Validation