-
Notifications
You must be signed in to change notification settings - Fork 90
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
Fastboot Safe #348
Fastboot Safe #348
Conversation
index.js
Outdated
@@ -49,7 +49,12 @@ module.exports = { | |||
// TODO: In order to make the addon work in EmberTwiddle, we cannot use // the `tests` prop til | |||
// https://github.com/joostdevries/twiddle-backend/pull/28 is merged. | |||
// return !!this.app.tests; | |||
return this.app.env !== 'production'; | |||
|
|||
if('EMBER_CLI_FASTBOOT' in process.env) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would fail when:
EMBER_CLI_FASTBOOT=false ember s
can we change this condition to check if the value is true, something like process.env.EMBER_CLI_FASTBOOT === 'true'
?
@demersus I don't have experience with fastboot but I'm curious about |
Thanks @demersus for the PR. As @ro0gr suggested, can you update the code to check that the value is process.env.EMBER_CLI_FASTBOOT === 'true'; @ro0gr doing a quick search in github, it seems that this VAR is what people uses to check this. About the failings in the CI, they don't seem related with this PR, it seems that ember-data breaks our test suite 😞 |
Yes, EMBER_CLI_FASTBOOT is present when this is building/running in fastboot. I'll update the check to check for the correct value. No idea what went wrong in the CI tests |
As for the |
@san650 I've re-ran failing builds. The issue seems to be fixed now. Is this good enough to be merged? |
Thanks @demersus for contributing! |
Hi, I can tell that In our application we have both stable I've tested
But, I've also tested |
@bobisjan thanks for the heads up. Still not clear to me if we need to change our implementation to avoid including the addon on a fastboot build. When you say master is working, are you referring to master with this PR merged? |
The error I've mentioned was fixed in I don't know which version of In FastBoot 1.0+ addon's code can not be actually excluded, but it can be wrapped with I don't think that it is required to change implementation (because it's working), but it would be useful to have some basic test to prevent from regression using https://github.com/tomdale/ember-cli-addon-tests. |
Our fastboot builds were failing for local development. This prevents the addon from enabling itself in the fastboot build. (Addon depends on jquery)