gpt4 book ai didi

selenium-webdriver - Selenium 与 Chrome 与网络 worker 崩溃

转载 作者:行者123 更新时间:2023-12-02 04:23:41 40 4
gpt4 key购买 nike

我在用:

  • Chrome 73
  • Chrome ChromeDriver 73
  • 阿尔卑斯3.9
  • Selenium Java

  • 在 CI(在 kuberenetes 集群中)中,自从我将 WebWorker 添加到我的被测应用程序代码以来,我的 Web 驱动程序崩溃了。

    崩溃日志在这里 - https://gist.github.com/yosiat/360cb40af0cf7e234a0c6304c8c26ef1

    我启用了 chrome webdriver 详细日志记录,我看到了这些行:
    [33751:33751:0709/175416.767497:ERROR:validation_errors.cc(76)] Invalid message: VALIDATION_ERROR_DESERIALIZATION_FAILED (DevToolsAgentHost::ChildWorkerCreated deserializer)
    [33751:33761:0709/175416.767545:ERROR:render_process_host_impl.cc(4800)] Terminating render process for bad Mojo message: Received bad user message: Validation failed for DevToolsAgentHost::ChildWorkerCreated deserializer [VALIDATION_ERROR_DESERIALIZATION_FAILED (DevToolsAgentHost::ChildWorkerCreated deserializer)
    [33751:33761:0709/175416.767578:ERROR:bad_message.cc(27)] Terminating renderer for bad IPC message, reason 123
    [1562694856.784][DEBUG]: DevTools WebSocket Event: Inspector.targetCrashed EBB11FCDAB2DEC02066BF3BCD6FF4F8D {

    }
    [1562694856.784][INFO]: Done waiting for pending navigations. Status: unknown error: cannot determine loading status
    from tab crashed
    [1562694856.835][INFO]: [d62047bf581d2bfcc6f681474fb0ea28] RESPONSE Navigate ERROR unknown error: session deleted because of page crash
    from unknown error: cannot determine loading status
    from tab crashed
    (Session info: chrome=73.0.3683.103)

    最佳答案

    尝试使用参数 '--disable-dev-shm-usage' 启动 chrome。
    示例 JAVA:

      ChromeOptions options = new ChromeOptions();
    options.addArguments("--disable-dev-shm-usage");

    很可能是因为内存问题而崩溃。 Reference

    如果上述解决方案不起作用,那么您可以尝试 mounting an emptyDir to /dev/shm and setting the medium to Memory

    关于selenium-webdriver - Selenium 与 Chrome 与网络 worker 崩溃,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56959594/

    40 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com