vendredi 28 avril 2017

Ember Template Compiler JS plugin not working when pre-compiled in Ember CLI rails appl

I am using ember-template-compiler.js as one of the dependency plugin in EmberCLI Rails application for Ember Handlebar templates . When I am trying to pre-compile the assets I am getting the following issue.

EmberCli::App::BuildError: EmberCLI app "account_settings" has failed to build
TypeError: Cannot read property 'length' of undefined

  at Object.TransFormDotComponentInvocation._isMulipartPath (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:14387:24)

  at Object.TransFormDotComponentInvocation._isInlineInvocation (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:14391:16)

  at traverse.MustacheStatement (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:14416:21)

  at visitNode (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2753:36)

  at visitKey (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2791:27)

  at visitNode (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2767:17)

  at visitArray (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2805:26)

  at visitKey (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2789:13)

  at visitNode (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2767:17)

  at visitArray (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2805:26)

  at visitKey (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2789:13)

  at visitNode (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2767:17)

  at visitArray (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2805:26)

  at visitKey (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2789:13)

  at visitNode (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2767:17)

  at visitKey (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2791:27)

  at visitNode (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2767:17)

  at visitArray (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2805:26)

  at visitKey (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2789:13)

  at visitNode (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2767:17)

  at visitArray (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2805:26)

  at visitKey (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2789:13)

  at visitNode (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2767:17)

  at visitArray (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2805:26)

  at visitKey (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2789:13)

  at visitNode (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2767:17)

  at traverse (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:2841:9)

  at Object.TransFormDotComponentInvocation.transform (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:14414:7)

  at Object.preprocess (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:3463:35)

  at precompile (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:1290:34)

  at Object.precompile (<app_folder_rails>/account_settings/bower_components/ember/ember-template-compiler.js:15389:12)

  at Object.module.exports.template (<app_folder_rails>/account_settings/node_modules/ember-cli-htmlbars/utils.js:29:40)

  at TemplateCompiler.processString (<app_folder_rails>/account_settings/node_modules/ember-cli-htmlbars/index.js:68:36)

  at Promise.then.result.output (<app_folder_rails>/account_settings/node_modules/broccoli-persistent-filter/lib/strategies/persistent.js:41:23)

  at initializePromise (<app_folder_rails>/account_settings/node_modules/rsvp/dist/rsvp.js:589:5)

  at new Promise$1 (<app_folder_rails>/account_settings/node_modules/rsvp/dist/rsvp.js:1077:33)

  at <app_folder_rails>/account_settings/node_modules/broccoli-persistent-filter/lib/strategies/persistent.js:40:18

  at tryCatch (<app_folder_rails>/account_settings/node_modules/rsvp/dist/rsvp.js:539:12)

  at invokeCallback (<app_folder_rails>/account_settings/node_modules/rsvp/dist/rsvp.js:554:13)

  at publish (<app_folder_rails>/account_settings/node_modules/rsvp/dist/rsvp.js:522:7)

  at flush (<app_folder_rails>/account_settings/node_modules/rsvp/dist/rsvp.js:2414:5)

  at _combinedTickCallback (internal/process/next_tick.js:67:7)

  at process._tickCallback (internal/process/next_tick.js:98:9)
Tasks: TOP => assets:precompile => ember:compile

Previously it had worked well. I am using the following node and ember versions.

ember-cli: 2.7.0
node: 6.2.1
os: linux ia32
Ruby: 2.3.1
Rails: 4.2.1
npm: 3.9.3
OS: Ubuntu 16.04

Also Please check bower.json , package.json file data as follows

bower.json:
{
  "name": "account-settings",
  "dependencies": {
    "ember": "^2.0",
    "ember-cli-shims": "0.0.6",
    "ember-cli-test-loader": "0.2.1",
    "ember-data": "^2.0",
    "ember-load-initializers": "0.1.7",
    "ember-qunit": "0.4.16",
    "ember-qunit-notifications": "0.1.0",
    "ember-resolver": "~0.1.20",
    "jquery": "^1.11.3",
    "loader.js": "ember-cli/loader.js#3.4.0",
    "qunit": "~1.20.0"
  }
}

And

   package.json:
    {
      "name": "account-settings",
      "version": "0.0.0",
      "description": "Small description for account-settings goes here",
      "private": true,
      "directories": {
        "doc": "doc",
        "test": "tests"
      },
      "scripts": {
        "build": "ember build",
        "start": "ember server",
        "test": "ember test"
      },
      "repository": "",
      "engines": {
        "node": ">= 0.10.0"
      },
      "author": "",
      "license": "MIT",
      "devDependencies": {
        "active-model-adapter": "2.0.3",
        "broccoli-asset-rev": "^2.2.0",
        "ember-cli": "1.13.13",
        "ember-cli-app-version": "^1.0.0",
        "ember-cli-babel": "^5.1.5",
        "ember-cli-coffeescript": "1.13.2",
        "ember-cli-content-security-policy": "0.4.0",
        "ember-cli-dependency-checker": "^1.1.0",
        "ember-cli-emblem": "0.3.1",
        "ember-cli-htmlbars": "^1.0.1",
        "ember-cli-htmlbars-inline-precompile": "^0.3.1",
        "ember-cli-ic-ajax": "0.2.4",
        "ember-cli-inject-live-reload": "^1.3.1",
        "ember-cli-qunit": "^1.0.4",
        "ember-cli-rails-addon": "0.0.13",
        "ember-cli-release": "0.2.8",
        "ember-cli-sri": "^1.2.0",
        "ember-cli-uglify": "^1.2.0",
        "ember-data": "1.13.15",
        "ember-disable-proxy-controllers": "^1.0.1",
        "ember-export-application-global": "^1.0.4",
        "ember-radio-button": "1.0.7",
        "emberx-select": "2.0.2",
        "phantomjs": "^2.1.3"
      }
    }

Can you please check with this. Solution for this will help me a lot.




Aucun commentaire:

Enregistrer un commentaire