iOS Google跟踪代码管理器在启动时因’NSParseErrorException’
发布时间:2020-12-14 19:08:49 所属栏目:百科 来源:网络整理
导读:我们在其他3个iOS应用中运行带有Google跟踪代码管理器的谷歌分析,但出于某种原因,这个最新的应用程序在尝试打开容器时崩溃. 这是有问题的代码行(类似于GTM’s guidelines): NSTimeInterval timeout = 0.1; [TAGContainerOpener openContainerWithId:contain
我们在其他3个iOS应用中运行带有Google跟踪代码管理器的谷歌分析,但出于某种原因,这个最新的应用程序在尝试打开容器时崩溃.
这是有问题的代码行(类似于GTM’s guidelines): NSTimeInterval timeout = 0.1; [TAGContainerOpener openContainerWithId:containerName tagManager:_tagManager openType:kTAGOpenTypePreferNonDefault timeout:&timeout notifier:self]; 抛出的错误: Terminating app due to uncaught exception 'NSParseErrorException',reason: 'Last tag: 116 should be 124' 堆栈跟踪: *** First throw call stack: ( 0 CoreFoundation 0x0000000104dffa75 __exceptionPreprocess + 165 1 libobjc.A.dylib 0x0000000104716bb7 objc_exception_throw + 45 2 CoreFoundation 0x0000000104dff9ad +[NSException raise:format:] + 205 3 MyApp 0x0000000102831ce6 -[TAGPBCodedInputStream readUnknownGroup:builder:] + 152 4 MyApp 0x0000000102844904 -[TAGPBUnknownFieldSet mergeFieldFrom:input:] + 283 5 MyApp 0x000000010283ceb1 -[TAGPBGeneratedMessage parseUnknownField:extensionRegistry:tag:] + 203 6 MyApp 0x000000010283cfc8 -[TAGPBGeneratedMessage mergeFromCodedInputStream:extensionRegistry:] + 264 7 MyApp 0x000000010283cb35 -[TAGPBGeneratedMessage mergeFromData:extensionRegistry:] + 88 8 MyApp 0x000000010283cc1e +[TAGPBGeneratedMessage parseFromData:extensionRegistry:] + 82 9 MyApp 0x0000000102852da7 -[TAGResourceStorageImpl loadResourceFromContainerFile:] + 352 10 MyApp 0x000000010284d245 -[TAGContainer createInitialContainer] + 89 11 MyApp 0x000000010284afd3 -[TAGContainer initWithId:tagManager:resourceStorage:] + 399 12 MyApp 0x000000010284b098 -[TAGContainer initWithId:tagManager:] + 112 13 MyApp 0x000000010284ffe5 -[TAGManager containerById:] + 64 14 MyApp 0x000000010284f618 -[TAGManager openContainerById:callback:] + 258 15 MyApp 0x000000010284e9d3 -[TAGContainerOpener openWithRefreshType:] + 850 16 MyApp 0x000000010284e5c5 +[TAGContainerOpener openContainerWithId:tagManager:openType:timeout:notifier:] + 155 17 MyApp 0x0000000102812588 -[AnalyticsManager initWithTrackingId:containerName:] + 776 18 MyApp 0x00000001027b5afe -[TIXAppDelegate setupAnalytics] + 94 到目前为止,我似乎无法在网上找到任何信息.到目前为止,我唯一看到的是在GA’s Release notes中提到他们已经弃用了openContainerWithId,但他们现在的指南却没有说明这个或者使用什么. 这是容器文件内容: { "exportFormatVersion": 1.3,"exportTime": "2015-06-23 16:11:59","containerVersion": { "accountId": "197720","containerId": "1300316","containerVersionId": "0","deleted": false,"container": { "accountId": "197720","name": "App","publicId": "GTM-MYCONTAINER","timeZoneCountryId": "US","timeZoneId": "America/Los_Angeles","notes": "","usageContext": [ "IOS" ],"fingerprint": "1434997566330","enabledBuiltInVariable": [ "EVENT","APP_ID","APP_NAME","APP_VERSION_CODE","APP_VERSION_NAME" ] },"fingerprint": "0","variable": [ { "accountId": "197720","variableId": "1","name": "UA Number","type": "c","parameter": [ { "type": "TEMPLATE","key": "value","value": "UA-TrackingNumber" } ],"fingerprint": "0" },{ "accountId": "197720","variableId": "3","name": "screen-from","type": "v","key": "name","value": "screen-from" } ],"variableId": "2","name": "screen-name","value": "screen-name" } ],"variableId": "4","name": "view-name","value": "view-name" } ],"fingerprint": "0" } ] } } 任何帮助赞赏. 解决方法
事实证明,如果在Google代码管理器的服务器端没有创建实际标记,则会发生此问题.
我们的分析人员最终做了以下事情: 然后崩溃消失了,一切正常. (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |