ios 混合开发应用白屏问题

server/2024/12/22 22:00:44/

一、问题场景

项目业务中某个前端页面中使用了多个echart 组件来显示历史数据, 在反复切换到这个页面后,会出现白屏问题。

二、问题分析

0x116000ab0 - GPUProcessProxy::didClose:

0x116000ab0 - GPUProcessProxy::gpuProcessExited: reason=Crash

0x1150180c0 - [PID=3342] WebProcessProxy::gpuProcessExited: reason=Crash

Error acquiring assertion: <Error Domain=RBSServiceErrorDomain Code=1 "((target is not running or doesn't have entitlement com.apple.developer.web-browser-engine.rendering AND target is not running or doesn't have entitlement com.apple.developer.web-browser-engine.networking AND target is not running or doesn't have entitlement com.apple.developer.web-browser-engine.webcontent))" UserInfo={NSLocalizedFailureReason=((target is not running or doesn't have entitlement com.apple.developer.web-browser-engine.rendering AND target is not running or doesn't have entitlement com.apple.developer.web-browser-engine.networking AND target is not running or doesn't have entitlement com.apple.developer.web-browser-engine.webcontent))}>

0x1150243c0 - ProcessAssertion::acquireSync Failed to acquire RBS assertion 'GPUProcess Background Assertion' for process with PID=3343, error: (null)

Failed to terminate process: Error Domain=com.apple.extensionKit.errorDomain Code=18 "(null)" UserInfo={NSUnderlyingError=0x30128cb40 {Error Domain=RBSRequestErrorDomain Code=3 "No such process found" UserInfo={NSLocalizedFailureReason=No such process found}}}

Failed to terminate process: Error Domain=com.apple.extensionKit.errorDomain Code=18 "(null)" UserInfo={NSUnderlyingError=0x30128ec40 {Error Domain=RBSRequestErrorDomain Code=3 "No such process found" UserInfo={NSLocalizedFailureReason=No such process found}}}

在切换页面的过程中看到如上日志,感觉是跟图形渲染相关的进程已经出问题了,

在出现白屏的时候,是如下日志:

0x116000ab0 - GPUProcessProxy::didClose:

0x116000ab0 - GPUProcessProxy::gpuProcessExited: reason=Crash

0x1150180c0 - [PID=3342] WebProcessProxy::gpuProcessExited: reason=Crash

0x104d70408 - WebProcessPool::gpuProcessDidExit: GPU Process has crashed more than 2 times in the last 30 seconds, terminating all WebProcesses

0x104d70408 - WebProcessPool::terminateAllWebContentProcesses

Error acquiring assertion: <Error Domain=RBSAssertionErrorDomain Code=2 "Specified target process does not exist" UserInfo={NSLocalizedFailureReason=Specified target process does not exist}>

0x1150180c0 - [PID=0] WebProcessProxy::didClose: (web process 0 crash)

0x1150180c0 - [PID=0] WebProcessProxy::processDidTerminateOrFailedToLaunch: reason=Crash

0x1150243c0 - ProcessAssertion::acquireSync Failed to acquire RBS assertion 'GPUProcess Background Assertion' for process with PID=3361, error: (null)

Error acquiring assertion: <Error Domain=RBSAssertionErrorDomain Code=2 "Specified target process does not exist" UserInfo={NSLocalizedFailureReason=Specified target process does not exist}>

0x115024600 - ProcessAssertion::acquireSync Failed to acquire RBS assertion 'XPCConnectionTerminationWatchdog' for process with PID=0, error: (null)

0x104d6c018 - [pageProxyID=10, webPageID=11, PID=0] WebPageProxy::processDidTerminate: (pid 0), reason=Crash

0x104d6c018 - [pageProxyID=10, webPageID=11, PID=0] WebPageProxy::dispatchProcessDidTerminate: reason=Crash

webViewWebContentProcessDidTerminate

从日志中可以看出webview 已经调用 webViewWebContentProcessDidTerminate 这个方法,进程都终止了。

在网上搜索了各种白屏问题,例如:

深入理解WKWebView白屏_webviewwebcontentprocessdidterminate-CSDN博客

App WebView白屏检测及解决总结,包括Android 和 iOS_ios webview加载白屏-CSDN博客

感觉最终的处理方式也只有reload 了

//进程被终止时调用

- (void)webViewWebContentProcessDidTerminate:(WKWebView *)webView{

    [webView reload];

    NSLog(@"webViewWebContentProcessDidTerminate");

}

不知道是不是苹果Safari 和 Chrome 里面的机制有差别,在电脑上运行同样的H5页面切换,明显感觉到Safari 要慢一下,感觉卡一些。


http://www.ppmy.cn/server/152330.html

相关文章

XXE靶场

XXE-lab 靶场 靶场网址&#xff1a;http://172.16.0.87/ 第一步我们看到网站有登录框我们试着用 bp 去抓一下包 将抓到的包发到重放器中 然后我们构建palody <!DOCTYPE foo [ <!ENTITY xxe SYSTEM "php://filter/readconvert.base64-encode/resourceC:/flag/fla…

WordPress 去除?v= 动态后缀

Wordpress url后面带有?vxxx的参数符&#xff0c;这种现象出现在安装了Woocommerce插件的店铺类型站点上&#xff0c;参数的作用是帮助系统根据用户的geographic定位计算 tax and shipping fee。 如何删除&#xff1f; 后台进入WooCommerce Settings &#xff0c;将根据IP定…

联发科MTK8788_MT8788安卓核心板安兔兔跑分_安卓主板方案商

MT8788安卓核心板具有集成的蓝牙、fm、WLAN和gps模块&#xff0c;是一个高度集成的基带平台&#xff0c;包括调制解调器和应用处理子系统&#xff0c;启用LTE/LTE-A和C2K智能设备应用程序。该芯片集成了工作在2.0GHz的ARM Cortex-A73、最高可达2.0GHz的ARM Cortex-A53和功能强大…

面试题整理9----谈谈对k8s的理解1

谈谈对k8s的理解 1. Kubernetes 概念 1.1 Kubernetes是什么 Kubernetes 是一个可移植、可扩展的开源平台&#xff0c;用于管理容器化的工作负载和服务&#xff0c;方便进行声明式配置和自动化。Kubernetes 拥有一个庞大且快速增长的生态系统&#xff0c;其服务、支持和工具的…

JaxaFx学习(三)

目录&#xff1a; &#xff08;1&#xff09;JavaFx MVVM架构实现 &#xff08;2&#xff09;javaFX知识点 &#xff08;3&#xff09;JavaFx的MVC架构 &#xff08;4&#xff09;JavaFx事件处理机制 &#xff08;5&#xff09;多窗体编程 &#xff08;6&#xff09;数据…

RunCam WiFiLink连接手机图传测试

RunCam WiFiLink中文手册从这里下载 一、摄像头端 1.连接天线&#xff08;易忘&#xff09; 2.打开摄像头前面的盖子&#xff08;易忘&#xff09; 3.接上直流电源&#xff0c;红线为正&#xff0c;黑线为负 4.直流电源设置电压为14v&#xff0c;电流为3.15A&#xff0c; 通…

4、交换机IP接口功能

这一篇是讲端口的功能的&#xff0c;应该放在路由前面的&#xff0c;不过关联不大&#xff0c;就这个顺序也行 1、DHCP功能 作用&#xff1a;交换机端口的DHCP功能可以使网络中的设备&#xff08;计算机、打印机等等&#xff09;能够自动的获取IP地址或其它网络参数&#xff0…

如何使用 WebAssembly 扩展后端应用

1. WebAssembly 简介 随着互联网的发展&#xff0c;越来越多的应用借助 Javascript 转到了 Web 端&#xff0c;但人们也发现&#xff0c;随着移动互联网的兴起&#xff0c;需要把大量的应用迁移到手机端&#xff0c;随着手端的应用逻辑越来越复杂&#xff0c;Javascript 的解析…