-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Crash while panning around #41
Comments
Yea I've seen this happen a few times, but this particular crash has proven to be especially elusive. I recently made a change that will cause the crash to happen earlier in the call chain. Posting it here if someone is able to spot something obvious: telephoto/zoomable/src/commonMain/kotlin/me/saket/telephoto/zoomable/ZoomableState.kt Lines 332 to 334 in 612c5a4
Can you also confirm telephoto's version in this crash report? |
We are using telephoto 0.5.0, and I confirm that we observe some crash reports with the check: For instance:
or
|
I spent a few hours but this crash seems to have become even more difficult to reproduce. I believe I have a better understanding of what might be causing it, but I'm still shooting in the dark. To help myself, I've added some more debug information to the exception. @ganfra @bmarty possible for you to try out |
Is the |
Hmmm that doesn't sound right. Can you try again? You can find the snapshot artifacts here: allprojects {
repositories {
…
maven { url = "https://oss.sonatype.org/content/repositories/snapshots/" }
}
} |
I did run into this crash but haven't been able to reproduce it since.
|
Thanks @igorilin13! Can you also share the full stacktrace? |
|
Huh these logs suggest that I've been investigating in the wrong direction all this time. The infinite offset isn't being calculated by any division by zero errors, but rather an infinite velocity tracked by the gesture receiver. I've added a few more logs to confirm this. Please keep sending the stacktraces, and thanks again! |
We have another recent stacktrace here:
|
Does that stacktrace not contain any message? The line numbers seem to point to bb4929b, which is an old snapshot build before any debug information was added to the exceptions. |
No, that's all we got from the crash in play store, sorry. I thought this stacktrace was from a version that should have a SNAPSHOT with the debug info, but I believe it comes from nightly versions who share the same string version, so maybe it was one before we switched to using the snapshots 🤔 . |
No worries, I should have bumped up the snapshot version to avoid this confusion. FWIW I was able to reproduce a situation where quick zooms would result in a division by zero error and it looks awfully similar to this crash. I'm not 100% sure it's the same one because @igorilin13's stacktrace in #41 (comment) indicates that a fling was made before the crash occurred, but 🤞! I'll make a new release soon. |
We got some new logs for a crash:
|
Interesting, can you include the full stacktrace? It is unclear where the crash is happening. |
I edited the stacktrace above, but now that I look at it again this might be an actual bug in our code that I mistook for this issue. I saw |
Haha no worries! |
Has anyone received any new crash reports since ^ this change was published? |
@jmartinesp is it possible that your crash is related to #49? The presence of |
@saket I just had this happen to me (version 0.6.1). Here are the logs:
I am using |
@FilippoVigani this was very helpful, thank you! I think I'm close to marking these crashes as resolved after this and #53.
How are you finding its performance? |
0.7.1 should hopefully mark the end of this issue. I'll keep this open for a few months just to be sure. |
…1002) This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [me.saket.telephoto:zoomable-image-coil](https://togithub.com/saket/telephoto) | dependencies | minor | `0.6.2` -> `0.7.1` | --- > [!WARNING] > Some dependencies could not be looked up. Check the Dependency Dashboard for more information. --- ### Release Notes <details> <summary>saket/telephoto (me.saket.telephoto:zoomable-image-coil)</summary> ### [`v0.7.1`](https://togithub.com/saket/telephoto/releases/tag/0.7.1) - Migrated all usages of `Modifier.composed()` to the new [`Modifier.Node` architecture](https://www.youtube.com/watch?v=BjGX2RftXsU). This should help with performance, especially if your app uses multiple zoomable content on the same screen. - [saket/telephoto#54: `ZoomableContentTransformation` now includes additional information about the content's scale: [`ScaleMetadata`](https://togithub.com/saket/telephoto/blob/9bf0937333e240832d5ecaad57bf31825f0d76b7/zoomable/src/commonMain/kotlin/me/saket/telephoto/zoomable/ZoomableContentTransformation.kt#L78-L90), Breaking changes - Reduced the public API surface by replacing all `data` classes with plain classes. These classes still implement `equals` and `hashCode` (thanks to [poko](https://togithub.com/drewhamilton/poko/)), but they no longer offer any `componentN()` or `copy()` functions. Bug fixes - [saket/telephoto#53: Prevent crashes when Compose UI reports the velocity of a gesture to be infinite. - [saket/telephoto#41: Fixed a crash where touch events received after the UI was restored would cause a division by zero error if the layout wasn't measured yet. </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Enabled. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Renovate Bot](https://togithub.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy41OS44IiwidXBkYXRlZEluVmVyIjoiMzcuNTkuOCIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->
[![Mend Renovate logo banner](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [me.saket.telephoto:zoomable-image-coil](https://togithub.com/saket/telephoto) | `0.6.2` -> `0.7.1` | [![age](https://developer.mend.io/api/mc/badges/age/maven/me.saket.telephoto:zoomable-image-coil/0.7.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/me.saket.telephoto:zoomable-image-coil/0.7.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/me.saket.telephoto:zoomable-image-coil/0.6.2/0.7.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/me.saket.telephoto:zoomable-image-coil/0.6.2/0.7.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [me.saket.telephoto:zoomable-image](https://togithub.com/saket/telephoto) | `0.6.2` -> `0.7.1` | [![age](https://developer.mend.io/api/mc/badges/age/maven/me.saket.telephoto:zoomable-image/0.7.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/me.saket.telephoto:zoomable-image/0.7.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/me.saket.telephoto:zoomable-image/0.6.2/0.7.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/me.saket.telephoto:zoomable-image/0.6.2/0.7.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | | [me.saket.telephoto:zoomable](https://togithub.com/saket/telephoto) | `0.6.2` -> `0.7.1` | [![age](https://developer.mend.io/api/mc/badges/age/maven/me.saket.telephoto:zoomable/0.7.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://developer.mend.io/api/mc/badges/adoption/maven/me.saket.telephoto:zoomable/0.7.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://developer.mend.io/api/mc/badges/compatibility/maven/me.saket.telephoto:zoomable/0.6.2/0.7.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/maven/me.saket.telephoto:zoomable/0.6.2/0.7.1?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>saket/telephoto (me.saket.telephoto:zoomable-image-coil)</summary> ### [`v0.7.1`](https://togithub.com/saket/telephoto/releases/tag/0.7.1) - Migrated all usages of `Modifier.composed()` to the new [`Modifier.Node` architecture](https://www.youtube.com/watch?v=BjGX2RftXsU). This should help with performance, especially if your app uses multiple zoomable content on the same screen. - [saket/telephoto#54: `ZoomableContentTransformation` now includes additional information about the content's scale: [`ScaleMetadata`](https://togithub.com/saket/telephoto/blob/9bf0937333e240832d5ecaad57bf31825f0d76b7/zoomable/src/commonMain/kotlin/me/saket/telephoto/zoomable/ZoomableContentTransformation.kt#L78-L90), Breaking changes - Reduced the public API surface by replacing all `data` classes with plain classes. These classes still implement `equals` and `hashCode` (thanks to [poko](https://togithub.com/drewhamilton/poko/)), but they no longer offer any `componentN()` or `copy()` functions. Bug fixes - [saket/telephoto#53: Prevent crashes when Compose UI reports the velocity of a gesture to be infinite. - [saket/telephoto#41: Fixed a crash where touch events received after the UI was restored would cause a division by zero error if the layout wasn't measured yet. </details> --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about these updates again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://developer.mend.io/github/ZacSweers/CatchUp). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy41OS44IiwidXBkYXRlZEluVmVyIjoiMzcuNTkuOCIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
I haven't received any more crash reports so I'm going ahead and closing this one. Please feel free to reopen if you see anything in your crash monitoring system. |
A user got a crash while panning around an image. I don't have the image to reproduce it, but hopefully the crash logs will be enough :
The text was updated successfully, but these errors were encountered: