New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 839449 link

Starred by 7 users

Issue metadata

Status: WontFix
Owner: ----
Closed: May 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 3
Type: Bug



Sign in to add a comment

Uncaught TypeError: Cannot convert undefined or null to object

Reported by bravo.m...@gmail.com, May 3 2018

Issue description

Chrome Version       : 66.0.3359.139
OS Version: 10.0
URLs (if applicable) :
Other browsers tested:
  Add OK or FAIL after other browsers where you have tested this issue:
     Safari:
    Firefox:
    IE/Edge: OK

What steps will reproduce the problem?
1. Open developer tools
2. set a breakpoint at var = function($("#id").val, 2)
3. step through the javascript

What is the expected result?
 I expect to step through the code with no errors

What happens instead of that?
 I receive an error of "Uncaught TypeError: Cannot convert undefined or null to object"

Please provide any additional information below. Attach a screenshot if
possible.
I have a function to strip out certain characters like dollar symbol, comma, and percent symbol and return the string.  When I try to load a variable with what is returned from the function, I get the above mentioned error.  This error is only returned when stepping through the javascript while debugging in develooper tools. The error is not returned if developer tools is not up or if I click on the resume script execution button.  There is no error encountered in IE developer tools.

UserAgentString: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.139 Safari/537.36



 
devToolsError.JPG
41.3 KB View Download
Cc: krajshree@chromium.org
Components: Platform>DevTools
Labels: Needs-Feedback Triaged-ET Needs-Triage-M66
bravo.mike@ - Thanks for filing the issue...!!

Could you please provide a sample test file/url to test the issue from TE-end.
This will help us in triaging the issue further.

Thanks...!!
No need to provide an example.
I have the same problem with all scripts in all my applications since the last few days. Just contacted two colleagues if they know what I'm doing wrong but they reported the same problem.
Reinstalled my Chrome (Version 66.0.3359.139 (Official Build) (64-bit)) but that didn't help.
When stopped on a breakpoint the propblem only occurs when doing a single step (F10).
- Copying the statement and executing it in the console it works fine.
- Stepping into a function (F11) works fine.
- Setting a breakpoint on the next statement and run (F8) will work.
Most times you will end-up with a "DevTools was disconnected from the page".
I'm having the same issue.  Many different lines of many different scripts.. they move around as I edit them. If I put a breakpoint past the crashpoint, it will play thru with no problem. If I try to step thru some line of code, it will give Aw, snap most of the time.. sometimes it gives Cannot convert undefined or null to object. In both cases, the code executes perfectly if I'm not stepping thru in the DevTools.  This has been happening for a few weeks, and it's making it very difficult for me to do my job! I realize how reliant I am on DevTools. Please fix!

Comment 4 by max.he...@gmail.com, May 10 2018

I have this problem too.  Thanks to a virtual machine that hadn't updated itself for a while, I can say this behaviour wasn't present in 3325.  As soon as said virtual machine updated itself to 3359, the problem appeared.
Also you have this bug listed as Windows. I'm using 2 different Macs with the same result. I was thinking of switching to Windows to see if the bug was there as well, but it looks like it is.

Comment 6 by woxxom@gmail.com, May 10 2018

If no one can submit a demo file or page, there's nothing the developers can do to fix the bug since there are thousands of changes between releases. It's also possible the bug was already fixed in Chrome Canary, which you can install separately, so please test that too.
I've checked Canary, it's there as well.
I'm working on code covered under an nda, so until the bug flares up in something else, I can't send an example.
I am in a similar situation to sloan. Unfortunately, I can't send the entire code. Hopefully someone else runs into this and can submit an example/URL.
Project Member

Comment 9 by sheriffbot@chromium.org, May 10 2018

Labels: -Needs-Feedback
Thank you for providing more feedback. Adding the requester to the cc list.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Here's the steps to reproduce this problem on a random popular website.  Crashes reliably on two different Chrome installs on two different machines for me.

1) Navigate to https://jqueryui.com/draggable/
2) In the Dev Tools Sources tab, find default.html -> code.jquery.com -> ui/1.12.1 => jquery.ui.js
3) In jquery.ui.js, place breakpoints on lines 9263 and 9264:

$.datepicker.uuid = new Date().getTime();
$.datepicker.version = "1.12.1";

4) Refresh the page.  Chrome reloads the page and hits the breakpoint.

5) Press F10 to Step Over.  Javascript execution crashes with the following apparently-misleading errors:

jquery-ui.js:9263 Uncaught TypeError: this is not a Date object.
    at getTime (<anonymous>)
    at jquery-ui.js:9263
    at jquery-ui.js:14
    at jquery-ui.js:16
(anonymous) @ jquery-ui.js:9263
(anonymous) @ jquery-ui.js:14
(anonymous) @ jquery-ui.js:16
default.html:16 Uncaught TypeError: $(...).draggable is not a function
    at HTMLDocument.<anonymous> (default.html:16)
    at fire (jquery-1.12.4.js:3232)
    at Object.fireWith [as resolveWith] (jquery-1.12.4.js:3362)
    at Function.ready (jquery-1.12.4.js:3582)
    at HTMLDocument.completed (jquery-1.12.4.js:3617)

6) Refresh the page.  When the breakpoint is hit, press F8 to resume execution.  The system breaks on the breakpoint on the following line; no error is generated by line 9263.

7) Now press F10 three times.  The system generates an Aw, Snap when you try to step over the following line of Internet Explorer detection code (!) :

var ie = $.ui.ie = !!/msie [\w.]+/.exec( navigator.userAgent.toLowerCase() );

8) Now, remove the breakpoints and refresh the page, with the Javascript console still open.  The system responds by successfully loading the page and running the Javascript without error.


Reproduced! Thank you! Hopefully now someone can address this.
Since max.he.. in comment 4 stated the problem was not present in 3325 I uninstalled Chromium (3359.139) and installed 3325 and that worked well.
Unfortunately I forgot to turn off automatic update and I got updated to 3359.
And now I got luckily. It was a new build: 3359.170 not having the problems this issue is about.

SO TO ALL OF YOU: UPDATE TO 3359.170 and this bug can be closed.
Can confirm, fixed for me in 3359.170.
Cc: sindhu.chelamcherla@chromium.org
Status: WontFix (was: Unconfirmed)
As per comment#12 and #13 closing this issue as issue is no longer reproducible after updating to 66.0.3359.170. Please raise a new issue if issue is still seen.

Thanks!
I also upgraded to version 3359.170 and no longer receive the error. Thanks to everyone for helping!
I can still reproduce the issue with chrome version 67.0.3396.87 (currently latest version).
The problem is back again. Now using 69.0.3497.100.

With the following piece of code:
+---------------------------------------------------------------------------+
|  switch ( typeof elemName)                                                |
|  {                                                                        |
|     case 'string' : // When we have an element with this name us it       |
|                     if ( objEnum[enumByName][elemName] !== undefined )    |
+---------------------------------------------------------------------------+

elemName has the value "Set", the switch statement is executed correctly but the script breaks on the if statement saying: "Uncaught ReferenceError: av_Value is not defined".
Breaking on the if and hovering over the elemName or dumping it in the command window will show "Set".

Sign in to add a comment