Skip to content

fix: remove happy-coder from global tooling - #741

Merged
keito4 merged 2 commits into
mainfrom
fix/repo-maintenance-global-cli-overrides
Jun 1, 2026
Merged

fix: remove happy-coder from global tooling#741
keito4 merged 2 commits into
mainfrom
fix/repo-maintenance-global-cli-overrides

Conversation

@keito4

@keito4 keito4 commented May 12, 2026

Copy link
Copy Markdown
Owner

Summary

  • Remove happy-coder from global CLI tooling and DevContainer installation.
  • Keep npm/global.json overridden: true entries pinned during library refreshes.
  • Document the override behavior for repo-maintenance propagation.

Root Cause

happy-coder@1.1.8 published a package with a workspace:* dependency, which breaks plain npm global installation and Docker image builds. Since the tool is no longer used, removing it is simpler than pinning an older version.

Validation

  • npm run format:check
  • npm run lint
  • npm test
  • npm install -g --prefix .context/npm-global-no-happy-test eslint typescript typescript-language-server @openai/codex@0.130.0 vercel@53.3.2 @google/gemini-cli@0.41.2 difit@4.0.7 --loglevel=error

Summary by CodeRabbit

  • Documentation
    • Updated internal documentation regarding dependency management and npm package installation procedures to clarify handling of overridden packages and legacy peer dependency resolver behavior.

@coderabbitai

coderabbitai Bot commented May 12, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: d8d06318-bceb-4315-ab7a-c29513e176fd

📥 Commits

Reviewing files that changed from the base of the PR and between ba816a9 and b10c690.

📒 Files selected for processing (2)
  • .claude/commands/repo-maintenance.md
  • script/README.md

📝 Walkthrough

Walkthrough

Documentation updates clarify npm package override behavior and global CLI installation resolver configuration. Changes specify that script/update-libraries.sh respects npm/global.json overridden: true entries, and that global CLI installation uses npm's legacy peer dependency resolver to align with DevContainer builds.

Changes

npm Dependency and DevContainer Documentation

Layer / File(s) Summary
npm override respect and installation documentation
.claude/commands/repo-maintenance.md, script/README.md
Documented that npm/global.json overridden: true entries are respected by library updates, and that install-npm-globals.sh uses npm's legacy peer dependency resolver to match DevContainer behavior.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Possibly related PRs

  • keito4/config#752: Documents same override-respect behavior that PR #752 implements in update-libraries.sh by skipping overridden packages.
  • keito4/config#129: Clarifies library update behavior for the same script/update-libraries.sh updater script introduced in that PR.
  • keito4/config#444: Documents override flag handling that aligns with PR #444's addition of new entries with overridden: false to npm/global.json.

Suggested labels

size/S

Poem

A rabbit hops through docs so fine,
Respecting overrides—no line crossed!
DevContainers now align,
Legacy resolvers keep npm's plight,
🐰 clarity brought to light! 🌟

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The PR title 'fix: remove happy-coder from global tooling' directly aligns with the primary change: removing the happy-coder package from global CLI tooling due to a breaking workspace:* dependency.
Description check ✅ Passed The PR description covers all required sections from the template: Summary, Root Cause (Why), detailed changes (What), and Validation steps. Documentation updates are explained with specific file modifications.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/repo-maintenance-global-cli-overrides

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@keito4
keito4 force-pushed the fix/repo-maintenance-global-cli-overrides branch from f81811a to 062827a Compare May 25, 2026 12:38
@keito4
keito4 marked this pull request as ready for review June 1, 2026 06:20
@claude

claude Bot commented Jun 1, 2026

Copy link
Copy Markdown
Contributor

Claude finished @keito4's task in 3m 15s —— View job


PR Review - fix: remove happy-coder from global tooling

  • コンテキスト収集
  • 変更内容のレビュー
  • フィードバックの投稿

概要

このPRは「happy-coder をグローバルツールから削除する」と謳っていますが、実際のコード変更はドキュメント追加のみ(+4行、削除0行)です。以下に詳細なレビューを示します。


🔴 Major: happy パッケージが実際には削除されていない

PR概要では「Remove happy-coder from global CLI tooling and DevContainer installation」と記載されていますが、happy パッケージへの参照がすべてのオペレーショナルファイルに残っています。

ファイル 残存する参照
npm/global.json:24 "happy": {"version": "1.1.8", "overridden": false}
script/install-npm-globals.sh:33 PACKAGES 配列に "happy" が残存
.devcontainer/Dockerfile:119,128 HAPPY_VERSION 読み取り + happy@${HAPPY_VERSION} インストール
.devcontainer/devcontainer.json:44 ~/.happy バインドマウント

もし happyhappy-coder が同一パッケージであれば、PR概要に記載された破損パッケージ(workspace:* 依存)は依然としてDockerビルドとpostCreateインストールに影響します。

削除が必要なファイル:

# npm/global.json
-    "happy": {
-      "version": "1.1.8",
-      "overridden": false
-    },

# script/install-npm-globals.sh
-    "happy"

# .devcontainer/Dockerfile:119-128
-  && HAPPY_VERSION=$(node -pe "require('/tmp/npm-global.json').dependencies['happy'].version") \
...
-    happy@${HAPPY_VERSION} \

# .devcontainer/devcontainer.json:44
-    "source=${localEnv:HOME}/.happy,target=/home/vscode/.happy,type=bind,consistency=cached"

Fix this →


✅ 良い点

.claude/commands/repo-maintenance.md の追記(+3行):

Global CLI manifest の更新では、`npm/global.json``overridden: true` を必ず尊重する。
壊れた latest npm package(例: `workspace:*` を含む package)が Docker build や postCreate install を壊さないよう、`script/update-libraries.sh` は overridden package を更新しない。

overridden: true の挙動を文書化する意図は良く、将来の同様の問題に対する防護柵として有効です。

script/README.md の追記(+1行):

Uses npm's legacy peer dependency resolver for global CLI packages to match DevContainer builds.

--legacy-peer-deps の理由を明記するのは適切です(ADR 0004との整合性あり)。


📌 確認事項

happy-coderhappy別のnpmパッケージという可能性もあります。その場合:

  • happy-coder が別ファイルやdevcontainerイメージ側で既に削除済みであれば、このPRのドキュメント変更のみで意図が達成されている可能性があります
  • PR概要に「既に別途削除済み」という補足があると明確になります

結論

happy パッケージが npm/global.jsonDockerfileinstall-npm-globals.shdevcontainer.json に残存しているという点を確認いただき、意図通りの削除が完了していなければコード変更の追加をお願いします。ドキュメント部分の変更自体は問題ありません。

@keito4 keito4 self-assigned this Jun 1, 2026
@keito4
keito4 merged commit 1165eb9 into main Jun 1, 2026
4 checks passed
@keito4
keito4 deleted the fix/repo-maintenance-global-cli-overrides branch June 1, 2026 06:32
@github-actions

github-actions Bot commented Jun 1, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 1.113.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@github-actions github-actions Bot added the released リリース済み label Jun 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

released リリース済み

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant