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

Zone.js bug that blocked any async function calls like clearTimeout(undefined) => must return undefined, not an exception #440

Closed
Jacke opened this issue Mar 19, 2016 · 2 comments

Comments

@Jacke
Copy link

Jacke commented Mar 19, 2016

  • I'm submitting a ...
    [x] bug report
    [ ] feature request
    [ ] question about the decisions made in the repository
  • What is the current behavior?
>> clearTimeout()
>> TypeError: task is undefined
[default] Checking started in a separate process...
[default] /home/stan/Dev/cleanbuild/node_modules/angular2/src/common/directives/ng_plural.d.ts (2,10):
    Module '"/home/stan/Dev/cleanbuild/node_modules/angular2/src/common/directives/ng_switch"' has no exported member 'SwitchView'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (127,5):
    Duplicate identifier 'parent'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (131,5):
    Duplicate identifier 'name'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (219,5):
    Duplicate identifier 'current'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (223,5):
    Duplicate identifier 'currentTask'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (234,5):
    Duplicate identifier 'name'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (238,5):
    Duplicate identifier 'properties'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (251,5):
    Duplicate identifier 'onFork'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (261,5):
    Duplicate identifier 'onIntercept'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (273,5):
    Duplicate identifier 'onInvoke'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (282,5):
    Duplicate identifier 'onHandleError'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (291,5):
    Duplicate identifier 'onScheduleTask'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (292,5):
    Duplicate identifier 'onInvokeTask'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (301,5):
    Duplicate identifier 'onCancelTask'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (310,5):
    Duplicate identifier 'onHasTask'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (344,5):
    Duplicate identifier 'zone'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (354,14):
    Duplicate identifier 'HasTaskState'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (363,14):
    Duplicate identifier 'TaskType'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (370,5):
    Duplicate identifier 'isPeriodic'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (374,5):
    Duplicate identifier 'delay'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (397,5):
    Duplicate identifier 'type'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (401,5):
    Duplicate identifier 'source'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (406,5):
    Duplicate identifier 'invoke'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (411,5):
    Duplicate identifier 'callback'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (415,5):
    Duplicate identifier 'data'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (421,5):
    Duplicate identifier 'scheduleFn'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (428,5):
    Duplicate identifier 'cancelFn'.
[default] /home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts (433,5):
    Duplicate identifier 'zone'.
[default] /home/stan/Dev/cleanbuild/src/polyfills.ts (11,8):
    Exported external package typings file '/home/stan/Dev/cleanbuild/node_modules/zone.js/dist/zone.js.d.ts' is not a module. Please contact the package author to update the package definition.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (129,5):
    Duplicate identifier 'parent'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (133,5):
    Duplicate identifier 'name'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (221,5):
    Duplicate identifier 'current'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (225,5):
    Duplicate identifier 'currentTask'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (236,5):
    Duplicate identifier 'name'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (240,5):
    Duplicate identifier 'properties'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (253,5):
    Duplicate identifier 'onFork'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (263,5):
    Duplicate identifier 'onIntercept'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (275,5):
    Duplicate identifier 'onInvoke'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (284,5):
    Duplicate identifier 'onHandleError'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (293,5):
    Duplicate identifier 'onScheduleTask'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (294,5):
    Duplicate identifier 'onInvokeTask'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (303,5):
    Duplicate identifier 'onCancelTask'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (312,5):
    Duplicate identifier 'onHasTask'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (346,5):
    Duplicate identifier 'zone'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (356,14):
    Duplicate identifier 'HasTaskState'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (365,14):
    Duplicate identifier 'TaskType'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (372,5):
    Duplicate identifier 'isPeriodic'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (376,5):
    Duplicate identifier 'delay'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (399,5):
    Duplicate identifier 'type'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (403,5):
    Duplicate identifier 'source'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (408,5):
    Duplicate identifier 'invoke'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (413,5):
    Duplicate identifier 'callback'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (417,5):
    Duplicate identifier 'data'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (423,5):
    Duplicate identifier 'scheduleFn'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (430,5):
    Duplicate identifier 'cancelFn'.
[default] /home/stan/Dev/cleanbuild/typings/browser/ambient/zone.js/index.d.ts (435,5):
    Duplicate identifier 'zone'.
  • If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem via
    just clone this repo, npm install && npm start
    and type in console some async function like clearTimeout

  • Please tell us about your environment:

    "angular2": "2.0.0-beta.10",
    "core-js": "^2.1.5",
    "rxjs": "5.0.0-beta.2",
    "zone.js": "0.6.4"

It's possible to turn off Zone.js? I want to use https://github.com/jmdobry/CacheFactory
but looks like it's conflict with zone functions

EXCEPTION: Error during instantiation of AppComponent!. angular2.js:23730:9

ORIGINAL EXCEPTION: TypeError: task is undefined angular2.js:23730:9

ORIGINAL STACKTRACE: angular2.js:23730:9

patchTimer/clearNative</<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:142:10
clearInterval@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575 line 953 > Function:1:40
a/$[e].setRecycleFreq@http://localhost:8080/my-app/app/components/cachefactory.js:1:9453
a/$[e].setOptions@http://localhost:8080/my-app/app/components/cachefactory.js:1:8475
a@http://localhost:8080/my-app/app/components/cachefactory.js:1:11587
AppComponent@http://localhost:8080/my-app/app/components/app.component.js:22:25
ReflectionCapabilities</ReflectionCapabilities.prototype.factory/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:1519:20
Injector</Injector.prototype._instantiate@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11127:19
Injector</Injector.prototype._instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11069:16
Injector</Injector.prototype._new@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11059:14
InjectorInlineStrategy</InjectorInlineStrategy.prototype.instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:10823:14
ElementDirectiveInlineStrategy</ElementDirectiveInlineStrategy.prototype.init@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8923:18
AppElement@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8613:9
viewFactory_HostAppComponent0@viewFactory_HostAppComponent:71:31
AppViewManager_</AppViewManager_.prototype.createRootHostView@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:6701:18
DynamicComponentLoader_</DynamicComponentLoader_.prototype.loadAsRoot/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:12388:27
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:322:20
NgZoneImpl/this.inner<.onInvoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2216:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:321:20
Zone</Zone</Zone.prototype.run@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:218:25
scheduleResolveOrReject/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:567:53
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:355:24
NgZoneImpl/this.inner<.onInvokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2208:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:354:24
Zone</Zone</Zone.prototype.runTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:254:29
drainMicroTaskQueue@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:473:26
ZoneTask/this.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:425:22
 angular2.js:23730:9

ERROR CONTEXT: angular2.js:23730:9

Object { element: <sd-app>, componentElement: null, injector: Object } angular2.js:23730:9

EXCEPTION: Error: Uncaught (in promise): EXCEPTION: Error during instantiation of AppComponent!.
ORIGINAL EXCEPTION: TypeError: task is undefined
ORIGINAL STACKTRACE:
patchTimer/clearNative</<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:142:10
clearInterval@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575 line 953 > Function:1:40
a/$[e].setRecycleFreq@http://localhost:8080/my-app/app/components/cachefactory.js:1:9453
a/$[e].setOptions@http://localhost:8080/my-app/app/components/cachefactory.js:1:8475
a@http://localhost:8080/my-app/app/components/cachefactory.js:1:11587
AppComponent@http://localhost:8080/my-app/app/components/app.component.js:22:25
ReflectionCapabilities</ReflectionCapabilities.prototype.factory/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:1519:20
Injector</Injector.prototype._instantiate@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11127:19
Injector</Injector.prototype._instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11069:16
Injector</Injector.prototype._new@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11059:14
InjectorInlineStrategy</InjectorInlineStrategy.prototype.instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:10823:14
ElementDirectiveInlineStrategy</ElementDirectiveInlineStrategy.prototype.init@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8923:18
AppElement@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8613:9
viewFactory_HostAppComponent0@viewFactory_HostAppComponent:71:31
AppViewManager_</AppViewManager_.prototype.createRootHostView@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:6701:18
DynamicComponentLoader_</DynamicComponentLoader_.prototype.loadAsRoot/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:12388:27
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:322:20
NgZoneImpl/this.inner<.onInvoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2216:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:321:20
Zone</Zone</Zone.prototype.run@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:218:25
scheduleResolveOrReject/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:567:53
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:355:24
NgZoneImpl/this.inner<.onInvokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2208:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:354:24
Zone</Zone</Zone.prototype.runTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:254:29
drainMicroTaskQueue@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:473:26
ZoneTask/this.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:425:22

ERROR CONTEXT:
[object Object] angular2.js:23740
EXCEPTION: Error: Uncaught (in promise): EXCEPTION: Error during instantiation of AppComponent!.
ORIGINAL EXCEPTION: TypeError: task is undefined
ORIGINAL STACKTRACE:
patchTimer/clearNative</<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:142:10
clearInterval@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575 line 953 > Function:1:40
a/$[e].setRecycleFreq@http://localhost:8080/my-app/app/components/cachefactory.js:1:9453
a/$[e].setOptions@http://localhost:8080/my-app/app/components/cachefactory.js:1:8475
a@http://localhost:8080/my-app/app/components/cachefactory.js:1:11587
AppComponent@http://localhost:8080/my-app/app/components/app.component.js:22:25
ReflectionCapabilities</ReflectionCapabilities.prototype.factory/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:1519:20
Injector</Injector.prototype._instantiate@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11127:19
Injector</Injector.prototype._instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11069:16
Injector</Injector.prototype._new@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11059:14
InjectorInlineStrategy</InjectorInlineStrategy.prototype.instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:10823:14
ElementDirectiveInlineStrategy</ElementDirectiveInlineStrategy.prototype.init@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8923:18
AppElement@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8613:9
viewFactory_HostAppComponent0@viewFactory_HostAppComponent:71:31
AppViewManager_</AppViewManager_.prototype.createRootHostView@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:6701:18
DynamicComponentLoader_</DynamicComponentLoader_.prototype.loadAsRoot/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:12388:27
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:322:20
NgZoneImpl/this.inner<.onInvoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2216:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:321:20
Zone</Zone</Zone.prototype.run@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:218:25
scheduleResolveOrReject/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:567:53
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:355:24
NgZoneImpl/this.inner<.onInvokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2208:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:354:24
Zone</Zone</Zone.prototype.runTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:254:29
drainMicroTaskQueue@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:473:26
ZoneTask/this.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:425:22

ERROR CONTEXT:
[object Object] angular2.js:23730:9

STACKTRACE: angular2.js:23730:9

resolvePromise@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:534:32
scheduleResolveOrReject/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:570:18
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:355:24
NgZoneImpl/this.inner<.onInvokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2208:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:354:24
Zone</Zone</Zone.prototype.runTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:254:29
drainMicroTaskQueue@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:473:26
ZoneTask/this.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:425:22
 angular2.js:23730:9

Unhandled Promise rejection: EXCEPTION: Error during instantiation of AppComponent!.
ORIGINAL EXCEPTION: TypeError: task is undefined
ORIGINAL STACKTRACE:
patchTimer/clearNative</<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:142:10
clearInterval@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575 line 953 > Function:1:40
a/$[e].setRecycleFreq@http://localhost:8080/my-app/app/components/cachefactory.js:1:9453
a/$[e].setOptions@http://localhost:8080/my-app/app/components/cachefactory.js:1:8475
a@http://localhost:8080/my-app/app/components/cachefactory.js:1:11587
AppComponent@http://localhost:8080/my-app/app/components/app.component.js:22:25
ReflectionCapabilities</ReflectionCapabilities.prototype.factory/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:1519:20
Injector</Injector.prototype._instantiate@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11127:19
Injector</Injector.prototype._instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11069:16
Injector</Injector.prototype._new@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11059:14
InjectorInlineStrategy</InjectorInlineStrategy.prototype.instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:10823:14
ElementDirectiveInlineStrategy</ElementDirectiveInlineStrategy.prototype.init@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8923:18
AppElement@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8613:9
viewFactory_HostAppComponent0@viewFactory_HostAppComponent:71:31
AppViewManager_</AppViewManager_.prototype.createRootHostView@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:6701:18
DynamicComponentLoader_</DynamicComponentLoader_.prototype.loadAsRoot/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:12388:27
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:322:20
NgZoneImpl/this.inner<.onInvoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2216:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:321:20
Zone</Zone</Zone.prototype.run@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:218:25
scheduleResolveOrReject/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:567:53
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:355:24
NgZoneImpl/this.inner<.onInvokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2208:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:354:24
Zone</Zone</Zone.prototype.runTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:254:29
drainMicroTaskQueue@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:473:26
ZoneTask/this.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:425:22

ERROR CONTEXT:
[object Object] ; Zone: angular ; Task: Promise.then ; Value: Object { _wrapperMessage: "DI Exception", _originalException: TypeError, _originalStack: "patchTimer/clearNative</<@http://lo…", _context: null, _wrapperStack: "WrappedException@http://localhost:8…", keys: Array[1], injectors: Array[1], stack: "" } angular2-polyfills.js:460:14

Error: Uncaught (in promise): EXCEPTION: Error during instantiation of AppComponent!.
ORIGINAL EXCEPTION: TypeError: task is undefined
ORIGINAL STACKTRACE:
patchTimer/clearNative</<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:142:10
clearInterval@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575 line 953 > Function:1:40
a/$[e].setRecycleFreq@http://localhost:8080/my-app/app/components/cachefactory.js:1:9453
a/$[e].setOptions@http://localhost:8080/my-app/app/components/cachefactory.js:1:8475
a@http://localhost:8080/my-app/app/components/cachefactory.js:1:11587
AppComponent@http://localhost:8080/my-app/app/components/app.component.js:22:25
ReflectionCapabilities</ReflectionCapabilities.prototype.factory/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:1519:20
Injector</Injector.prototype._instantiate@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11127:19
Injector</Injector.prototype._instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11069:16
Injector</Injector.prototype._new@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11059:14
InjectorInlineStrategy</InjectorInlineStrategy.prototype.instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:10823:14
ElementDirectiveInlineStrategy</ElementDirectiveInlineStrategy.prototype.init@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8923:18
AppElement@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8613:9
viewFactory_HostAppComponent0@viewFactory_HostAppComponent:71:31
AppViewManager_</AppViewManager_.prototype.createRootHostView@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:6701:18
DynamicComponentLoader_</DynamicComponentLoader_.prototype.loadAsRoot/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:12388:27
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:322:20
NgZoneImpl/this.inner<.onInvoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2216:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:321:20
Zone</Zone</Zone.prototype.run@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:218:25
scheduleResolveOrReject/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:567:53
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:355:24
NgZoneImpl/this.inner<.onInvokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2208:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:354:24
Zone</Zone</Zone.prototype.runTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:254:29
drainMicroTaskQueue@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:473:26
ZoneTask/this.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:425:22

ERROR CONTEXT:
[object Object]
Stack trace:
resolvePromise@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:534:32
scheduleResolveOrReject/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:570:18
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:355:24
NgZoneImpl/this.inner<.onInvokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2208:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:354:24
Zone</Zone</Zone.prototype.runTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:254:29
drainMicroTaskQueue@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:473:26
ZoneTask/this.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:425:22
 angular2-polyfills.js:462:10

Unhandled Promise rejection: EXCEPTION: Error during instantiation of AppComponent!.
ORIGINAL EXCEPTION: TypeError: task is undefined
ORIGINAL STACKTRACE:
patchTimer/clearNative</<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:142:10
clearInterval@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575 line 953 > Function:1:40
a/$[e].setRecycleFreq@http://localhost:8080/my-app/app/components/cachefactory.js:1:9453
a/$[e].setOptions@http://localhost:8080/my-app/app/components/cachefactory.js:1:8475
a@http://localhost:8080/my-app/app/components/cachefactory.js:1:11587
AppComponent@http://localhost:8080/my-app/app/components/app.component.js:22:25
ReflectionCapabilities</ReflectionCapabilities.prototype.factory/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:1519:20
Injector</Injector.prototype._instantiate@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11127:19
Injector</Injector.prototype._instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11069:16
Injector</Injector.prototype._new@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11059:14
InjectorInlineStrategy</InjectorInlineStrategy.prototype.instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:10823:14
ElementDirectiveInlineStrategy</ElementDirectiveInlineStrategy.prototype.init@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8923:18
AppElement@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8613:9
viewFactory_HostAppComponent0@viewFactory_HostAppComponent:71:31
AppViewManager_</AppViewManager_.prototype.createRootHostView@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:6701:18
DynamicComponentLoader_</DynamicComponentLoader_.prototype.loadAsRoot/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:12388:27
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:322:20
NgZoneImpl/this.inner<.onInvoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2216:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:321:20
Zone</Zone</Zone.prototype.run@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:218:25
scheduleResolveOrReject/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:567:53
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:355:24
NgZoneImpl/this.inner<.onInvokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2208:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:354:24
Zone</Zone</Zone.prototype.runTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:254:29
drainMicroTaskQueue@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:473:26
ZoneTask/this.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:425:22

ERROR CONTEXT:
[object Object] ; Zone: <root> ; Task: Promise.then ; Value: Object { _wrapperMessage: "DI Exception", _originalException: TypeError, _originalStack: "patchTimer/clearNative</<@http://lo…", _context: null, _wrapperStack: "WrappedException@http://localhost:8…", keys: Array[1], injectors: Array[1], stack: "" } angular2-polyfills.js:460:14

Error: Uncaught (in promise): EXCEPTION: Error during instantiation of AppComponent!.
ORIGINAL EXCEPTION: TypeError: task is undefined
ORIGINAL STACKTRACE:
patchTimer/clearNative</<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:142:10
clearInterval@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575 line 953 > Function:1:40
a/$[e].setRecycleFreq@http://localhost:8080/my-app/app/components/cachefactory.js:1:9453
a/$[e].setOptions@http://localhost:8080/my-app/app/components/cachefactory.js:1:8475
a@http://localhost:8080/my-app/app/components/cachefactory.js:1:11587
AppComponent@http://localhost:8080/my-app/app/components/app.component.js:22:25
ReflectionCapabilities</ReflectionCapabilities.prototype.factory/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:1519:20
Injector</Injector.prototype._instantiate@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11127:19
Injector</Injector.prototype._instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11069:16
Injector</Injector.prototype._new@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:11059:14
InjectorInlineStrategy</InjectorInlineStrategy.prototype.instantiateProvider@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:10823:14
ElementDirectiveInlineStrategy</ElementDirectiveInlineStrategy.prototype.init@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8923:18
AppElement@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:8613:9
viewFactory_HostAppComponent0@viewFactory_HostAppComponent:71:31
AppViewManager_</AppViewManager_.prototype.createRootHostView@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:6701:18
DynamicComponentLoader_</DynamicComponentLoader_.prototype.loadAsRoot/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:12388:27
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:322:20
NgZoneImpl/this.inner<.onInvoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2216:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:321:20
Zone</Zone</Zone.prototype.run@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:218:25
scheduleResolveOrReject/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:567:53
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:355:24
NgZoneImpl/this.inner<.onInvokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2.js?1458383153576:2208:22
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:354:24
Zone</Zone</Zone.prototype.runTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:254:29
drainMicroTaskQueue@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:473:26
ZoneTask/this.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:425:22

ERROR CONTEXT:
[object Object]
Stack trace:
resolvePromise@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:534:32
resolvePromise@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:519:18
scheduleResolveOrReject/<@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:567:18
Zone</ZoneDelegate</ZoneDelegate.prototype.invokeTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:355:24
Zone</Zone</Zone.prototype.runTask@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:254:29
drainMicroTaskQueue@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:473:26
ZoneTask/this.invoke@http://localhost:8080/my-app/node_modules/angular2/bundles/angular2-polyfills.js?1458383153575:425:22
 angular2-polyfills.js:462:10
@Jacke
Copy link
Author

Jacke commented Mar 19, 2016

First error caused by duplicated def of zone
https://github.com/AngularClass/angular2-webpack-starter/blob/master/typings.json
here

@Jacke Jacke changed the title Zone.js bug that blocked any async function calls like clearTimeout Zone.js bug that blocked any async function calls like clearTimeout(undefined) => must return undefined, not an exception Mar 19, 2016
@PatrickJS
Copy link
Owner

fixed via workaround 1661e4c
related angular/angular#7652 (comment)

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

2 participants