Describe the bug
Hey folks! I'm evaluating the use of ibazel with our monorepo and stumbled onto a relatively nasty bug where ibazel would fail to restart my relatively large JS application.
Reproduction instructions
https://github.com/markovejnovic/ibazel-js-repro
git clone https://github.com/markovejnovic/ibazel-js-repro.git
cd ibazel-js-repro
ibazel run //:dev
# wait until it prints 'hello world'
# edit src/main.ts to print a different string
# note ibazel doesn't catch it
Expected behavior
Ibazel restarts my target after a source file changes.
Actual behavior
Ibazel doesn't restart my target.
Version (please complete the following information):
- OS: macOS
- ibazel Version: iBazel - Version 0.29.0, present on
HEAD
- Bazel version: 9.1.0
Additional context
I think the bug is in ibazel.go:650. When labelsToWatch filters for labels that should be watched, it has special handling for localRepositories. aspect's external targets start with @ and are referenced as localRepositories, which means that we hit the break in ibazel.go:650.
To be 100% honest, I don't really understand the intent behind this function and this was discovered by getting claude to sprinkle debug statements across the program, so I might be wrong in my guess, but changing the break to a continue does populate the toWatch list as I would expect.
Describe the bug
Hey folks! I'm evaluating the use of
ibazelwith our monorepo and stumbled onto a relatively nasty bug where ibazel would fail to restart my relatively large JS application.Reproduction instructions
https://github.com/markovejnovic/ibazel-js-repro
Expected behavior
Ibazel restarts my target after a source file changes.
Actual behavior
Ibazel doesn't restart my target.
Version (please complete the following information):
HEADAdditional context
I think the bug is in
ibazel.go:650. WhenlabelsToWatchfilters for labels that should be watched, it has special handling forlocalRepositories.aspect's external targets start with@and are referenced aslocalRepositories, which means that we hit thebreakinibazel.go:650.To be 100% honest, I don't really understand the intent behind this function and this was discovered by getting claude to sprinkle debug statements across the program, so I might be wrong in my guess, but changing the
breakto acontinuedoes populate thetoWatchlist as I would expect.