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

Ensure we are properly testing multiple Ember versions. #5123

Merged
merged 7 commits into from
Aug 16, 2017

Conversation

rwjblue
Copy link
Member

@rwjblue rwjblue commented Aug 13, 2017

Prior to this commit (since c2ca068) we were only testing [email protected]. Even though we had a config/ember-try.js with many scenarios, none of them properly removed the ember-source version (even though ba7f462 was specifically trying to do this 😭).

The fundamental issue here is:

  • ember-try supports removing packages, but requires that you specify them
    in the dependencies or devDependencies objects. Since my changes in
    ba7f462 added "ember-source": null to the root of the npm config
    it was completely ignored 😞.
  • ember-source emits a warning to the console when it is present and
    the bower package for ember is in use. Unfortunately, this warning is
    a bit misleading (it doesn't tell you that the ember-source from npm
    will always win). The ember-source addon should be updated to throw an
    error when this misconfiguration is detected.
  • ember-cli will always use ember-source if it is present, and
    completely ignore whatever is in bower.json. IMHO, this default was not
    correct and ember-cli should have done the same thing that ember-data
    did during its migration from bower to npm: if both packages are present
    default to bower.json version with a warning.

There are almost certainly failing tests in the various scenarios. I pushed this in a branch so that others can help track down and fix the various issues.

Prior to this commit (since c2ca068) we were only testing [email protected].
Even though we had a `config/ember-try.js` with many scenarios, none of them
properly removed the `ember-source` version (even though ba7f462 was
specifically trying to do this 😭).

The fundamental issue here is:

* `ember-try` supports removing packages, but requires that you specify them
  in the `dependencies` or `devDependencies` objects.  Since my changes in
  ba7f462 added `"ember-source": null` to the root of the `npm` config
  it was completely ignored 😞.
* `ember-source` emits a warning to the console when it is present **and**
  the bower package for `ember` is in use.  Unfortunately, this warning is
  a bit misleading (it doesn't tell you that the `ember-source` from `npm`
  will always win). The `ember-source` addon should be updated to throw an
  error when this misconfiguration is detected.
* `ember-cli` will **always** use `ember-source` if it is present, and
  completely ignore whatever is in `bower.json`. IMHO, this default was not
  correct and `ember-cli` should have done the same thing that `ember-data`
  did during its migration from bower to `npm`: if both packages are present
  default to `bower.json` version with a warning.
@rwjblue
Copy link
Member Author

rwjblue commented Aug 13, 2017

I'm very sorry I didn't properly handle this back in ba7f462 😭.

@rwjblue
Copy link
Member Author

rwjblue commented Aug 13, 2017

Migrated from a warning to an error in emberjs/ember.js#15582.

@rwjblue
Copy link
Member Author

rwjblue commented Aug 14, 2017

Looks like nearly all of the failures on ember-release, ember-beta, ember-canary, and ember-alpha channels are related to the Ember.MODEL_FACTORY_INJECTIONS deprecation. #5127 should fix those.

@stefanpenner stefanpenner self-assigned this Aug 15, 2017
@stefanpenner
Copy link
Member

stefanpenner commented Aug 15, 2017

I'm working on this for rob starting now.

Avoid MODEL_FACTORY_INJECTION deprecations in tests on Ember >= 2.14.
@stefanpenner
Copy link
Member

stefanpenner commented Aug 16, 2017

fixed some more stuff, still some issues for: 1.13.x and 2.4.x

@rwjblue
Copy link
Member Author

rwjblue commented Aug 16, 2017

Looking good @stefanpenner, looks like all but Ember 2.4 and 1.13 are passing now.

@stefanpenner stefanpenner merged commit d67ca67 into master Aug 16, 2017
@stefanpenner stefanpenner deleted the fix-ember-try-config branch August 16, 2017 17:48
@rwjblue rwjblue mentioned this pull request Aug 16, 2017
3 tasks
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

Successfully merging this pull request may close these issues.

2 participants