New issue
Advanced search Search tips

Issue 839135 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Sep 25
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 2
Type: Bug



Sign in to add a comment

javascript module doesn't assign values in step through debugger

Reported by hannah.l...@gmail.com, May 2 2018

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/66.0.3359.117 Safari/537.36

Steps to reproduce the problem:
1. I tried the attached javascript with devTools open, and with devTools closed (it gets an element, and then the data attribute from that element).
When using the step through debugger, the data attribute is not assigned to the variable. 
The same code works when used directly in the console.

2. Tried removing type="module" but then (another bug?) the dataset method breaks.
3. Tried in Chrome Canary - same error.

What is the expected behavior?
const greeting should be "Hello World", not ReferenceError when console is opened, and code is stepped through.

bizarrely, this is still printed to the console with the console.log statements, but I'm using this in a more complex piece of code, and it's causing problems when I debug.

What went wrong?
ReferenceError after assignment for otherwise working code.
Only happens when devTools is open / using step through debugger.

Did this work before? N/A 

Chrome version: 66.0.3359.117  Channel: n/a
OS Version: OS X 10.13.3
Flash Version: 

Apologies if this is an existing issue or me not doing something correctly. It really looks like a bug to me.
 
index.html
402 bytes View Download
index.js
208 bytes View Download
Screen Shot 2018-05-02 at 2.23.40 PM.png
100 KB View Download
Labels: Needs-Triage-M66

Comment 2 by alph@chromium.org, May 10 2018

Components: -Platform>DevTools Platform>DevTools>JavaScript
Owner: kozy@chromium.org
Status: Assigned (was: Unconfirmed)

Comment 3 by pric...@gmail.com, Jun 4 2018

Same thing happening is OSX 10.13.2 Chrome 67

Comment 4 by pric...@gmail.com, Jun 4 2018

Pardon the sloppy code, but here is a screenshot of it in action.
Screen Shot 2018-06-04 at 6.26.47 PM.png
289 KB View Download
Status: Fixed (was: Assigned)
It looks fixed in latest Google Chrome Canary, feel free to open another issue if it still a problem.

Sign in to add a comment