This repository was archived by the owner on Apr 12, 2024. It is now read-only.
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
Infinite $digest caused by deferred/promise #2622
Closed
Description
I have found an infinite $digest loop caused by using a deferred inside a deferred. The jsfiddle link below demonstrates the problem. I have purposefully broken the link to angular so you can load the fiddle without hanging the browser. Simple change the link to angular in the HTML pane, and remove the alert in the JS pane.
http://jsfiddle.net/tdterry/yfytc/1/
This is a barebones example of a legitimate use case I have where one deferred property depends on another deferred property. It's the combination of creating the deferred, resolving it, and acting on the promise that causes the hang. If you comment out either line 14 or 15 in the JS, it doesn't hang.
Also, this does NOT hang in 1.0.6.