[英]Chromiumn : Selenium : Check failed: InitDefaultFont(). Could not find the default font
Getting following error while creating Chromedriver in selenium using java.使用 java 在 selenium 中创建 Chromedriver 时出现以下错误。 It is not working for one specific user, if same program is executed with other user then it works.它不适用于某个特定用户,如果与其他用户一起执行相同的程序,则它可以工作。 Both the user have similar permissions and environment variable两个用户都具有相似的权限和环境变量
OS: RHEL 7.9操作系统:RHEL 7.9
[1658829780.419][DEBUG]: DevTools HTTP Request: http://localhost:7742/json/list
[0726/100300.421991:FATAL:platform_font_skia.cc(98)] Check failed: InitDefaultFont(). Could not find the default font
#0 0x55c23a026c99
#28 0x7f11d4ded119 g_main_context_dispatch
#29 0x7f11d4ded478 (/usr/lib64/libglib-2.0.so.0.5600.1+0x4c477)
#30 0x7f11d4ded52c g_main_context_iteration
#31 0x55c239faed42
#43 0x55c237480f05 ChromeMain
#44 0x7f11cfb7e555 __libc_start_main
#45 0x55c237480d2a _start
Task trace:
#0 0x55c239f8ce64
#3 0x7f11d551f630 (/usr/lib64/libpthread-2.17.so+0xf62f)
#4 0x7f11cfb92387 __GI_raise
#5 0x7f11cfb93a78 __GI_abort
#6 0x55c23a025815
#33 0x7f11d4ded119 g_main_context_dispatch
#34 0x7f11d4ded478 (/usr/lib64/libglib-2.0.so.0.5600.1+0x4c477)
#35 0x7f11d4ded52c g_main_context_iteration
#36 0x55c239faed42
#48 0x55c237480f05 ChromeMain
#49 0x7f11cfb7e555 __libc_start_main
#50 0x55c237480d2a _start
r8: 0000000000000000 r9: 0000000000000000 r10: 0000000000000008 r11: 0000000000000202
r12: 00002625bce2e298 r13: 00002625bce2e290 r14: 00002625bce2e280 r15: 00007fffd6b4c700
di: 000000000000beea si: 000000000000beea bp: 00007fffd6b4be80 bx: 00007fffd6b4c6e0
dx: 0000000000000006 ax: 0000000000000000 cx: ffffffffffffffff sp: 00007fffd6b4bd48
ip: 00007f11cfb92387 efl: 0000000000000202 cgf: 0000000000000033 erf: 0000000000000007
trp: 000000000000000e msk: 0000000000000000 cr2: 00007ffb58b86700
[end of stack trace]
Calling _exit(1). Core file will not be generated.
[1658829780.445][SEVERE]: CreatePlatformSocket() failed: Address family not supported by protocol (97)
[1658829780.445][DEBUG]: DevTools HTTP Request failed
[1658829780.447][INFO]: [ee5fe644206b3d46f737dc17ed442b7e] RESPONSE InitSession ERROR unknown error: Chrome failed to start: exited abnormally.
(chrome not reachable)
(The process started from chrome location /Driver/linux/assertion_web_driver/assertion_web_driver is no longer running, so ChromeDriver is assuming that Chrome has crashed.)
[1658829780.447][DEBUG]: Log type 'driver' lost 1 entries on destruction
[1658829780.447][DEBUG]: Log type 'browser' lost 0 entries on destruction
[0100/000000.431497:INFO:child_thread_impl.cc(838)] ChildThreadImpl::EnsureConnected()
[0726/100315.456870:INFO:child_thread_impl.cc(838)] ChildThreadImpl::EnsureConnected()
0100/000000.504161:INFO:child_thread_impl.cc(838)] ChildThreadImpl::EnsureConnected()
[0726/100308.528783:INFO:child_thread_impl.cc(838)] ChildThreadImpl::EnsureConnected()
Chromium version: 88.0.4324.27铬版本:88.0.4324.27
Seems to be a classical case of mismatch between chromedriver and the chromebrowser version.似乎是chromedriver和chromebrowser版本不匹配的经典案例。
Ensure that:确保这件事:
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.