【发布时间】:2019-11-12 17:44:00
【问题描述】:
我有一个 WebRTC 项目的自动化测试。当我尝试使用具有允许使用权限的麦克风时,Chrome 驱动程序在 macOS 上崩溃。在 Linux 上一切正常,只有 macOS 存在问题。
val options = ChromeOptions()
val prefs = HashMap<String, Any>()
prefs["intl.accept_languages"] = "de"
prefs["profile.default_content_setting_values.media_stream_mic"] = 1
options.setExperimentalOption("prefs", prefs)
val driver = ChromeDriver(options)
chrome驱动的日志:
[1111/144648.290128:WARNING:process_memory_mac.cc(93)] mach_vm_read(0x7ffee3670000, 0x2000): (os/kern) invalid address (1)
[1111/144648.443304:WARNING:system_snapshot_mac.cc(42)] sysctlbyname kern.nx: No such file or directory (2)
[1111/144648.462626:WARNING:crash_report_exception_handler.cc(239)] UniversalExceptionRaise: (os/kern) failure (5)
[1573480008.479][SEVERE]: Unable to receive message from renderer
[1573480008.479][INFO]: Waiting for pending navigations...
[1573480008.479][INFO]: Done waiting for pending navigations. Status: disconnected: not connected to DevTools
[1573480008.479][DEBUG]: DevTools HTTP Request: http://localhost:63323/json
[1573480008.480][DEBUG]: DevTools HTTP Request failed
有人知道可能导致崩溃的原因吗?任何设置,如内存等?或者这只是 selenium 中的一个错误?
【问题讨论】:
标签: macos selenium selenium-chromedriver webrtc