Proxy call fails when used in threshold
Reported by
nassahaw...@gmail.com,
Feb 8 2017
|
|||||||
Issue descriptionUserAgent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:51.0) Gecko/20100101 Firefox/51.0 Steps to reproduce the problem: I am attaching a code snippet which reproduces the bug. The commented line works correctly (without Proxy) What is the expected behavior? IntersectionObserver should work correctly. What went wrong? An error message is displayed on the console : "The provided double value is non-finite." Did this work before? No Chrome version: Version 56.0.2924.87 (64-bit) Channel: n/a OS Version: 6.3 Flash Version: Shockwave Flash 24.0 r0
,
Feb 9 2017
Tested the issue on chrome Stable #56.0.2924.87, Canary 58.0.3006.0 in Windows 10.0 and was able to reproduce the issue. Observations: Issue behaving differently in older versions M30,M35 & M45 - Displaying "Reference error:Proxy is not defined" M50 - Insersion Observrver is not defined. M56- The provided double value is non-finite This is a Non-Regression issue since seeing this from M30 #30.0.1549.0, Making the status to Untriaged so that the issue would get addressed. Note : Able to reproduce the issue in MAC 10.12 and Linux Ubuntu 14.04. Thank you.
,
Feb 9 2017
Note on comment #2 - Proxy (JavaScript object) is implemented in M49 and IntersectionObserver in M54. Tests before M53 is not meaningful for this case. Can someone check if this is a Proxy issue?
,
Feb 13 2017
,
Feb 13 2017
This is a bindings (and maybe WebIDL) issue. The code asks V8 if the threshold IsArray() explicitly (which returns false for Proxies). I suspect this isn't quite how WebIDL specifies union types (in this case, a union of "double" and "sequence<double>".
,
Feb 13 2017
I believe any use of IsArray() in the bindings would be a bug; sequence<>s in Web IDL these days are specified by simply trying to iterate over the given value. So e.g. not only should an (iterable) proxy pass, but so should a Set.
,
Apr 13 2017
It looks to me like the fix in https://codereview.chromium.org/2810843002/ to handle sequence<> better might end up resolving this issue. Would you mind checking that, Raphael?
,
Apr 14 2017
domenic and jbroman are right: the problem's that our code currently only checks for IsArray() and the long-deprecated WebIDL array type (objects with a length property). The work in issue 690428 to make the bindings aware of objects with the @@iterator symbol should fix this (I tried my patch with the attachment in the bug description and didn't get any error messages in the console). |
|||||||
►
Sign in to add a comment |
|||||||
Comment 1 by ligim...@chromium.org
, Feb 8 2017