ember-codemods / ember-module-migrator

Automated migration for new Ember application layout.
74 stars 15 forks source link

The Broccoli Plugin: [Funnel: Funnel: index.html] failed with: Error: Attempting to watch missing directory: .../app-name/app #64

Open psteininger opened 6 years ago

psteininger commented 6 years ago

after running ember-module-migrator even on a brand new Ember 2.16 project one get's the following

The Broccoli Plugin: [Funnel: Funnel: index.html] failed with:
Error: Attempting to watch missing directory: /Users/piotr/lv/next/tttttt/app
    at Watcher_addWatchDir [as addWatchDir] (/Users/piotr/lv/next/tttttt/node_modules/ember-cli-broccoli-sane-watcher/index.js:142:11)
    at /Users/piotr/lv/next/tttttt/node_modules/broccoli-builder/lib/builder.js:135:35
    at tryCatch (/Users/piotr/lv/next/tttttt/node_modules/rsvp/dist/rsvp.js:525:12)
    at invokeCallback (/Users/piotr/lv/next/tttttt/node_modules/rsvp/dist/rsvp.js:538:13)
    at /Users/piotr/lv/next/tttttt/node_modules/rsvp/dist/rsvp.js:606:14
    at flush (/Users/piotr/lv/next/tttttt/node_modules/rsvp/dist/rsvp.js:2415:5)
    at _combinedTickCallback (internal/process/next_tick.js:131:7)
    at process._tickCallback (internal/process/next_tick.js:180:9)

The broccoli plugin was instantiated at: 
    at Funnel.Plugin (/Users/piotr/lv/next/tttttt/node_modules/broccoli-plugin/index.js:7:31)
    at new Funnel (/Users/piotr/lv/next/tttttt/node_modules/ember-cli/node_modules/broccoli-funnel/index.js:57:10)
    at EmberApp._rawAppIndex (/Users/piotr/lv/next/tttttt/node_modules/ember-cli/lib/broccoli/ember-app.js:762:12)
    at EmberApp.index (/Users/piotr/lv/next/tttttt/node_modules/ember-cli/lib/broccoli/ember-app.js:745:20)
    at EmberApp.toArray (/Users/piotr/lv/next/tttttt/node_modules/ember-cli/lib/broccoli/ember-app.js:1806:12)
    at EmberApp.toTree (/Users/piotr/lv/next/tttttt/node_modules/ember-cli/lib/broccoli/ember-app.js:1831:32)
    at module.exports (/Users/piotr/lv/next/tttttt/ember-cli-build.js:24:14)
    at Builder.setupBroccoliBuilder (/Users/piotr/lv/next/tttttt/node_modules/ember-cli/lib/models/builder.js:56:19)
    at new Builder (/Users/piotr/lv/next/tttttt/node_modules/ember-cli/lib/models/builder.js:30:10)
    at ServeTask.run (/Users/piotr/lv/next/tttttt/node_modules/ember-cli/lib/tasks/serve.js:24:55)
RobbieTheWagner commented 6 years ago

I'm also seeing this. @rwjblue any idea what could be causing this?

rwjblue commented 6 years ago

I think it is a regression in ember-cli where we essentially require the app/ directory to be present. We should confirm, and make sure it is reported upstream...

RobbieTheWagner commented 6 years ago

Sounds good. I was planning to migrate most of my apps, but maybe that isn't a good idea yet? I'm not sure when module unification is supposed to land.

charlesfonlupt commented 6 years ago

I have the same problem with :

ember-cli: 2.18.0-beta.1
node: 8.9.1
os: darwin x64

Any update ?

ghost commented 6 years ago

This is related to / possible dupe https://github.com/ember-cli/ember-cli/issues/7343. Upon catching that error, I saw the one mentioned in this ticket appear.

RobbieTheWagner commented 6 years ago

Any ideas when this might be fixed? I'm unsure when module unification is supposed to drop, so no real hurry, but would like to start getting used to the new directory structure ahead of time.

ef4 commented 6 years ago

I reproduced this issue and it comes down to having an ember-cli version that doesn't have MU enabled.

AFAIK you need to use ember-cli from master if you want to try turning on MU.

You can verify by looking in node_modules/ember-cli/lib/experiments/index.html. If it says MODULE_UNIFICATION: false, it's not going to work.

ef4 commented 6 years ago

The exact place where the code tries to watch app is here:

https://github.com/ember-cli/ember-cli/blob/89511a774c4d64adb3147c7e0245ae932eff82fd/lib/broccoli/ember-app.js#L223-L227

I'm linking to code from the latest stable release, master has already changed from this.