【发布时间】:2019-02-03 19:01:51
【问题描述】:
我最近通过 cocoapods 将 Firebase In-App Messaging 添加到我的项目中。遵循文档中的设置过程后,我收到以下错误。如果有帮助,我最近也安装了 Admob,但直到我安装了应用内消息传递后才出现此错误。让我感到困惑的是:几乎没有任何代码可以设置它,那么我在哪里会得到一个 nil URL 错误?
起初,我不确定是 Firebase I.A.M.导致问题,但删除并重新安装后,问题消失然后再次出现。所以,我将描述我是如何安装 Firebase IAM 的。我使用此链接作为参考:
https://firebase.google.com/docs/in-app-messaging/get-started?authuser=0
将它添加到我的 Podfile 中,使用 cocoapods 1.4.0
在我的方案中添加了“-FIRDebugEnabled”
获取我的实例 ID,并将其添加到控制台中的活动中
仔细检查了我的方案
错误:
Terminating app due to uncaught exception
'NSInvalidArgumentException', reason: ' -[NSBundle initWithURL:]: nil URL argument'
First throw call stack:
(0x234b8cec4 0x233d5da40 0x234a93594 0x23554f6a8 0x23554f62c
0x10027a1b8 0x10248cdc8 0x10248ee28 0x10027a0f8 0x10027a2c0
0x10027b518 0x100267038 0x100260888 0x100266e44 0x100267328
0x100264bd0 0x10248b824 0x10248cdc8 0x10248fc90 0x10249e1dc
0x10249ebc8 0x2347a917c 0x2347abcec)
libc++abi.dylib: terminating with uncaught exception of type NSException
在控制台中,我的实例 ID 出现,然后是更多信息,然后是错误,所以我不知道是什么原因导致它发生。这是我控制台中的一些输出:
[Firebase/InAppMessaging][I-IAM700004] 1 messages were fetched successfully.
[Firebase/InAppMessaging][I-IAM270005] No impression records update due to no change after applying the server message list
[Firebase/InAppMessaging][I-IAM160010] There are analytics event trigger based messages, enable listening
[Firebase/InAppMessaging][I-IAM160001] There are 0 test messages and 1 regular messages and 3 Firebase analytics events to watch after resetting the message cache
[Firebase/InAppMessaging][I-IAM240002] Fetch is done. Start message rendering flow.
作为参考,当您搜索错误时,我查看了所有这些链接以及更多内容:
有什么想法吗?
【问题讨论】:
-
你找到解决办法了吗?
-
遗憾的是,我只是没有将它包含在我的应用程序中。如果您找到解决方案评论。我觉得我快弄明白了,所以如果你看一下链接,你可能会弄明白,但 idk 在任何地方都没有真正好的答案
-
您可以在这里提出/支持,希望他们帮助解决问题github.com/firebase/firebase-ios-sdk/issues/3090
标签: ios firebase cocoapods firebase-in-app-messaging