# Deprecation: must have an \`isServiceFactory\` property set to true

**URL:** https://discuss.emberjs.com/t/deprecation-must-have-an-isservicefactory-property-set-to-true/8203
**Category:** Uncategorized
**Created:** [June 17, 2015, 6:09am UTC](https://discuss.emberjs.com/t/deprecation-must-have-an-isservicefactory-property-set-to-true/8203 "2015-06-17T06:09:14Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![jeremytm](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/jeremytm/32/10600_2.png) [@jeremytm](https://discuss.emberjs.com/u/jeremytm)
#### Post date: [June 17, 2015, 6:09am UTC](https://discuss.emberjs.com/t/deprecation-must-have-an-isservicefactory-property-set-to-true/8203/1 "2015-06-17T06:09:14Z")

</div>

Is anyone able to help me work out where this deprecation has come from? It appears in the Ember Inspector Deprecations section.

Even if I click on the last line of the callstack, best I can tell it comes from within Ember itself. So it’s an Ember bug and I just report it? I just need someone more experienced to confirm this is an ember bug.

```
Ember Inspector (Deprecation Trace): In Ember 2.0 service factories must have an `isServiceFactory` property set to true. You registered (unknown mixin) as a service factory. Either add the `isServiceFactory` property to this factory or extend from Ember.Service.

    at validateType (http://localhost:4200/assets/vendor.js:15823:13)
    at exports.default._emberRuntimeSystemObject.default.extend.resolve (http://localhost:4200/assets/vendor.js:15511:56)
    at Object.resolve [as resolver] (http://localhost:4200/assets/vendor.js:15263:23)
    at resolve (http://localhost:4200/assets/vendor.js:12753:29)
    at Object.Registry.resolve (http://localhost:4200/assets/vendor.js:12316:21)
    at factoryFor (http://localhost:4200/assets/vendor.js:11909:28)
    at instantiate (http://localhost:4200/assets/vendor.js:11967:19)
    at lookup (http://localhost:4200/assets/vendor.js:11865:17)
    at Object.Container.lookup (http://localhost:4200/assets/vendor.js:11797:14)

```

The last line there links to this code which appears to be part of ember:

```
lookup: function (fullName, options) {
  _emberMetalCore.default.assert('fullName must be a proper full name', this._registry.validateFullName(fullName));
  return lookup(this, this._registry.normalize(fullName), options);
},

```

---

<div class="post-metadata">

### Author: ![jeremytm](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/jeremytm/32/10600_2.png) [@jeremytm](https://discuss.emberjs.com/u/jeremytm)
#### Post date: [June 18, 2015, 12:07am UTC](https://discuss.emberjs.com/t/deprecation-must-have-an-isservicefactory-property-set-to-true/8203/2 "2015-06-18T00:07:29Z")

</div>

Nevermind. I found that this stack trace was being limited to 10 lines.

Adding this to the top of `app/app.js` fixed it.

`Error.stackTraceLimit=100;`

I can now see all lines of the trace, and after some digging found that the deprecation was being caused by Ember Validation.

I hope this helps someone else.

---

<div class="post-metadata">

### Author: ![eccegordo](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/eccegordo/32/14927_2.png) [@eccegordo](https://discuss.emberjs.com/u/eccegordo)
#### Post date: [June 18, 2015, 7:53am UTC](https://discuss.emberjs.com/t/deprecation-must-have-an-isservicefactory-property-set-to-true/8203/3 "2015-06-18T07:53:45Z")

</div>

@jeremytm can you post a small example snippet of actual code that triggered this issue? And what you changed to resolve it?

I have the same error and looking to refactor. But need to better understand it.

---

<div class="post-metadata">

### Author: ![jeremytm](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/jeremytm/32/10600_2.png) [@jeremytm](https://discuss.emberjs.com/u/jeremytm)
#### Post date: [June 18, 2015, 9:35am UTC](https://discuss.emberjs.com/t/deprecation-must-have-an-isservicefactory-property-set-to-true/8203/4 "2015-06-18T09:35:58Z")

</div>

This is the change that the ember-validations team made which fixes the issue: [https://github.com/dockyard/ember-validations/commit/c117388c2d80ff8cf0b639884229ed0753c1f9a7](https://github.com/dockyard/ember-validations/commit/c117388c2d80ff8cf0b639884229ed0753c1f9a7)

It’s not available in any releases yet, but I just changed their code locally to reflect this change to get rid of the deprecation until they release it.

---

<div class="post-metadata">

### Author: ![walter](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.emberjs.com/walter/32/14648_2.png) [@walter](https://discuss.emberjs.com/u/walter)
#### Post date: [July 23, 2015, 2:32am UTC](https://discuss.emberjs.com/t/deprecation-must-have-an-isservicefactory-property-set-to-true/8203/5 "2015-07-23T02:32:49Z")

</div>

Thanks for the example. That really helped me understand what was going on. The deprecation warning is could use an `"E.g. Ember.Object.extend... should be Ember.Service.extend"` or something like that.
