@goliapkg/sentori-react-native 0.8.5 → 0.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/android/src/main/java/com/sentori/SentoriCrashHandler.kt +11 -1
- package/android/src/main/java/com/sentori/SentoriMobileVitals.kt +100 -0
- package/android/src/main/java/com/sentori/SentoriModule.kt +23 -0
- package/android/src/main/java/com/sentori/SentoriNativeExceptionBridge.kt +75 -0
- package/android/src/main/java/com/sentori/SentoriNativeSignals.kt +32 -0
- package/ios/SentoriMobileVitals.swift +104 -0
- package/ios/SentoriModule.swift +23 -0
- package/ios/SentoriNativeExceptionBridge.swift +90 -0
- package/lib/capture.d.ts.map +1 -1
- package/lib/capture.js +21 -0
- package/lib/capture.js.map +1 -1
- package/lib/index.d.ts +4 -0
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +4 -0
- package/lib/index.js.map +1 -1
- package/lib/init.d.ts.map +1 -1
- package/lib/init.js +21 -1
- package/lib/init.js.map +1 -1
- package/lib/mobile-vitals.d.ts +35 -0
- package/lib/mobile-vitals.d.ts.map +1 -0
- package/lib/mobile-vitals.js +89 -0
- package/lib/mobile-vitals.js.map +1 -0
- package/lib/native.d.ts +20 -0
- package/lib/native.d.ts.map +1 -1
- package/lib/native.js +48 -0
- package/lib/native.js.map +1 -1
- package/lib/navigation.d.ts.map +1 -1
- package/lib/navigation.js +14 -2
- package/lib/navigation.js.map +1 -1
- package/package.json +1 -1
- package/src/capture.ts +22 -0
- package/src/index.ts +12 -0
- package/src/init.ts +21 -1
- package/src/mobile-vitals.ts +114 -0
- package/src/native.ts +88 -0
- package/src/navigation.ts +16 -2
|
@@ -119,6 +119,16 @@ object SentoriCrashHandler {
|
|
|
119
119
|
|
|
120
120
|
val error = errorToJson(throwable)
|
|
121
121
|
|
|
122
|
+
// v0.9.5 #7 — detect crashes originating from native code (JNI
|
|
123
|
+
// / .so libs). Pure SIGSEGV in a stripped .so won't reach us
|
|
124
|
+
// without breakpad (queued for v1.1), but throws that surface
|
|
125
|
+
// as UnsatisfiedLinkError or have native frames in the stack
|
|
126
|
+
// are tagged so the dashboard can split them out.
|
|
127
|
+
val tags = JSONObject()
|
|
128
|
+
if (SentoriNativeOrigin.looksNative(throwable)) {
|
|
129
|
+
tags.put("native_signal", "true")
|
|
130
|
+
}
|
|
131
|
+
|
|
122
132
|
val event = JSONObject().apply {
|
|
123
133
|
put("id", uuidLower())
|
|
124
134
|
put("timestamp", iso8601Now())
|
|
@@ -129,7 +139,7 @@ object SentoriCrashHandler {
|
|
|
129
139
|
put("device", device)
|
|
130
140
|
put("app", app)
|
|
131
141
|
put("user", JSONObject.NULL)
|
|
132
|
-
put("tags",
|
|
142
|
+
put("tags", tags)
|
|
133
143
|
put("breadcrumbs", JSONArray())
|
|
134
144
|
put("error", error)
|
|
135
145
|
put("fingerprint", JSONArray())
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
package com.sentori
|
|
2
|
+
|
|
3
|
+
import android.os.Process
|
|
4
|
+
import android.os.SystemClock
|
|
5
|
+
import android.view.Choreographer
|
|
6
|
+
import java.util.concurrent.atomic.AtomicInteger
|
|
7
|
+
import java.util.concurrent.atomic.AtomicLong
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* v0.9.4 #1 — Mobile Vitals.
|
|
11
|
+
*
|
|
12
|
+
* Cold start uses `Process.getStartElapsedRealtime()` (API 24+) —
|
|
13
|
+
* the time the system started the process clock, anchored to boot
|
|
14
|
+
* time. Subtract from current `SystemClock.elapsedRealtime()` at JS
|
|
15
|
+
* bridge ready to get the user-perceived launch budget.
|
|
16
|
+
*
|
|
17
|
+
* Frame counters hook `Choreographer.postFrameCallback` and compare
|
|
18
|
+
* deltas. 16.67ms = slow, 700ms = frozen — same thresholds as iOS
|
|
19
|
+
* for parity. The choreographer callback runs on the UI thread so we
|
|
20
|
+
* don't need extra synchronization for the AtomicInteger counters.
|
|
21
|
+
*/
|
|
22
|
+
object SentoriMobileVitals {
|
|
23
|
+
|
|
24
|
+
private const val SLOW_FRAME_NS: Long = 16_670_000 // 16.67 ms
|
|
25
|
+
private const val FROZEN_FRAME_NS: Long = 700_000_000 // 700 ms
|
|
26
|
+
|
|
27
|
+
private val jsBridgeReadyAt = AtomicLong(0)
|
|
28
|
+
private val coldStartMs = AtomicLong(-1)
|
|
29
|
+
|
|
30
|
+
private val slowFrames = AtomicInteger(0)
|
|
31
|
+
private val frozenFrames = AtomicInteger(0)
|
|
32
|
+
private var lastFrameNs: Long = 0L
|
|
33
|
+
@Volatile private var frameWatchRunning = false
|
|
34
|
+
private var callback: Choreographer.FrameCallback? = null
|
|
35
|
+
|
|
36
|
+
/** Called when JS init runs. Uses Process start elapsed realtime
|
|
37
|
+
* as the anchor; available API 24+. */
|
|
38
|
+
@JvmStatic
|
|
39
|
+
fun markJsBridgeReady() {
|
|
40
|
+
if (jsBridgeReadyAt.get() != 0L) return
|
|
41
|
+
val now = SystemClock.elapsedRealtime()
|
|
42
|
+
jsBridgeReadyAt.set(now)
|
|
43
|
+
try {
|
|
44
|
+
val processStart = Process.getStartElapsedRealtime()
|
|
45
|
+
coldStartMs.set(now - processStart)
|
|
46
|
+
} catch (_: Throwable) {
|
|
47
|
+
// API < 24 — leave -1 sentinel
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
@JvmStatic
|
|
52
|
+
fun getColdStartMs(): Long? {
|
|
53
|
+
val v = coldStartMs.get()
|
|
54
|
+
return if (v < 0) null else v
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
@JvmStatic
|
|
58
|
+
fun startFrameWatch() {
|
|
59
|
+
if (frameWatchRunning) return
|
|
60
|
+
frameWatchRunning = true
|
|
61
|
+
val cb = object : Choreographer.FrameCallback {
|
|
62
|
+
override fun doFrame(frameTimeNanos: Long) {
|
|
63
|
+
if (!frameWatchRunning) return
|
|
64
|
+
if (lastFrameNs != 0L) {
|
|
65
|
+
val delta = frameTimeNanos - lastFrameNs
|
|
66
|
+
if (delta >= FROZEN_FRAME_NS) {
|
|
67
|
+
frozenFrames.incrementAndGet()
|
|
68
|
+
} else if (delta >= SLOW_FRAME_NS) {
|
|
69
|
+
slowFrames.incrementAndGet()
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
lastFrameNs = frameTimeNanos
|
|
73
|
+
Choreographer.getInstance().postFrameCallback(this)
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
callback = cb
|
|
77
|
+
// Choreographer must be subscribed on the UI thread. Caller
|
|
78
|
+
// is expected to run this on the main thread (SentoriModule
|
|
79
|
+
// OnCreate runs on the main thread for Expo Modules).
|
|
80
|
+
Choreographer.getInstance().postFrameCallback(cb)
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
@JvmStatic
|
|
84
|
+
fun stopFrameWatch() {
|
|
85
|
+
frameWatchRunning = false
|
|
86
|
+
callback?.let { Choreographer.getInstance().removeFrameCallback(it) }
|
|
87
|
+
callback = null
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
@JvmStatic
|
|
91
|
+
fun getFrameCounters(): Map<String, Int> {
|
|
92
|
+
return mapOf("slow" to slowFrames.get(), "frozen" to frozenFrames.get())
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
@JvmStatic
|
|
96
|
+
fun resetFrameCounters() {
|
|
97
|
+
slowFrames.set(0)
|
|
98
|
+
frozenFrames.set(0)
|
|
99
|
+
}
|
|
100
|
+
}
|
|
@@ -18,6 +18,29 @@ class SentoriModule : Module() {
|
|
|
18
18
|
OnCreate {
|
|
19
19
|
val ctx = appContext.reactContext ?: return@OnCreate
|
|
20
20
|
SentoriCrashHandler.register(ctx)
|
|
21
|
+
// v0.9.4 #1 — start frame watch. Cold-start is captured
|
|
22
|
+
// anchored to Process.getStartElapsedRealtime so no
|
|
23
|
+
// separate registerColdStartAnchor() call is needed.
|
|
24
|
+
SentoriMobileVitals.startFrameWatch()
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
// v0.9.5 #8 — TurboModule exception bridge readout.
|
|
28
|
+
Function("getRecentNativeException") {
|
|
29
|
+
SentoriNativeExceptionBridge.getRecent()
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
// v0.9.4 #1 — Mobile Vitals exposure.
|
|
33
|
+
Function("markJsBridgeReady") {
|
|
34
|
+
SentoriMobileVitals.markJsBridgeReady()
|
|
35
|
+
}
|
|
36
|
+
Function("getColdStartMs") {
|
|
37
|
+
SentoriMobileVitals.getColdStartMs()
|
|
38
|
+
}
|
|
39
|
+
Function("getFrameCounters") {
|
|
40
|
+
SentoriMobileVitals.getFrameCounters()
|
|
41
|
+
}
|
|
42
|
+
Function("resetFrameCounters") {
|
|
43
|
+
SentoriMobileVitals.resetFrameCounters()
|
|
21
44
|
}
|
|
22
45
|
|
|
23
46
|
Function("setConfig") { config: Map<String, Any?> ->
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
package com.sentori
|
|
2
|
+
|
|
3
|
+
import java.util.concurrent.ConcurrentLinkedDeque
|
|
4
|
+
import java.util.concurrent.atomic.AtomicLong
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* v0.9.5 #8 — partial fix for TurboModule swallowing native
|
|
8
|
+
* exceptions into a generic JSError.
|
|
9
|
+
*
|
|
10
|
+
* Android side mirrors the iOS implementation. Host TurboModule code:
|
|
11
|
+
*
|
|
12
|
+
* try {
|
|
13
|
+
* riskyOperation()
|
|
14
|
+
* } catch (e: Exception) {
|
|
15
|
+
* SentoriNativeExceptionBridge.record(e)
|
|
16
|
+
* throw e
|
|
17
|
+
* }
|
|
18
|
+
*
|
|
19
|
+
* JS-side coerceError calls `getRecent()` and, if an exception
|
|
20
|
+
* within the last 1 s exists, attaches its stack to the resulting
|
|
21
|
+
* sentori event.
|
|
22
|
+
*/
|
|
23
|
+
object SentoriNativeExceptionBridge {
|
|
24
|
+
|
|
25
|
+
private const val RING_SIZE = 8
|
|
26
|
+
private const val WINDOW_MS = 1_000L
|
|
27
|
+
|
|
28
|
+
private data class Stash(
|
|
29
|
+
val timestamp: Long,
|
|
30
|
+
val name: String,
|
|
31
|
+
val reason: String,
|
|
32
|
+
val stack: List<String>,
|
|
33
|
+
)
|
|
34
|
+
|
|
35
|
+
private val ring = ConcurrentLinkedDeque<Stash>()
|
|
36
|
+
private val lastPurgeAt = AtomicLong(0)
|
|
37
|
+
|
|
38
|
+
@JvmStatic
|
|
39
|
+
fun record(t: Throwable) {
|
|
40
|
+
val frames = t.stackTrace.take(48).map { it.toString() }
|
|
41
|
+
val stash = Stash(
|
|
42
|
+
timestamp = System.currentTimeMillis(),
|
|
43
|
+
name = t.javaClass.simpleName,
|
|
44
|
+
reason = t.message ?: "",
|
|
45
|
+
stack = frames,
|
|
46
|
+
)
|
|
47
|
+
ring.addLast(stash)
|
|
48
|
+
while (ring.size > RING_SIZE) ring.pollFirst()
|
|
49
|
+
purgeIfDue()
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
@JvmStatic
|
|
53
|
+
fun getRecent(): Map<String, Any?>? {
|
|
54
|
+
purgeIfDue()
|
|
55
|
+
val latest = ring.peekLast() ?: return null
|
|
56
|
+
return mapOf(
|
|
57
|
+
"name" to latest.name,
|
|
58
|
+
"reason" to latest.reason,
|
|
59
|
+
"stack" to latest.stack,
|
|
60
|
+
"ageMs" to (System.currentTimeMillis() - latest.timestamp).toInt(),
|
|
61
|
+
)
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
private fun purgeIfDue() {
|
|
65
|
+
val now = System.currentTimeMillis()
|
|
66
|
+
val last = lastPurgeAt.get()
|
|
67
|
+
if (now - last < 100) return
|
|
68
|
+
lastPurgeAt.set(now)
|
|
69
|
+
val cutoff = now - WINDOW_MS
|
|
70
|
+
val it = ring.iterator()
|
|
71
|
+
while (it.hasNext()) {
|
|
72
|
+
if (it.next().timestamp < cutoff) it.remove()
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
package com.sentori
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* v0.9.5 #7 — Android NDK origin detection (stub).
|
|
5
|
+
*
|
|
6
|
+
* Pure-Kotlin heuristics to tag a Throwable as "originated in native
|
|
7
|
+
* code" so the dashboard can show NDK crashes separately from JVM
|
|
8
|
+
* crashes. Real breakpad/crashpad integration (with minidump +
|
|
9
|
+
* dump_syms symbolicator) is queued for v1.1 — see
|
|
10
|
+
* `docs/design/v1-roadmap.md` #7.
|
|
11
|
+
*/
|
|
12
|
+
object SentoriNativeOrigin {
|
|
13
|
+
|
|
14
|
+
/** Returns true iff this throwable likely originated in native
|
|
15
|
+
* (NDK / .so / JNI) code. Used by `SentoriCrashHandler.write` to
|
|
16
|
+
* flip the `native_signal` tag on the event. */
|
|
17
|
+
@JvmStatic
|
|
18
|
+
fun looksNative(t: Throwable): Boolean {
|
|
19
|
+
val name = t.javaClass.simpleName
|
|
20
|
+
if (name == "UnsatisfiedLinkError") return true
|
|
21
|
+
// OutOfMemoryError can be either JVM or native allocator;
|
|
22
|
+
// bias toward native since pure-JVM OOM is rare on modern
|
|
23
|
+
// Android with heap auto-growth.
|
|
24
|
+
if (name == "OutOfMemoryError") return true
|
|
25
|
+
return t.stackTrace.any { f ->
|
|
26
|
+
val cls = f.className
|
|
27
|
+
cls.contains("jni", ignoreCase = true) ||
|
|
28
|
+
cls.contains("native", ignoreCase = true) ||
|
|
29
|
+
f.fileName?.endsWith(".so") == true
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import Foundation
|
|
2
|
+
import UIKit
|
|
3
|
+
import QuartzCore
|
|
4
|
+
|
|
5
|
+
/// v0.9.4 #1 — Mobile Vitals: cold start measurement + slow/frozen
|
|
6
|
+
/// frame counters.
|
|
7
|
+
///
|
|
8
|
+
/// Cold start is read at `applicationDidFinishLaunching` time. We use
|
|
9
|
+
/// `mach_absolute_time` because it's monotonic + survives clock
|
|
10
|
+
/// adjustments. The JS bridge reads via `getColdStartMs()` once at
|
|
11
|
+
/// `sentori.init` and the value rides along with the first event.
|
|
12
|
+
///
|
|
13
|
+
/// Frame counters hook `CADisplayLink` on the main run loop. The
|
|
14
|
+
/// callback compares actual vs expected timestamp; > 16.67ms = slow
|
|
15
|
+
/// (one missed VSync at 60fps), > 700ms = frozen (per Sentry's
|
|
16
|
+
/// definition for parity). Counters reset on navigation transition
|
|
17
|
+
/// — `resetFrameCounters()` from JS side.
|
|
18
|
+
@objc public final class SentoriMobileVitals: NSObject {
|
|
19
|
+
|
|
20
|
+
private static var coldStartCapturedAt: UInt64 = 0
|
|
21
|
+
private static var jsBridgeReadyAt: UInt64 = 0
|
|
22
|
+
private static var coldStartMs: Double? = nil
|
|
23
|
+
|
|
24
|
+
private static var slowFrames: Int = 0
|
|
25
|
+
private static var frozenFrames: Int = 0
|
|
26
|
+
private static var displayLink: CADisplayLink? = nil
|
|
27
|
+
private static var lastFrameTimestamp: CFTimeInterval = 0
|
|
28
|
+
|
|
29
|
+
private static let SLOW_FRAME_MS: Double = 16.67
|
|
30
|
+
private static let FROZEN_FRAME_MS: Double = 700.0
|
|
31
|
+
|
|
32
|
+
/// Call from app delegate or earliest reachable point. Stores
|
|
33
|
+
/// the cold-start anchor. Safe to call multiple times (only the
|
|
34
|
+
/// first effective time wins).
|
|
35
|
+
@objc public static func registerColdStartAnchor() {
|
|
36
|
+
if coldStartCapturedAt == 0 {
|
|
37
|
+
coldStartCapturedAt = mach_absolute_time()
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/// Called by the bridge when JS init() runs. The delta from the
|
|
42
|
+
/// app-delegate anchor → here is the cold-start budget the
|
|
43
|
+
/// user perceived.
|
|
44
|
+
@objc public static func markJsBridgeReady() {
|
|
45
|
+
if jsBridgeReadyAt != 0 { return }
|
|
46
|
+
jsBridgeReadyAt = mach_absolute_time()
|
|
47
|
+
if coldStartCapturedAt > 0 {
|
|
48
|
+
var info = mach_timebase_info()
|
|
49
|
+
mach_timebase_info(&info)
|
|
50
|
+
let elapsed = (jsBridgeReadyAt - coldStartCapturedAt) * UInt64(info.numer) / UInt64(info.denom)
|
|
51
|
+
// ns → ms
|
|
52
|
+
coldStartMs = Double(elapsed) / 1_000_000.0
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
@objc public static func getColdStartMs() -> NSNumber? {
|
|
57
|
+
if let ms = coldStartMs {
|
|
58
|
+
return NSNumber(value: ms)
|
|
59
|
+
}
|
|
60
|
+
return nil
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
/// Start frame budget watch. Idempotent. Hooks CADisplayLink on
|
|
64
|
+
/// the main run loop's common modes so it ticks even during
|
|
65
|
+
/// scroll views.
|
|
66
|
+
@objc public static func startFrameWatch() {
|
|
67
|
+
if displayLink != nil { return }
|
|
68
|
+
DispatchQueue.main.async {
|
|
69
|
+
let link = CADisplayLink(target: self, selector: #selector(onFrame(_:)))
|
|
70
|
+
link.add(to: .main, forMode: .common)
|
|
71
|
+
displayLink = link
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
@objc public static func stopFrameWatch() {
|
|
76
|
+
displayLink?.invalidate()
|
|
77
|
+
displayLink = nil
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
@objc public static func getFrameCounters() -> NSDictionary? {
|
|
81
|
+
return [
|
|
82
|
+
"slow": slowFrames,
|
|
83
|
+
"frozen": frozenFrames,
|
|
84
|
+
]
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
@objc public static func resetFrameCounters() {
|
|
88
|
+
slowFrames = 0
|
|
89
|
+
frozenFrames = 0
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
@objc private static func onFrame(_ link: CADisplayLink) {
|
|
93
|
+
let now = link.timestamp
|
|
94
|
+
if lastFrameTimestamp != 0 {
|
|
95
|
+
let deltaMs = (now - lastFrameTimestamp) * 1000.0
|
|
96
|
+
if deltaMs >= FROZEN_FRAME_MS {
|
|
97
|
+
frozenFrames += 1
|
|
98
|
+
} else if deltaMs >= SLOW_FRAME_MS {
|
|
99
|
+
slowFrames += 1
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
lastFrameTimestamp = now
|
|
103
|
+
}
|
|
104
|
+
}
|
package/ios/SentoriModule.swift
CHANGED
|
@@ -14,6 +14,29 @@ public class SentoriModule: Module {
|
|
|
14
14
|
|
|
15
15
|
OnCreate {
|
|
16
16
|
SentoriCrashHandler.register()
|
|
17
|
+
// v0.9.4 #1 — capture cold-start anchor + start frame watch.
|
|
18
|
+
SentoriMobileVitals.registerColdStartAnchor()
|
|
19
|
+
SentoriMobileVitals.startFrameWatch()
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
// v0.9.5 #8 — TurboModule exception bridge readout for
|
|
23
|
+
// coerceError to attach native stack to wrapped JSError.
|
|
24
|
+
Function("getRecentNativeException") { () -> [String: Any]? in
|
|
25
|
+
return SentoriNativeExceptionBridge.getRecentException()
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
// v0.9.4 #1 — Mobile Vitals exposure.
|
|
29
|
+
Function("markJsBridgeReady") {
|
|
30
|
+
SentoriMobileVitals.markJsBridgeReady()
|
|
31
|
+
}
|
|
32
|
+
Function("getColdStartMs") { () -> Double? in
|
|
33
|
+
return SentoriMobileVitals.getColdStartMs()?.doubleValue
|
|
34
|
+
}
|
|
35
|
+
Function("getFrameCounters") { () -> [String: Any]? in
|
|
36
|
+
return SentoriMobileVitals.getFrameCounters() as? [String: Any]
|
|
37
|
+
}
|
|
38
|
+
Function("resetFrameCounters") {
|
|
39
|
+
SentoriMobileVitals.resetFrameCounters()
|
|
17
40
|
}
|
|
18
41
|
|
|
19
42
|
Function("setConfig") { (config: [String: Any]) in
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import Foundation
|
|
2
|
+
|
|
3
|
+
/// v0.9.5 #8 — partial-fix for the "TurboModule swallows NSException
|
|
4
|
+
/// into a generic JSError" gap.
|
|
5
|
+
///
|
|
6
|
+
/// We can't easily swizzle the C++ ObjCTurboModule call site that does
|
|
7
|
+
/// the swallowing. What we *can* offer is an escape hatch: host code
|
|
8
|
+
/// inside a TurboModule method wraps its native call in `@try @catch`
|
|
9
|
+
/// and calls `SentoriNativeExceptionBridge.record(exception)` from the
|
|
10
|
+
/// catch block. We stash the exception (name + reason + callStackSymbols)
|
|
11
|
+
/// in a static ring with timestamps. When the JS side then receives
|
|
12
|
+
/// the generic JSError that RN wraps it into, `coerceError` checks the
|
|
13
|
+
/// ring for an exception within the last 1 s and attaches the native
|
|
14
|
+
/// stack to the JS error event.
|
|
15
|
+
///
|
|
16
|
+
/// Usage from a host TurboModule (Swift example):
|
|
17
|
+
///
|
|
18
|
+
/// @objc func mySensitiveMethod() {
|
|
19
|
+
/// do {
|
|
20
|
+
/// try riskyNativeOperation()
|
|
21
|
+
/// } catch let nsException as NSException {
|
|
22
|
+
/// SentoriNativeExceptionBridge.record(nsException)
|
|
23
|
+
/// throw nsException
|
|
24
|
+
/// }
|
|
25
|
+
/// }
|
|
26
|
+
///
|
|
27
|
+
/// Or Objective-C:
|
|
28
|
+
///
|
|
29
|
+
/// @try {
|
|
30
|
+
/// riskyOp();
|
|
31
|
+
/// } @catch (NSException *e) {
|
|
32
|
+
/// [SentoriNativeExceptionBridge recordException:e];
|
|
33
|
+
/// @throw;
|
|
34
|
+
/// }
|
|
35
|
+
|
|
36
|
+
@objc public final class SentoriNativeExceptionBridge: NSObject {
|
|
37
|
+
|
|
38
|
+
private static let RING_SIZE = 8
|
|
39
|
+
private static let WINDOW_MS: Double = 1000
|
|
40
|
+
|
|
41
|
+
private struct Stash {
|
|
42
|
+
let timestamp: Date
|
|
43
|
+
let name: String
|
|
44
|
+
let reason: String
|
|
45
|
+
let stack: [String]
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
private static var ring: [Stash] = []
|
|
49
|
+
private static let lock = NSLock()
|
|
50
|
+
|
|
51
|
+
/// Called from a `@catch` inside a TurboModule method. Records
|
|
52
|
+
/// the exception's name + reason + callStackSymbols for ~1 s so
|
|
53
|
+
/// the JS-side coerceError can pick it up.
|
|
54
|
+
@objc public static func recordException(_ exception: NSException) {
|
|
55
|
+
let stash = Stash(
|
|
56
|
+
timestamp: Date(),
|
|
57
|
+
name: exception.name.rawValue,
|
|
58
|
+
reason: exception.reason ?? "",
|
|
59
|
+
stack: exception.callStackSymbols
|
|
60
|
+
)
|
|
61
|
+
lock.lock()
|
|
62
|
+
defer { lock.unlock() }
|
|
63
|
+
ring.append(stash)
|
|
64
|
+
while ring.count > RING_SIZE {
|
|
65
|
+
ring.removeFirst()
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
/// Called by JS-side bridge. Returns the most recent exception
|
|
70
|
+
/// within the last 1 s, or nil. Does NOT remove from the ring —
|
|
71
|
+
/// the same NSException may surface as multiple JSError frames
|
|
72
|
+
/// across the bridge. Ring is cleared by `purge()` on a timer.
|
|
73
|
+
@objc public static func getRecentException() -> [String: Any]? {
|
|
74
|
+
lock.lock()
|
|
75
|
+
defer { lock.unlock() }
|
|
76
|
+
purgeLocked()
|
|
77
|
+
guard let latest = ring.last else { return nil }
|
|
78
|
+
return [
|
|
79
|
+
"name": latest.name,
|
|
80
|
+
"reason": latest.reason,
|
|
81
|
+
"stack": latest.stack,
|
|
82
|
+
"ageMs": Int(Date().timeIntervalSince(latest.timestamp) * 1000),
|
|
83
|
+
]
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
private static func purgeLocked() {
|
|
87
|
+
let now = Date()
|
|
88
|
+
ring.removeAll { now.timeIntervalSince($0.timestamp) * 1000 > WINDOW_MS }
|
|
89
|
+
}
|
|
90
|
+
}
|
package/lib/capture.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"capture.d.ts","sourceRoot":"","sources":["../src/capture.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"capture.d.ts","sourceRoot":"","sources":["../src/capture.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAoD,IAAI,EAAE,IAAI,EAAE,MAAM,SAAS,CAAC;AAE5F,OAAO,EAAE,WAAW,EAAE,oBAAoB,EAAE,MAAM,SAAS,CAAC;AAgB5D,eAAO,MAAM,+BAA+B,QAAO,IAElD,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,OAAO,GAAI,MAAM,IAAI,GAAG,IAAI,KAAG,IAE3C,CAAC;AAEF,eAAO,MAAM,OAAO,QAAO,IAAI,GAAG,IAAa,CAAC;AAEhD,MAAM,MAAM,aAAa,GAAG;IAC1B,IAAI,CAAC,EAAE,IAAI,CAAC;IACZ,IAAI,CAAC,EAAE,IAAI,CAAC;IACZ,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;IACvB;;;qDAGiD;IACjD,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB,CAAC;AAEF;;;;;;;;;GASG;AACH,eAAO,MAAM,gBAAgB,GAAU,OAAO;IAC5C,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;CACf,KAAG,OAAO,CAAC,IAAI,GAAG;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,IAAI,GAAG,MAAM,CAAA;CAAE,CAKxD,CAAC;AAEF,eAAO,MAAM,YAAY,GAAI,OAAO,KAAK,EAAE,SAAS,aAAa,KAAG,IAqEnE,CAAC;AAiEF,eAAO,MAAM,gBAAgB,UAtIO,KAAK,WAAW,aAAa,KAAG,IAsIxB,CAAC"}
|
package/lib/capture.js
CHANGED
|
@@ -12,6 +12,7 @@ import { getTrailBuffer } from './trail';
|
|
|
12
12
|
import { enqueue, sendUserReport, uploadAttachment } from './transport';
|
|
13
13
|
import { uuidV7 } from './uuid';
|
|
14
14
|
import { getCachedNetworkType } from './netinfo';
|
|
15
|
+
import { getRecentNativeException } from './native';
|
|
15
16
|
export { captureStep, __resetTrailForTests } from './trail';
|
|
16
17
|
let _user = null;
|
|
17
18
|
// Phase 42 sub-D.08 — per-session screenshot quota. Defaults: 10 in
|
|
@@ -219,6 +220,26 @@ const errorToObject = (error) => {
|
|
|
219
220
|
if (causeRaw instanceof Error) {
|
|
220
221
|
cause = errorToObject(causeRaw);
|
|
221
222
|
}
|
|
223
|
+
// v0.9.5 #8 — TurboModule swallowed-exception bridge. If the host
|
|
224
|
+
// wrapped a native call with `@try @catch + recordException`, the
|
|
225
|
+
// native ring may hold a fresh entry (< 1 s old). Synthesize that
|
|
226
|
+
// as a `cause` so the JS event includes the original native stack.
|
|
227
|
+
if (cause === null) {
|
|
228
|
+
const recent = getRecentNativeException();
|
|
229
|
+
if (recent && recent.ageMs <= 1500) {
|
|
230
|
+
cause = {
|
|
231
|
+
type: recent.name || 'NativeException',
|
|
232
|
+
message: recent.reason,
|
|
233
|
+
stack: recent.stack.map((line, i) => ({
|
|
234
|
+
function: line.trim(),
|
|
235
|
+
file: '<native>',
|
|
236
|
+
inApp: false,
|
|
237
|
+
line: i + 1,
|
|
238
|
+
})),
|
|
239
|
+
cause: null,
|
|
240
|
+
};
|
|
241
|
+
}
|
|
242
|
+
}
|
|
222
243
|
return {
|
|
223
244
|
type: error.name || 'Error',
|
|
224
245
|
message: error.message,
|
package/lib/capture.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"capture.js","sourceRoot":"","sources":["../src/capture.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAEjE,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;AAC9D,OAAO,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAC9C,OA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AS,EAAE,CAAC;YAC9B,MAAM,GAAG,EAAE,CAAC,aAAa,CAAC,WAAW,EAAE,gBAAgB,CAAC;QAC1D,CAAC;IACH,CAAC;IAAC,MAAM,CAAC;QACP,qCAAqC;IACvC,CAAC;IACD,MAAM,MAAM,GAAW,EAAE,EAAE,EAAE,SAAS,EAAE,CAAC;IACzC,IAAI,MAAM;QAAE,MAAM,CAAC,MAAM,GAAG,MAAM,CAAC;IACnC,IAAI,WAAW;QAAE,MAAM,CAAC,WAAW,GAAG,WAAW,CAAC;IAClD,OAAO,MAAM,CAAC;AAChB,CAAC,CAAC;AAEF,MAAM,UAAU,GAAG,CAAC,OAAe,EAAO,EAAE;IAC1C,MAAM,CAAC,GAAG,iCAAiC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;IAC1D,MAAM,OAAO,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,IAAI,OAAO,CAAC;IAClC,MAAM,KAAK,GAAG,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;IAErB,IAAI,SAAS,GAAG,SAAS,CAAC;IAC1B,IAAI,CAAC;QACH,SAAS,GAAI,OAAO,CAAC,2BAA2B,CAAyB,CAAC,OAAO,CAAC;IACpF,CAAC;IAAC,MAAM,CAAC;QACP,oBAAoB;IACtB,CAAC;IAED,OAAO;QACL,OAAO;QACP,KAAK;QACL,SAAS,EAAE,EAAE,IAAI,EAAE,cAAc,EAAE,OAAO,EAAE,SAAS,EAAE;KACxD,CAAC;AACJ,CAAC,CAAC"}
|
package/lib/index.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ import { ErrorBoundary } from './error-boundary';
|
|
|
2
2
|
import { type FeedbackButtonHandle, type FeedbackButtonProps } from './feedback-widget';
|
|
3
3
|
import { clearMaskQuery, registerMaskQuery } from './mask';
|
|
4
4
|
import { measureFn } from './measure';
|
|
5
|
+
import { getColdStartMs, markTimeToFullDisplay } from './mobile-vitals';
|
|
5
6
|
import { bindState, recordState, unbindState } from './state-snapshots';
|
|
6
7
|
import { startMoment } from '@goliapkg/sentori-core';
|
|
7
8
|
import { flushMetrics, recordMetric } from './metrics';
|
|
@@ -31,6 +32,8 @@ export declare const sentori: {
|
|
|
31
32
|
bindState: typeof bindState;
|
|
32
33
|
recordState: typeof recordState;
|
|
33
34
|
unbindState: typeof unbindState;
|
|
35
|
+
markTimeToFullDisplay: typeof markTimeToFullDisplay;
|
|
36
|
+
getColdStartMs: typeof getColdStartMs;
|
|
34
37
|
setFeatureFlag: (name: string, value: string) => void;
|
|
35
38
|
clearFeatureFlag: (name: string) => void;
|
|
36
39
|
clearAllFeatureFlags: () => void;
|
|
@@ -54,6 +57,7 @@ export { clearAllFeatureFlags, clearFeatureFlag, getFeatureFlags, setFeatureFlag
|
|
|
54
57
|
export { clearMaskQuery, registerMaskQuery } from './mask';
|
|
55
58
|
export { flushMetrics, recordMetric } from './metrics';
|
|
56
59
|
export { measureFn } from './measure';
|
|
60
|
+
export { getColdStartMs, markTimeToFullDisplay, type TimeToFullDisplayHandle, } from './mobile-vitals';
|
|
57
61
|
export { MomentHandle, type MomentProperties, startMoment } from '@goliapkg/sentori-core';
|
|
58
62
|
export { bindState, recordState, type StateSnapshot, unbindState, } from './state-snapshots';
|
|
59
63
|
export { RageTapCapture } from './rage-tap';
|
package/lib/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAUA,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAkB,KAAK,oBAAoB,EAAE,KAAK,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAOxG,OAAO,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,QAAQ,CAAC;AAC3D,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AACtC,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AACxE,O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AACjD,OAAO,EAAE,cAAc,EAAE,KAAK,oBAAoB,EAAE,KAAK,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AACxG,OAAO,EACL,oBAAoB,EACpB,gBAAgB,EAChB,eAAe,EACf,cAAc,GACf,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,QAAQ,CAAC;AAC3D,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AACvD,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AACtC,OAAO,EACL,cAAc,EACd,qBAAqB,EACrB,KAAK,uBAAuB,GAC7B,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAE,YAAY,EAAE,KAAK,gBAAgB,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAC1F,OAAO,EACL,SAAS,EACT,WAAW,EACX,KAAK,aAAa,EAClB,WAAW,GACZ,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAC5C,OAAO,EACL,gBAAgB,EAChB,eAAe,EACf,kBAAkB,GACnB,MAAM,UAAU,CAAC;AAClB,OAAO,EACL,UAAU,EACV,kBAAkB,EAClB,YAAY,GACb,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,KAAK,iBAAiB,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAE1E,YAAY,EACV,KAAK,EACL,YAAY,EACZ,KAAK,EACL,UAAU,EACV,cAAc,EACd,MAAM,EACN,QAAQ,EACR,GAAG,EACH,IAAI,EACJ,IAAI,EACJ,SAAS,EACT,QAAQ,GACT,MAAM,SAAS,CAAC"}
|
package/lib/index.js
CHANGED
|
@@ -6,6 +6,7 @@ import { FeedbackButton } from './feedback-widget';
|
|
|
6
6
|
import { clearAllFeatureFlags, clearFeatureFlag, getFeatureFlags, setFeatureFlag, } from './feature-flags';
|
|
7
7
|
import { clearMaskQuery, registerMaskQuery } from './mask';
|
|
8
8
|
import { measureFn } from './measure';
|
|
9
|
+
import { getColdStartMs, markTimeToFullDisplay, } from './mobile-vitals';
|
|
9
10
|
import { bindState, recordState, unbindState } from './state-snapshots';
|
|
10
11
|
import { startMoment } from '@goliapkg/sentori-core';
|
|
11
12
|
import { flushMetrics, recordMetric } from './metrics';
|
|
@@ -27,6 +28,8 @@ export const sentori = {
|
|
|
27
28
|
bindState,
|
|
28
29
|
recordState,
|
|
29
30
|
unbindState,
|
|
31
|
+
markTimeToFullDisplay,
|
|
32
|
+
getColdStartMs,
|
|
30
33
|
setFeatureFlag,
|
|
31
34
|
clearFeatureFlag,
|
|
32
35
|
clearAllFeatureFlags,
|
|
@@ -50,6 +53,7 @@ export { clearAllFeatureFlags, clearFeatureFlag, getFeatureFlags, setFeatureFlag
|
|
|
50
53
|
export { clearMaskQuery, registerMaskQuery } from './mask';
|
|
51
54
|
export { flushMetrics, recordMetric } from './metrics';
|
|
52
55
|
export { measureFn } from './measure';
|
|
56
|
+
export { getColdStartMs, markTimeToFullDisplay, } from './mobile-vitals';
|
|
53
57
|
export { MomentHandle, startMoment } from '@goliapkg/sentori-core';
|
|
54
58
|
export { bindState, recordState, unbindState, } from './state-snapshots';
|
|
55
59
|
export { RageTapCapture } from './rage-tap';
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,OAAO,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAC9C,OAAO,EACL,YAAY,EACZ,gBAAgB,EAChB,WAAW,EACX,OAAO,EACP,gBAAgB,EAChB,OAAO,GACR,MAAM,WAAW,CAAC;AACnB,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAE,cAAc,EAAuD,MAAM,mBAAmB,CAAC;AACxG,OAAO,EACL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iBAAiB,EAAE,MAAM,QAAQ,CAAC;AAC3D,OAAO,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AACvD,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AACtC,OAAO,EACL,cAAc,EACd,qBAAqB,GAEtB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EAAE,YAAY,EAAyB,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAC1F,OAAO,EACL,SAAS,EACT,WAAW,EAEX,WAAW,GACZ,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAC5C,OAAO,EACL,gBAAgB,EAChB,eAAe,EACf,kBAAkB,GACnB,MAAM,UAAU,CAAC;AAClB,OAAO,EACL,UAAU,EACV,kBAAkB,EAClB,YAAY,GACb,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAA0B,kBAAkB,EAAE,MAAM,cAAc,CAAC"}
|
package/lib/init.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"init.d.ts","sourceRoot":"","sources":["../src/init.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"init.d.ts","sourceRoot":"","sources":["../src/init.ts"],"names":[],"mappings":"AAeA,OAAO,EAAyB,KAAK,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAQnF,OAAO,KAAK,EAAkB,cAAc,EAA2B,MAAM,SAAS,CAAC;AAIvF,MAAM,MAAM,WAAW,GAAG;IACxB,sDAAsD;IACtD,KAAK,EAAE,MAAM,CAAC;IACd,4DAA4D;IAC5D,OAAO,EAAE,MAAM,CAAC;IAChB,sEAAsE;IACtE,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,qFAAqF;IACrF,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,iEAAiE;IACjE,OAAO,CAAC,EAAE;QACR,YAAY,CAAC,EAAE,OAAO,CAAC;QACvB,iBAAiB,CAAC,EAAE,OAAO,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