Issue setting up dev environment

I have started using ubuntu 18.04 and while setting up my ember dev environment, i have come across this issue. In other OS(Windows) my ember project is working fine, but in this OS,an error is thrown BroccoliMergeTrees (TreeMerger (lint)): Expected Broccoli node, got [object Object] for inputNodes[1]. I am not able to understand why it is happening. Although this is not an OS specific issue but I don’t understand whats the issue here. Ember Version: 1.13.15 Node Version: 6.11.2

Can any one Help me here? The image for Error Stack Trace: https://i.stack.imgur.com/1pLYd.png

Can you send your package JSON please? Are you using ESLint plugin Prettier maybe? Try changing it to an earlier version if so.

I’m also facing the same issues, if I remove ember-cli-eslint it started to work. I have checked with ember-cli-eslint 4.2.3, 3.1.0, 2.0.1 nothing is working.

BroccoliMergeTrees (TreeMerger (addon-lint)): Expected Broccoli node, got [object Object] for inputNodes[1] TypeError: BroccoliMergeTrees (TreeMerger (addon-lint)): Expected Broccoli node, got [object Object] for inputNodes[1]

@Sammi-93 is this a work project? Ember 1.x is very old :-\

@abraham what version are you using?

Have either of you tried using nvm? (node version manager?) I find it essential for projects so I can specify what version od node,npm,etc I’m using.

Can you please post your package JSON?

Thanks for replying @Alonski, 

"devDependencies": {
    "body-parser": "1.12.4",
    "broccoli-asset-rev": "2.4.2",
    "connect-restreamer": "1.0.2",
    "ember-ajax": "2.4.1",
    "ember-cli": "2.5.0",
    "ember-cli-app-version": "1.0.0",
    "ember-cli-babel": "5.1.6",
    "ember-cli-code-coverage": "0.3.11",
    "ember-cli-content-security-policy": "0.4.0",
    "ember-cli-dependency-checker": "1.2.0",
    "ember-cli-document-title": "0.2.0",
    "ember-cli-eslint": "3.1.0",
    "ember-cli-htmlbars-inline-precompile": "0.3.1",
    "ember-cli-ic-ajax": "0.2.4",
    "ember-cli-inject-live-reload": "1.4.0",
    "ember-cli-qunit": "1.4.0",
    "ember-cli-release": "0.2.8",
    "ember-cli-simple-auth-cookie-store": "0.8.0",
    "ember-cli-sri": "2.1.0",
    "ember-cli-uglify": "1.2.0",
    "ember-data": "2.5.0",
    "ember-disable-proxy-controllers": "1.0.1",
    "ember-export-application-global": "1.0.5",
    "ember-load-initializers": "0.5.1",
    "ember-resolver": "2.0.3",
    "eslint": "^3.19.0",
    "eslint-plugin-ember": "5.2.0",
    "eslint-plugin-sonarjs": "0.1.0",
    "esprima-fb": "15001.1.0-dev-harmony-fb",
    "express": "4.12.3",
    "glob": "4.5.3",
    "liquid-fire": "0.23.0",
    "loader.js": "4.0.1",
    "morgan": "1.5.3"
  },
  "dependencies": {
    "ember-cli-htmlbars": "1.0.3",
    "ember-cli-sass": "5.3.1"
  }

@NullVoxPopuli thanks for replying,

ember-cli: 2.5.0 node: 4.9.1 os: linux x64

Using ember-cli-eslint 3.1.0

it was working last month. now suddenly not working in linux or ubuntu

what happens if you disable hinting in ember-cli-build.js?

like this: packages/frontend/ember-cli-build.js · master · NullVoxPopuli / emberclear · GitLab

new EmberApp(defaults, {
  hinting: false
  // ...
})
1 Like

Tried that not working

Can you try setting all of your “^x.x.x” versions to “x.x.x” without the ^? Maybe something updated and broke for you and it is hard to figure out exactly why. If this works we can start weeding them out one by one.

Rather than randomly trying to change versions to make the bug disappear, it would be good to debug the source of the issue. The stack trace shows where to begin. If you’ve never debugged inside Node, check out VSCode’s debugger, it’s good at that.

I’m guessing some addon unintentionally broke compatibility with ember-cli versions as old as yours.

To avoid this whole class of problem in the future, use a reliable dependency locking method, either yarn.lock or (on NPM 5+) package-lock.json. Both of those prevent you from updating accidentally, and I see them as absolutely critical in any project.

How to use yarn.lock efficiently. It is updated once we run yarn commands or do something else

Yes, you need to check it into your source control. Then the next time someone runs yarn install they will get the same exact results as you.