ember.js
ember.js copied to clipboard
[Bug] Duplicate `remove` logs when destroying a blueprint
🐞 Describe the Bug
Since v4.4.1, destroying e.g. a component shows duplicate remove logs:
uninstalling component
remove addon/components/foo.hbs
uninstalling component-test
remove tests/integration/components/foo-test.js
remove tests/integration/components/foo-test.js (duplicate)
uninstalling component-addon
remove app/components/foo.js
remove app/components/foo.js (duplicate)
🔬 Minimal Reproduction
npx ember-cli addon foo
cd foo
ember g component foo
ember d component foo
It's also reproducible when generating an app, or destroying e.g. a controller, route, ...
😕 Actual Behavior
Duplicate remove logs are being printed when running the ember d component foo command.
🤔 Expected Behavior
The remove logs are printed only once per blueprint type (main, test, addon).
🌍 Environment
- Ember: v4.4.1
- Node.js/npm: v16 / Yarn v1
- OS: macOS
- Browser: N/A
➕ Additional Context
The issue does not happen on Ember < v4.4.0. This seems related to https://github.com/emberjs/ember.js/pull/19962. It's not yet clear to me if that PR is the actual cause or if something else is wrong.
Hey, could you tell me which files should I be looking into for this issue? Thanks
@kirtan-desai My initial idea was that this line could be related: https://github.com/emberjs/ember.js/pull/19962/files#diff-e1d24ae1c27f7810153391ad26d343a5e940afd53cceff9fe1d87046ade6730dR15
Not sure though, haven't looked into it any further, but the PR linked in this issue's description is most likely the culprit.
Seems "fixed" since we've enabled the EMBER_TYPESCRIPT_BLUEPRINTS flag by default.