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

[BUGFIX] Fix remaining ember-source issues. #6484

Merged
merged 2 commits into from
Nov 30, 2016

Conversation

nathanhammond
Copy link
Contributor

The removal from bower meant that we were erroneously removing it from ember-source. No longer.

@nathanhammond nathanhammond changed the title Shims are always present in the ember-source version. [BUGFIX] Shims are always present in the ember-source version. Nov 30, 2016
@nathanhammond nathanhammond changed the title [BUGFIX] Shims are always present in the ember-source version. [BUGFIX] Fix remaining ember-source issues. Nov 30, 2016
@@ -335,7 +335,7 @@ EmberApp.prototype._initVendorFiles = function() {
}

// don't crash if ember-cli-shims is not included
if (!bowerDeps['ember-cli-shims']) {
if (!ember && !bowerDeps['ember-cli-shims']) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change seems somewhat odd. The idea here was that a different addon could provide the shims. That would work even with using Ember from bower.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ember-source build provides shims every time.

@martndemus this was introduced in #6254. What is the story behind this check?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In other words, what's the story of this: #6254 (comment)

It's distinct from the ember-resolver issue but in that PR.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What @rwjblue said, to be able to provide my own shims addon.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm actually rather opposed to this check existing as it makes the failure for not including shims move to runtime where we can't control it as easily and manifests as:

cannot find module 'ember'

Regardless, knowing the story makes it possible for me to address. Thank you!

Copy link
Contributor Author

@nathanhammond nathanhammond Nov 30, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, so the only thing which requires this change is ember-new-modules-shim. The users of that addon should be assumed to be highly familiar Ember devs.

Given that, if users of ember-new-modules-shim wish to not include ember-cli-shims they will need to follow the full set of instructions at https://github.com/DockYard/ember-new-modules-shim#optional-disabling-ember-cli-shims ... not just remove the bower dependency and rely on this change.

That is the only way we can make sure that shims are not included across both ember-source-provided and bower-provided shims while knowing user intent.

@rwjblue
Copy link
Member

rwjblue commented Nov 30, 2016

👍 , seems good

@nathanhammond
Copy link
Contributor Author

Skipping @homu because CI is broken.

@nathanhammond nathanhammond merged commit 92f1303 into ember-cli:master Nov 30, 2016
@nathanhammond nathanhammond deleted the shims-present branch November 30, 2016 18:42
@homu homu mentioned this pull request Nov 30, 2016
@ghost
Copy link

ghost commented Nov 30, 2016

img_0364

@rwjblue rwjblue mentioned this pull request Dec 1, 2016
@Turbo87 Turbo87 added this to the v2.11.0 milestone Dec 4, 2016
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.

None yet

3 participants