BugSense unable to log catched exception - ios

I have integrated BugSense library available at HERE in my iOS project.
When my application crashed because of uncauchgt exception I can see details in "Errors" bookmark. But when I try to log catched exception (via BUGSENSE_LOG macro), no error details are visible. I want to check my trial version before upgrade.
Could anyone explain me what's wrong? I would appreciate any help

Solved: My problem was because I've tried to log exception which wasn't directly throwed. Somewhere in my code I throw exception (let's suppose A) and in try-catch statement this exception was handled. In catch statement I've created another exception (let's suppose B) by call initWithName: reason: userInfo: and set exception A as caused to B. Log exception B failed, but when I logged A, it works!

Related

EXC_BAD_ACCESS issue debugging

I sometimes get EXC_BAD_ACCESS without knowing the source.I enabled Zombies and this is now what I get on the console:
2018-08-27 18:37:41.785523+0530 MyProject[3419:1228271] *** -[MyProject.VideoLibrary retain]: message sent to deallocated instance 0x103078200
VideoLibrary is the name of controller and I am not sending any retain messages. How do I go further to identify the issue and fix it? I am using Swift 4.0 if that matters.
When I want to have more information about a crash, I create an exception breakpoint.
You can add one from the breakpoint navigator by clicking on the "+".
When added, edit it and add po $arg1 for action. This will print information about the exception.

Terminating app due to uncaught exception 'NSInternalInconsistencyException' - HTTPS Error

I see the following error when getting data from Firebase for my iOS app:
*2018-01-06 14:55:09.327043-0500 Spirit-App[65852:5935746] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'URL must be in the form of http[s]://firebasestorage.googleapis.com/v0/b//o/[?token=signed_url_params]'*
I suspected this may have something to do with Info.plist so as a workaround I attempted to modify the App Transport Security Settings but the same message still appears. Is there another location, besides Info.plist, that would need changed? Or is there a specific location where I can edit the firebase URL referenced above to correct the issue? Thanks!
You are most likely using one of the internal reference functions of Firebase which converts a URL to a storage reference. For e.g. the code below
let httpsReference = storage.reference(forURL: "https://firebasestorage.googleapis.com/b/bucket/o/images%20stars.jpg")
In such an instance, the above exception is thrown if the URL is not in the correct format as explained in the error message. You will need to check that the URL has the valid prefix in the string before passing it to the reference function.
I am trying to answer your question without having a view of your source code where the error is occurring. So if you want more details, please post the source code and I will update my answer.

Sending NS user authentication data with Xcode 8.3.3 and Swift 3 from mobile app to server issue

I'm new to authentication development and am stumped.
When I touch (click on simulator) Sign Up button in the app to submit my user name and password Xcode log shows the following error,
20 Selfie 0x0000000100479707 main + 55
21 libdyld.dylib 0x000000010393d65d start + 1
)
libc++abi.dylib: terminating with uncaught exception of type NSException
Further more, this appears when I scroll up, and seems the first signs of an issue
2017-07-13 18:27:42.367 Selfie[75333:3951236] *** Terminating app due
to uncaught exception 'NSInvalidArgumentException', reason: '-
[Selfie.ViewController signupBtnTapped:]: unrecognized selector sent
to instance 0x7fc042c11250'
The desired result is for the app to send the built request to my remote server held by AWS. Here's the pre-dated tutorial I'm using:
https://www.raywenderlich.com/85528/user-accounts-ios-ruby-rails-swift
Here is the repo for the app, in the specific view controller it seems the problem is in, and where I'm left off in the tutorials instruction (at the sign up btn):
https://github.com/tristanbnewman/rwenderlich-auth-selfie/blob/master/Selfie/ViewController.swift
I apologize ahead of time for any etiquettes I've missed in this post, if there's anything you all need to help me solving (likely something I've missed providing you) just let me know.
First of all i would suggest you to make breakpoints on each line of the signupBtnTapped function and see what's happening.
The "unrecognized selector sent to instance" is probably related to how you connect your #IBAction with a button event. Have you connected touchUpInside event with your function in the storyboard?
The first exception is a generic exception which doesn't give much information. Making breakpoints should help you with this.

Terminating app due to uncaught exception 'FirebaseShutdown', reason: 'Firebase error

Terminating app due to uncaught exception 'FirebaseShutdown', reason: 'Firebase error. Please ensure that you spelled the name of your Firebase correctly' in ios.
Can any one help me solve this issue?
Using this demo for real time message:
https://github.com/firebase/ios-swift-chat-example
Is there any demo for real time chat in iOS?
The error you're getting is actually from calling [Firebase initWithUrl:] with a URL that isn't backed by a valid Firebase.
This exception is thrown so that you as a developer know that the Firebase you're connecting to is invalid.
If you put in the right Firebase URL, you shouldn't be getting this error.
Could you explain the situation in which you might need to connect to a Firebase that may not be valid?
Note:- You will need to check your base URL for the Firebase, Because you have try to access data from the wrong URL

Terminating app because of errors. How can i minimize these app closes

I have an app without try catch. App terminates when error occurred. I want to get error logs when error happen but don't terminate the app. Is this possible to handle this errors? I searched try, guard, defer but don't know how to use? Thanks.

Resources