简体   繁体   English

Chrome开发工具暂停黑盒脚本中的异常

[英]Chrome dev tools pauses on exceptions in blackboxed script

I have a JavaScript file that I have blackboxed in the Chrome developer tools and I have the debugger set to pause on uncaught exceptions. 我有一个JavaScript文件,我在Chrome开发人员工具中使用了黑盒子,我将调试器设置为暂停未捕获的异常。 However, the dev tools continues to pause on uncaught exceptions in the blackboxed JS file (see screenshot below). 但是,开发工具继续在黑盒子JS文件中暂停未捕获的异常(见下面的截图)。 Is this a Chrome bug? 这是Chrome错误吗? Or is there an additional step required to make Chrome stop pausing on uncaught exceptions in blackboxed scripts? 或者是否还需要一个额外的步骤才能让Chrome停止在黑盒子脚本中暂停未捕获的异常?

在此输入图像描述

According to https://developer.chrome.com/devtools/docs/blackboxing : 根据https://developer.chrome.com/devtools/docs/blackboxing

What happens when you blackbox a script? blackbox脚本会发生什么?

Exceptions thrown from library code will not pause (if Pause on exceptions is enabled) 从库代码抛出的异常不会暂停(如果启用了异常暂停)

So this seems either like a bug, or I'm overlooking something obvious. 所以这看起来像是一个错误,或者我忽略了一些明显的东西。

This issue is sadly not resolved as of 70.0.3538.77. 从70.0.3538.77开始,这个问题很难解决。 Filed this Chromium issue . 提起这个Chromium问题 The fun part? 有趣的部分? Dev Tools itself says it shouldn't stop on exceptions from blackboxed scripts - while being stopped in a blackboxed script 😂 Dev Tools本身表示它不应该停止黑盒子脚本的异常 - 而是在黑盒子脚本中停止😂

Dev Tools清楚地描述它不应该是它实际上的位置

This issue is fixed for me on version 56.0.2924.87. 我在56.0.2924.87版本上修复了此问题。

If I blackbox a script on this version, the debugger does not stop anymore on a throw statement even when"pauses on caught exceptions" is checked. 如果我在这个版本上使用黑盒子,那么调试器就不会再停止在throw语句中,即使选中“暂停捕获的异常”也是如此。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM