Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to run ember init after upgrading to 2.6.0 #5973

Closed
stevenwu opened this issue Jun 10, 2016 · 22 comments
Closed

Unable to run ember init after upgrading to 2.6.0 #5973

stevenwu opened this issue Jun 10, 2016 · 22 comments

Comments

@stevenwu
Copy link

stevenwu commented Jun 10, 2016

Unable to run ember init when upgrading from 2.5.1 to 2.6.0.


Output from ember version --verbose (project directory):

The addon `ember-cli-htmlbars` requires an Ember CLI version of 0.1.2 or above, but you are running null.
Error: The addon `ember-cli-htmlbars` requires an Ember CLI version of 0.1.2 or above, but you are running null.
    at Function.deprecatedAssertAbove [as assertAbove] (/Users/steve/work/noovis-ui/node_modules/ember-cli-version-checker/index.js:143:18)
    at CoreObject.module.exports.init (/Users/steve/work/noovis-ui/node_modules/ember-cli-htmlbars/ember-addon-main.js:13:13)
    at CoreObject.superWrapper [as init] (/Users/steve/work/noovis-ui/node_modules/core-object/lib/assign-properties.js:32:18)
    at CoreObject.Class (/Users/steve/work/noovis-ui/node_modules/core-object/core-object.js:33:38)
    at /Users/steve/work/noovis-ui/node_modules/ember-cli/lib/models/addons-factory.js:48:21
    at visit (/Users/steve/work/noovis-ui/node_modules/ember-cli/lib/utilities/DAG.js:23:3)
    at DAG.topsort (/Users/steve/work/noovis-ui/node_modules/ember-cli/lib/utilities/DAG.js:82:7)
    at CoreObject.extend.initializeAddons (/Users/steve/work/noovis-ui/node_modules/ember-cli/lib/models/addons-factory.js:44:11)
    at CoreObject.extend.initializeAddons (/Users/steve/work/noovis-ui/node_modules/ember-cli/lib/models/addon.js:220:38)
    at setupRegistryForEachAddon (/Users/steve/work/noovis-ui/node_modules/ember-cli-preprocess-registry/preprocessors.js:18:10)

Output from ember version --verbose (home directory):

ember-cli: 2.6.0
http_parser: 2.7.0
node: 6.2.1
v8: 5.0.71.52
uv: 1.9.1
zlib: 1.2.8
ares: 1.10.1-DEV
icu: 57.1
modules: 48
openssl: 1.0.2h
os: darwin x64

Tried with node 6.1.0, had same issue.

@stefanpenner
Copy link
Contributor

stefanpenner commented Jun 10, 2016

@stevenwu what version of ember-cli-htmlbars do you have?

Be sure to review https://github.com/ember-cli/ember-cli/blob/master/CONTRIBUTING.md#reporting-a-bug to provide actionable issues.

@stefanpenner stefanpenner modified the milestones: v2.6.0, v2.6.1 Jun 10, 2016
@stefanpenner
Copy link
Contributor

i suspect you have a version of ember-cli-htmlbars pre 1.0.7, could you confirm?

@stefanpenner
Copy link
Contributor

I've been attempting different configurations but have been so far unable to replicate. We will need more information to proceed...

@stefanpenner stefanpenner removed this from the v2.6.1 milestone Jun 10, 2016
@nathanhammond
Copy link
Contributor

@stevenwu Can you paste in your package.json?

@stevenwu
Copy link
Author

I tried to copy package.json and bower.json into a new 2.6.0 project earlier, but couldn't reproduce the erorr. Now I'm trying with a new 2.5.0 project upgrading to 2.6.0.

@nathanhammond
Copy link
Contributor

@stevenwu My hope was that you could post it here for us to review your dependencies. Is that possible?

@stevenwu
Copy link
Author

@stefanpenner
Copy link
Contributor

@stevenwu thanks, looking now.

@stefanpenner
Copy link
Contributor

stefanpenner commented Jun 10, 2016

@nathanhammond / @stevenwu bumping ember-font-awesome to the latest fixed the issue. As it does the right thing.

Going to see if we can improve this somehow on our end, although I am unclear on that.

@stefanpenner
Copy link
Contributor

I can't think of a solution beyond upgrading to the fixed ember-font-awesome.

The way I found it was via: CORE_OBJECT_WARN_DEPRECATED=1 ember s

which results in:

Deprecation: Overriding init without calling this._super is deprecated. Please call this._super.apply(this, arguments) ember-data
    at Function.Addon.lookup (/Users/stefanpenner/tmp/ember-cli-issue-5973/node_modules/ember-cli/lib/models/addon.js:879:27)
Deprecation: Overriding init without calling this._super is deprecated. Please call this._super.apply(this, arguments) ember-cli-dependency-checker
    at Function.Addon.lookup (/Users/stefanpenner/tmp/ember-cli-issue-5973/node_modules/ember-cli/lib/models/addon.js:879:27)
Deprecation: Overriding init without calling this._super is deprecated. Please call this._super.apply(this, arguments) ember-cli-jshint
    at Function.Addon.lookup (/Users/stefanpenner/tmp/ember-cli-issue-5973/node_modules/ember-cli/lib/models/addon.js:879:27)
Deprecation: Overriding init without calling this._super is deprecated. Please call this._super.apply(this, arguments) Ember CLI QUnit
    at Function.Addon.lookup (/Users/stefanpenner/tmp/ember-cli-issue-5973/node_modules/ember-cli/lib/models/addon.js:879:27)
Deprecation: Overriding init without calling this._super is deprecated. Please call this._super() ember-font-awesome
    at Function.Addon.lookup (/Users/stefanpenner/tmp/ember-cli-issue-5973/node_modules/ember-cli/lib/models/addon.js:879:27)

@stefanpenner
Copy link
Contributor

stefanpenner commented Jun 10, 2016

@nathanhammond et. al. we could enable that warning by default?

PR to do that: ember-cli/core-object#33

@crodriguez1a
Copy link

crodriguez1a commented Jun 13, 2016

@nathanhammond @stefanpenner I also ran into this issue with one of my add-ons. Adding the missing this._super call in the init method did seem to have fixed the issue. However, I didn't see the deprecation warning until (out of curiosity) I temporarily switched ember-cli-htmlbars from a dependency over to a dev dependency.

Then I was able to see:
DEPRECATION: Addon:ember-themed-syntaxis missing addon.project, this may be the result of an addon forgetting to invokesuperin its init.

Not sure if this helps at all. Thanks.

@badazz91
Copy link

Had the same problem on my project.

Bumping ember-font-awesome to 2.1.1 did the trick.

@stefanpenner
Copy link
Contributor

@crodriguez1a likely doing that forced NPM to download the latest core-object module, which contained that deprecation? or..

@celicoo
Copy link

celicoo commented Jun 16, 2016

Same issue here.

DEPRECATION: Overriding init without calling this._super is deprecated. Please call `this._super.init && this._super.init.apply(this, arguments);` ember-cli-dependency-checker
    at Function.Addon.lookup (/Users/marceloalves/DEV/Garimpo/Application/Application/node_modules/ember-cli/lib/models/addon.js:896:27)
DEPRECATION: Overriding init without calling this._super is deprecated. Please call `this._super.init && this._super.init.apply(this, arguments);` ember-cli-jshint
    at Function.Addon.lookup (/Users/marceloalves/DEV/Garimpo/Application/Application/node_modules/ember-cli/lib/models/addon.js:896:27)
DEPRECATION: Overriding init without calling this._super is deprecated. Please call `this._super.init && this._super.init.apply(this, arguments);` Ember CLI QUnit
    at Function.Addon.lookup (/Users/marceloalves/DEV/Garimpo/Application/Application/node_modules/ember-cli/lib/models/addon.js:896:27)
DEPRECATION: Overriding init without calling this._super is deprecated. Please call `this._super.init && this._super.init.apply(this, arguments);` release
    at /Users/marceloalves/DEV/Garimpo/Application/Application/node_modules/ember-cli/lib/models/project.js:404:38

@stefanpenner
Copy link
Contributor

stefanpenner commented Jun 16, 2016

Deprecations are enabled by default, if you have issues please follow the deprecations instruction (either updating the addon in question, or fixing the addon in question).

This isn't an ember-cli issue, rather we are attempting to transition old add-ons in a helpful way.

@Serabe
Copy link
Contributor

Serabe commented Jun 17, 2016

@stefanpenner is there any change to reconsider this until [email protected] or [email protected]? Currently a fresh installation of [email protected] shows three deprecation warnings all of them coming from files in ember-cli/lib/models
2016-06-17 at 17 02

@stefanpenner
Copy link
Contributor

stefanpenner commented Jun 17, 2016

@Serabe unfortunately do to how those add-on are wired up, that is the best stack trace we can give. For some add-ons we are able to give a better stack trace and we do, but for lots that information is quite tricky to get.

@stefanpenner
Copy link
Contributor

stefanpenner commented Jun 17, 2016

the stack trace helps identify how the add-on was instantiated (either in ember-cli, or standalone), but the deprecation also clearly states which dependency needs fixed.

  • ember-cli-dependency-checker (pending release)
  • ember-cli-quint (already fixed)
  • release (I thought this was ember-cli-release, but doesn't appear to be the case?)

@Serabe
Copy link
Contributor

Serabe commented Jun 19, 2016

@stefanpenner: I see the point on this comment. IMHO, a clean installation of ember-cli should not be raising any kind of deprecation. If ember-cli chooses to include an addon by default, I think this issue tracker would need to address those addons not raising any deprecation.

As an example, currently only ember-cli-release keep raising such deprecation, but ember-cli creates a package.json that fixes the version to 0.2.8 (it does not even allow to install 0.2.9 if it existed), while the fix has been released as a beta for 1.0.0. That means that the user needs to manually change package.json to a beta version of an addon as far the user knows is needed to run Ember CLI.

I would suggest releasing the fix in ember-cli-release as 0.2.9, changing package.json's ember-cli-release version to ^0.2.9 and releasing a 2.6.2 version with that fix. This would fix the issue without waiting for 2.7.0 and ease triaging issues, addressing questions on Slack, etc.

Thank you!

@nathanhammond
Copy link
Contributor

@Serabe Your proposed solution isn't unreasonable. It's a time and energy thing. Please see my response on that thread.

@rwjblue
Copy link
Member

rwjblue commented Jun 19, 2016

In this case, we enabled the deprecations after 2.6 was already released out of "self defense" (there were a number of issues reported that the deprecation was intended to help with and addon authors had no clue they needed to take action).

I think in the future that we should try to land deprecations "on by default" during the beta period, so that addon authors at least have a chance to fix the underlying issues before final/stable releases.

I do not think there is much we can do at this point, other than what @Serabe suggested (RE: [email protected] and a [email protected]).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants