Skip to content

Non-ASCII character in app name causes crash in +[NSBundle bundleWithIdentifier:] #3951

Closed
@burkaslarry

Description

I use firebase firestore to develop . In this morning , no crash

as night, it gives exception at [NSBundle bundleWithIdentifier:@“org.cocoapods.grpcpp”] as screenshot stated . I have no clue on my pod settings or code... Would you please tell me what to fix?

Below is my screen shot :

enter image description here

Below is my code :

    Auth.auth().signInAnonymously() { (result , error) in
        guard let authResult = result else {
            return
        }
        let user = authResult.user
        let isAnonymous = user.isAnonymous  // true
        if(isAnonymous){
            let uid = user.uid
            User.shared.userId = uid
            print("user id : \(User.shared.userId)")
           self.writeProgressInitial()

        }
        // Do any additional setup after loading the view.
    }




   func writeProgressInitial() {
        let db = Firestore.firestore()
        let userRef = db.collection("user").document(User.shared.userId)
        userRef.getDocument { (querySnapshot, err) in
        if let err = err {
            print("Error getting documents: \(err)")
        } else {
            if (querySnapshot?.get("progress") == nil) {
                   var  dataDict : Dictionary<String , Any> = [:]
                   dataDict["progress"]  = 0
                   userRef.setData(dataDict)
                }else{
                    let dict = querySnapshot?.data()
                    let sssresult = dict!.filter{ $0.key == "progress" }.first?.value as? Int ?? 0
                    User.shared.progress = sssresult
                }
            }
        }
    }

Personally, I have tested that even using Dispatch async to update the progress but it fails .

Below is my Installed dependencies :

Installing BoringSSL-GRPC (0.0.3)
Installing Cosmos (19.0.3)
Installing Firebase (6.9.0)
Installing FirebaseAnalytics (6.1.2)
Installing FirebaseAuth (6.2.3)
Installing FirebaseAuthInterop (1.0.0)
Installing FirebaseCore (6.3.0)
Installing FirebaseCoreDiagnostics (1.1.0)
Installing FirebaseCoreDiagnosticsInterop (1.0.0)
Installing FirebaseFirestore (1.5.1)
Installing FirebaseInstanceID (4.2.5)
Installing GTMSessionFetcher (1.2.2)
Installing GoogleAppMeasurement (6.1.2)
Installing GoogleDataTransport (2.0.0)
Installing GoogleDataTransportCCTSupport (1.1.0)
Installing GoogleUtilities (6.3.0)
Installing JGProgressHUD (2.0.4)
Installing Protobuf (3.9.2)
Installing QuickTableViewController (1.2.0)
Installing SDWebImage (5.2.0)
Installing SimpleRoundedButton (1.0)
Installing gRPC-C++ (0.0.9)
Installing gRPC-Core (1.21.0)
Installing leveldb-library (1.22)
Installing nanopb (0.3.901)

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions