Closed Monabr closed 9 months ago
Are you manually starting the activity? You are supposed to start this activity using the ShowkaseBrowserActivity.getIntent()
method. Is that what you used?
@vinaygaba I am not using this activity, some bots launch it in my code. I am not manually starting the activity.
@Monabr In that case, this activity isn't being started correctly as it needs more information to work correctly. This is an intentional failure - https://github.com/airbnb/Showkase/blob/8d9e120e5f4c1b34e3824fd07de9699876277639/showkase/src/main/java/com/airbnb/android/showkase/ui/ShowkaseBrowserActivity.kt#L23
Is there a way where you can pass additional information when this activity is started (or how this activity is started)? I suspect you do?
@vinaygaba I am not using this activity, I am not starting it. Some other people's bots, which I have nothing to do with, enter my application and launch this activity.
@Monabr Not sure how to help here if these bots are starting the activity incorrectly. I have no control over this, library is doing the right thing as it's designed to.
@vinaygaba We need to remove this activity from the release build; it is absolutely unnecessary there, has no use and causes problems. Or do something about this crashes so that it does not spoil the statistics.
You can make Showkase only available in debug builds. Make sure your setup looks like this -
debugImplementation "com.airbnb.android:showkase:1.0.2"
kspDebug "com.airbnb.android:showkase-processor:1.0.2"
implementation "com.airbnb.android:showkase-annotation:1.0.2"
@vinaygaba I don’t use your dependencies directly; they probably came to me along with the Jetpack Compose dependencies. How could I fix the situation?
@Monabr That's not possible. This library is an opt-in library and doesn't come by default if you use Jetpack Compose.
@vinaygaba I have Lottie package with com.airbnb...
maybe that activity comes from their dependencies? How could I fix the situation?
Lottie doesn't use Showkase so that's not possible either. I recommend spending some more time debugging as it's unrelated to the library itself and has probably something to do with your setup.
@Monabr I was able to understand the root cause of this issue -
It stems from your use of this library - https://github.com/marosseleng/compose-material3-datetime-pickers
It leverages Showkase in a way that uses it as an implementation
dependency as opposed to debugImplementation
like I recommended in this comment https://github.com/airbnb/Showkase/issues/366#issuecomment-1868363576. If the library added a debug dependency on Showkase, it wouldn't be available in your release builds.
Moreover, this is happening because the ShowkaseBrowserActivity
used to be incorrectly exported. This was fixed here - https://github.com/airbnb/Showkase/pull/355. However, a new release hasn't gone out since this fix was merged. So even though this issue has been fixed, it's not available yet (but will be with the new release). Hope that makes sense.
Hello.
With each of my releases, bots come to me and launch
ShowkaseBrowserActivity
, it crashes and I get bad statistics. Is there any way to fix this?