小编Suj*_*rya的帖子

错误域=NSCocoaErrorDomain 代码=4099

你们中的任何人都可以向我解释一下这个错误是什么,以及如何解决这个错误。我在应用程序商店中有一个快速应用程序,我正在尝试通过添加广告来货币化它。我尝试联系添加平台的支持团队,但他们没有回复。下面是我在控制台中看到的显示。我想知道这意味着什么。我确实在板上看到了一些评论,要在终端中运行命令,我还没有尝试过...在使用命令抑制日志之前想了解有关此错误的更多信息。提前致谢。

我正在尝试在我的应用程序中使用 INMOBI 来投放广告:

2020-01-19 23:18:26.769190-0500 testadv[4386:92650] [Client] Updating selectors failed with: Error Domain=NSCocoaErrorDomain Code=4099 "The connection to service on pid 0 named com.apple.commcenter.coretelephony.xpc was invalidated." UserInfo={NSDebugDescription=The connection to service on pid 0 named com.apple.commcenter.coretelephony.xpc was invalidated.} 2020-01-19 23:18:26.769421-0500 testadv[4386:92650] [Client] Updating selectors after delegate addition failed with: Error Domain=NSCocoaErrorDomain Code=4099 "The connection to service on pid 0 named com.apple.commcenter.coretelephony.xpc was invalidated." UserInfo={NSDebugDescription=The connection to service on pid 0 named com.apple.commcenter.coretelephony.xpc was invalidated.}

inmobi swift

6
推荐指数
1
解决办法
1万
查看次数

Swift IAPManager SKPaymentTransactionObserver 未调用

我正在尝试在我的应用程序中添加应用程序内购买。我能够加载产品,在设备中显示和测试它们。当我单击购买选项时,我确实收到了输入凭据并在沙盒环境中确认购买的提醒[下面的屏幕截图]。但我在控制台中没有看到 paymentQueue 方法的任何显示。谁能让我知道我在这里缺少什么。下面是代码中的几行:

谢谢。

import UIKit
import StoreKit

class testing: NSObject {

    private var productIds : Set<String> = []
    @objc private(set) var productsArray = [SKProduct]()

    func getProducts() {

        productIds = ["xxxxx", "yyyyy"]
        let request = SKProductsRequest(productIdentifiers: productIds)
        request.delegate = self
        request.start()
    }

    func purchase(product: String) {

        guard SKPaymentQueue.canMakePayments() else {
            return
        }

        guard SKPaymentQueue.default().transactions.last?.transactionState != .purchasing else {
            return
        }

        guard let productToPurchase = productsArray.filter({$0.productIdentifier == product}).first else {return}

        print(productToPurchase.localizedTitle)
        let payment = SKPayment(product: productToPurchase)
        SKPaymentQueue.default().add(payment)

    }

    func restorePurchases(){
        print("calling …
Run Code Online (Sandbox Code Playgroud)

storekit in-app-purchase swift

5
推荐指数
0
解决办法
1187
查看次数

标签 统计

swift ×2

in-app-purchase ×1

inmobi ×1

storekit ×1