Source tab sometimes does not refresh when browser window is refreshed

10,872 views
Skip to first unread message

ortho...@gmail.com

unread,
Feb 19, 2014, 2:34:21 PM2/19/14
to google-chrome-...@googlegroups.com
I wonder if someone can explain an irritating mystery about the Chrome debugger.

My typical debugging workflow is:

1. Load a page in the browser.
2. Open Developer Tools.
3. Select the Sources tab; open the HTML file; open the JavaScript file.
4. Set a breakpoint in the JavaScript file.
5. Reload the browser page. Loading stops at the breakpoint.
6. Debug until I find a problem.
7. Fix the problem (in my usual code editor, not in Developer Tools) and save the file.
8. Return to step 5.

Normally reloading the HTML file reloads the JavaScript file. Sometimes, though, Developer Tools continues to show the old version of the file. Then only way I can make it refresh is to close Developer Tools and start over.

What makes it do that, and how can I make it stop without resorting to the nuclear option?

John J Barton

unread,
Feb 19, 2014, 2:42:18 PM2/19/14
to Google Chrome Developer Tools
Did you try Devtools > Options (gear top right) > General > Disable cache (while DevTools is open) ?


--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-chrome-developer-tools/3b0f30f7-d2d9-4445-845f-79804ea22014%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Ivo Dachev

unread,
May 12, 2015, 9:56:27 AM5/12/15
to google-chrome-...@googlegroups.com, ortho...@gmail.com
I am having the same problem, when using both FF and Chrome. Cache is disabled. What else could be?

Thanks,

Andrey Lushnikov

unread,
May 12, 2015, 10:32:42 AM5/12/15
to google-chrome-...@googlegroups.com, ortho...@gmail.com
Make sure you have "Disable cache" setting off

--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-develo...@googlegroups.com.

praci...@gmail.com

unread,
Oct 30, 2015, 11:35:39 AM10/30/15
to Google Chrome Developer Tools, ortho...@gmail.com, lush...@chromium.org
Hi,

I have the exact same problem.  This occurs even if I disable the cache manually (even though my application already applies no-cache policies).

Chrome Version: 46.0.2490.80 m

Here is the explanation of my problem (which is almost the same):
  1. Open Sources tab of the developer tool
  2. Add a breakpoint to a JavaScript file (foo.js)
  3. Execute action to hit the breakpoint
  4. Finish the execution
  5. Modify the JavaScript file code and save
  6. Refresh the web app (keeping the developer tool open)
  7. Verify source of the JavaScript file
    • The source didn't updated itself
    • I cannot add new breakpoints in the file
  8. Execute action to hit the breakpoint added in step #2
    • The breakpoint is hit and the source file has the lastest code, but if I check in the right-side panel under Breakpoints, I can see that instead of being on foo.js, the breakpoint is actually on VM000000 foo.js
Note
Although the foo.js file didn't update in the Sources tab, if I go in the Resources tab and find foo.js, I can see that the source has been updated.

Workaround
A workaround that I found (but that is quite annoying) is to close the developper tool before I refresh the page.  After the refresh, when I re-open the developer tool and go in the sources tab, the foo.js file contains the latest source code.

Thanks,
Patrick Racicot

On Tuesday, May 12, 2015 at 10:32:42 AM UTC-4, Andrey Lushnikov wrote:
Make sure you have "Disable cache" setting off

On Tue, May 12, 2015 at 4:56 PM Ivo Dachev <dach...@gmail.com> wrote:
I am having the same problem, when using both FF and Chrome. Cache is disabled. What else could be?

Thanks,

On Wednesday, February 19, 2014 at 11:34:21 AM UTC-8, ortho...@gmail.com wrote:
I wonder if someone can explain an irritating mystery about the Chrome debugger.

My typical debugging workflow is:

1. Load a page in the browser.
2. Open Developer Tools.
3. Select the Sources tab; open the HTML file; open the JavaScript file.
4. Set a breakpoint in the JavaScript file.
5. Reload the browser page. Loading stops at the breakpoint.
6. Debug until I find a problem.
7. Fix the problem (in my usual code editor, not in Developer Tools) and save the file.
8. Return to step 5.

Normally reloading the HTML file reloads the JavaScript file. Sometimes, though, Developer Tools continues to show the old version of the file. Then only way I can make it refresh is to close Developer Tools and start over.

What makes it do that, and how can I make it stop without resorting to the nuclear option?

--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.

Valentin Tayursky

unread,
May 22, 2017, 11:22:50 AM5/22/17
to Google Chrome Developer Tools, ortho...@gmail.com, lush...@chromium.org
Hi guys,
I have the same issue... 
It makes me really mad. I can see new version of the script in the Source/Network/Application tabs, but real application uses 'cached version' and I can not change it...

пятница, 30 октября 2015 г., 18:35:39 UTC+3 пользователь praci...@gmail.com написал:

Tim Chase

unread,
Aug 9, 2017, 12:26:47 PM8/9/17
to Google Chrome Developer Tools, ortho...@gmail.com, lush...@chromium.org
I found a workaround.  If you open the js file in the browser (http://whatever.com/yourfile.js) and refresh the page it will load the new JS into the cashe.  

Flavio Portela

unread,
Aug 17, 2017, 5:45:39 PM8/17/17
to Google Chrome Developer Tools, ortho...@gmail.com
Same issue here, I have the cache off and I also tried with a fresh installation of chrome with no success

José Pedro Silva

unread,
Aug 23, 2017, 7:39:43 AM8/23/17
to Google Chrome Developer Tools, ortho...@gmail.com
Hi!

I have the same issue, since chrome v60. Until then it was working just fine.

Best,

Diego Marafetti

unread,
Sep 6, 2017, 10:11:35 AM9/6/17
to Google Chrome Developer Tools, ortho...@gmail.com
I also have the same issue since v60 too. Using chrome for os x. Source tab is not being refreshed after a page reload. This is definitely a bug and not a cache configuration issue. If I close and open the dev tools the source tab is populated with the new change so the browser does loads the updated file. 

Diego Marafetti

unread,
Sep 6, 2017, 10:14:56 AM9/6/17
to Google Chrome Developer Tools, ortho...@gmail.com
its solved in lastest version Version 61.0.3163.79 (Official Build) (64-bit) OS X

mig...@zappysoftware.com

unread,
Oct 18, 2017, 1:18:06 PM10/18/17
to Google Chrome Developer Tools
V62 and for me the issue is still present!

mih...@gmail.com

unread,
Oct 20, 2017, 2:45:20 PM10/20/17
to Google Chrome Developer Tools
Version 62.0.3202.62 (Official Build) (64-bit) behaves the same for me. I'm pretty sure I did not notice this before, even though the report seems quite old (2014) and I'm using Chrome dev tool daily.

I can see in the network tab of the dev tool window, that the file is indeed re-transferred (I have the "disable cache" checkbox checked) and in preview of the file I can see my changed to the page.

In my case it's not a stand alone js file, it's a script embedded via <script> tag in the main page, so the workaround presented by Tim Chase above, does not apply. Closing dev tool window, refreshing the page and reopening dev tool (as suggested by praci...@gmail.com) does seem to work.

mig...@zappysoftware.com

unread,
Oct 25, 2017, 7:12:03 AM10/25/17
to Google Chrome Developer Tools
I also have this issue, please fix this ASAP, i lose tons of hours debugging because the window is not showing the real code, so breakpoints, are not true, and does not relate to the actual code im doing.
I have cache disabled and have to reload the window, and close the dev tools or some crazy combos, to make it work, this is not good.

PhistucK

unread,
Oct 25, 2017, 11:05:11 AM10/25/17
to Google Chrome Developer Tools
You can search crbug.com for an existing issue and star it. If you cannot find one, file a new issue using the "New issue" link on the same page.
Please, do not add a "+1" or "Me too" or "Confirmed" (or similar) comment. It just wastes the time of Chrome engineers and sends unnecessary e-mails to all of the people who starred the issue.

You can reply with a link to the found or created issue and might get triaged (and fixed) faster.

Thank you.



PhistucK

--
You received this message because you are subscribed to the Google Groups "Google Chrome Developer Tools" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-chrome-developer-tools+unsub...@googlegroups.com.

kingk...@gmail.com

unread,
Apr 26, 2019, 5:50:46 AM4/26/19
to Chrome DevTools
I have been facing this problem for a few years and am still facing it.

To overcome it, I have to close CDT, refresh the page, open CDT again.  Sometimes this works, sometimes it doesn't.

Will be nice to know what is wrong and the proper way to overcome it.



Reply all
Reply to author
Forward
0 new messages