at-internet / piano-analytics-apple

Piano Analytics Apple SDK repository
https://developers.atinternet-solutions.com/piano-analytics/
MIT License
7 stars 13 forks source link

Endless Cycle with Exception Handler when Crash Detection is enabled #19

Closed itsJS closed 1 year ago

itsJS commented 1 year ago

SDK Version: 3.0.5

iOS Version: 16.0

Xcode Version: 15.0

Device: Real iPhone 13 & iPhone 15 Simulator

Description:

I have encountered an issue with the library where the exception handler appears to create an endless cycle when the iOS app encounters an exception. That means, when the app encounters an exception, the exception handler of Piano is called, which then encounters an exception, that exception causes the exception handler to be called again. This behaviour results in a call stack that becomes polluted with repeated exceptions, making it difficult to identify and diagnose the root cause of the problem that occurred initially.

Steps to Reproduce:

  1. set .enableCrashDetection(true)
  2. Force an exception in your project

Expected Behavior:

I expect the exception handler in the Piano library to gracefully handle exceptions and provide meaningful error information to assist with debugging.

Actual Behavior:

The current behavior involves an endless cycle where the app triggers an exception, the exception handler is called, and it, in turn, triggers another exception. This loop results in a polluted call stack and hinders effective debugging.

Screenshots/Logs:

Screenshot 2023-10-16 at 17 25 44

Thank you for your attention to this issue. Please let me know if you need any further information or clarification.

alexey-troshkov commented 1 year ago

@itsJS Please show your stacktrace

alexey-troshkov commented 1 year ago

Fixed in version 3.0.7