So asking again for some advice on how to debug / ...
# compose
t
So asking again for some advice on how to debug / repro a Compose issue with keyboard. Randomly without any text composable anywhere when returning to the app from home the keyboard will open. When it happens closing the keyboard, going home, returning to the app will bring back the keyboard again. I have no idea what I can observe / could generate that to try to build a repro 😞
To complement if I go in a place that has a text field and show then hide the keyboard from there then the issue is fixed and won't be back until a random time / return.
i
Yups, I also face this issue
t
@Zach Klippenstein (he/him) [MOD] Sorry to ping you but you are the expert on that matter and if I open an issue without a repro it won't go anywhere.
c
What Android OS are you using? I feel like I've seen this open in bugtracker as a general android 12 issue and actually nothing to do with compose. edit: not saying that your issue is the same thing, but curious if youve only seen it on 12.
i
I have experienced it on android 9 and 12
👍 1
t
Same 10 and 12 and never with 12 on my other apps. Do you have a link to that thread in case there's hints ?
z
So you haven't been able to reproduce reliably? Are you working in a public codebase we could try using? Please file a bug either way so we can track this
i
That's an open source project but It's in development as of now.
t
On my side source is closed, but yes can't reproduce reliably else I'd have reported already. I'll open the issue later without a repro first then and link it here so that @Illustrator can share it's code if it's reproducible. As far as I can tell, this may happen randomly if at some point I use the IME action that will navigate away so remove the parent composable and close the keyboard. Maybe some race that leave some state internal to compose.
Copy code
keyboardActions = KeyboardActions(onSend = {
 keyboardController?.hide()
 viewModel.navigate()})
For the moment that would be my only explanation but this could be something completely different.
z
Thanks. Feel free to file now and link the project later
Your race explanation sounds plausible, maybe we missed a dispose action somewhere or something. Please include that information in the bug!
t
On parenting duty but will in a few hours.
👶 1
@Zach Klippenstein (he/him) [MOD] As expected no reaction on the issue except asking me to build a repro ignoring my ask about hints about how to make that repro ... Since the issue is worse with the last compose version I'd really like if you could help to build that repro. This is the last really annoying bug that I'd like to fix before going to prod.
z
As someone pointed out in that ticket, I’m guessing it’s the same issue as https://issuetracker.google.com/227218393
t
@Zach Klippenstein (he/him) [MOD] I'm not sure 😞 When trying to build a small repro switching to the next screen did keep the keyboard but hiding it then returning to the app did not show the keyboard again. But since then some other users have posted some repro maybe there's hints in them ?
And that keyboard not hidden things appeared in alpha 6 the keyboard showing again issue appeared before (but it's 100% repro now with alpha 6/7)
z
I just got back from vacation, still trying to figure out what is going on this week, but i’ll add this to my personal backlog
💯 1
❤️ 1
t
Thanks but take time to get back, first day after 2 weeks is hard 😛
@Zach Klippenstein (he/him) [MOD] pinging here seeing the other users comment on the issue. So the issue is not fixed it's back to random and back to fixable by showing the keyboard then hiding it.
@Zach Klippenstein (he/him) [MOD] ping again since you are here, can you please reopen https://issuetracker.google.com/issues/221895355 it's not fixed it's back to the initial random state.
z
re-opened
❤️ 1
t
The app is now released so if you can give me
some pointer I might find time to work on finding a repro.
z
No worries, hoping to be able to repro and fix with the existing info
t
Thanks, that and a mem leak in derivedStateOf are the last 2 impacting compose bugs, but so far, nearly all works nicely and performant. Very nice work to all the team even if you joined after 🙂
z
is there a bug for that derivedStateOf leak? I just searched and don’t see anythikng
t
Yes https://issuetracker.google.com/issues/230168389 it's handled by Chuck, the title is LazyColumn as I thought it was that first. And already half of it fixed.
👍🏻 1
@Zach Klippenstein (he/him) [MOD] Sorry to ask here and to you but do you think you can help having https://issuetracker.google.com/issues/227218386 properly attributed and triaged? Since it's text you probably know the proper core team. Thanks.
z
Looks like it’s already been assigned to the right team
t
:( 10 years of fighting to be 100% crash free session on Core Vitals down to ugly 99.9% because of it :( It's usually a bad sign when no reaction or triaging. Anyway thanks for looking at it.
But checking again, it's in the right category, but still assigned to the external triager, so not sure they even see it as to be handled.
z
It’s assigned to an internal team alias, seems like the right one
t
Ok thanks, only seeing an... and so many bad memory with an... asking over and over things without reading that I now fear those 2 letter.
c
100% crash free? Congrats! Keep filling bugs. We'll get back to 100 💪
t
100% crash free / 100% ANR free on that app since 5 years approx 🙂 App on store since 10 years, was a hard challenge to reach 🙂 (And of course this is due to Play Console rounding 😛 it's impossible to be really at 100%)
🎉 1