refactor(deps): gazelle migration phase 1 — inline thin wrappers#6197
Merged
refactor(deps): gazelle migration phase 1 — inline thin wrappers#6197
Conversation
Replace all ts_binary() calls with js_binary() + --experimental-transform-types directly in BUILD.bazel files (22 calls across 9 files). Remove all package_json_test() calls which were dead code (28 files). This is the first step toward making ts_project targets visible to gazelle for automatic dep management. See knowledge-base/migrations/001-gazelle-migration.md. Also add knowledge-base update reminder to CLAUDE.md. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
longlho
added a commit
that referenced
this pull request
Mar 30, 2026
Revert the BUILD file changes from phases 1-3 of the gazelle migration: - Phase 1: inline ts_binary -> js_binary (#6197) - Phase 2: decompose ts_compile macros (#6198) - Phase 3+4: decompose vitest, enable gazelle JS (#6199) Keep gazelle scaffolding (aspect-gazelle setup, multitool, lefthook integration) and knowledge-base documentation. The migration approach of using map_kind + copy_to_bin caused conflicting actions between gazelle-managed srcs and copy_to_bin outputs. A different approach is needed. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2 tasks
longlho
added a commit
that referenced
this pull request
Mar 30, 2026
## Summary Revert the BUILD file changes from the gazelle migration (phases 1-3) while keeping the scaffolding and documentation. ### Reverted - Phase 1: `ts_binary` → `js_binary` inlining (#6197) - Phase 2: `ts_compile` macro decomposition (#6198) - Phase 3+4: `vitest` decomposition + gazelle JS enablement (#6199) ### Kept - Gazelle scaffolding: aspect-gazelle setup, multitool, lefthook integration (#6195) - Knowledge-base documentation (#6196) ### Why The `map_kind` + `copy_to_bin` approach caused conflicting actions — both `copy_to_bin(name = "srcs")` and gazelle's direct file lists produce the same output files through `ts_project`. A different approach is needed that either eliminates `copy_to_bin` or uses a custom gazelle extension. ## Test plan - [x] 495 tests pass - [ ] CI passes 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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.
Summary
Gazelle migration phase 1: inline thin Bazel macro wrappers so
ts_projecttargets can eventually be made visible to gazelle for automatic dependency management.Changes
1. Replace
ts_binarywithjs_binary(22 calls across 9 files)ts_binarywas a thin wrapper that just added--experimental-transform-typestonode_options. Now inlined directly:2. Remove
package_json_test(28 files)Dead code — the actual test body was commented out. Only created a
copy_to_bin(name = "package")target that nothing depended on.3. Update migration doc + CLAUDE.md
knowledge-base/migrations/001-gazelle-migration.mdWhat's NOT changed
tools/index.bzlis untouched — macros remain available for referencets_compile,ts_compile_node,vitest,generate_src_filemacros are untouched (phases 2-3)Test plan
pnpm t— all 495 tests pass🤖 Generated with Claude Code