Skip to content

Remove npm install from query scripts — deps managed by start-server.sh#193

Merged
atheurer merged 1 commit into
masterfrom
remove-redundant-npm-install
Jun 12, 2026
Merged

Remove npm install from query scripts — deps managed by start-server.sh#193
atheurer merged 1 commit into
masterfrom
remove-redundant-npm-install

Conversation

@atheurer

Copy link
Copy Markdown
Contributor

Summary

  • Removes redundant npm install from 5 query wrapper scripts (add-run.sh, delete-run.sh, get-metric-data.sh, get-primary-periods.sh, get-result-summary.sh)
  • Dependencies are already installed by start-server.sh which runs at CDM server startup with a stamp-file guard
  • Running npm install inside containers with overlay fs causes ENOTEMPTY failures when npm tries to rmdir directories from lower layers
  • Replaces with a simple node_modules existence check and clear error message

Context

Discovered via agentic-perf automated runs (PERF-7140E67D, PERF-D095E672): fio benchmarks complete successfully but OpenSearch indexing fails because npm install inside the crucible controller container hits overlay fs issues (ENOTEMPTY: directory not empty, rmdir 'node_modules/js-yaml/lib'). This is a follow-up to PR #192 which added error reporting — this PR eliminates the root cause.

Test plan

  • Run crucible run with a benchmark — verify add-run.sh succeeds (node_modules present from start-server.sh)
  • Verify start-server.sh still installs deps on first launch
  • Manually remove node_modules and run add-run.sh — verify clear error message

🤖 Generated with Claude Code

The CDM server startup (start-server.sh) already installs npm
dependencies with a stamp-file guard. Running npm install redundantly
in every query script (add-run, delete-run, get-metric-data,
get-primary-periods, get-result-summary) is unnecessary and causes
failures inside containers where overlay fs prevents npm from
replacing directories (ENOTEMPTY on rmdir).

Replace with a simple check that node_modules exists, with a clear
error message pointing to start-server.sh if it doesn't.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@atheurer atheurer merged commit 495e1eb into master Jun 12, 2026
38 checks passed
@github-project-automation github-project-automation Bot moved this from In Progress to Done in Crucible Tracking Jun 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants