Pablichjenkov
07/21/2023, 1:35 AM#Versions
kotlin.version=1.8.21
agp.version=7.4.2
compose.version=1.5.0-dev1114
Sometimes I see this message as the last printed in the logs:
"Message from debugger: Terminated due to signal 9", I confirm this is myself killing the App manually. The logger goes muted.
The freeze is only happening with a real device, cannot reproduce it with emulators, only reproducible on a real device, see bellow
model: iPhone 13 mini
iOS version: 16.5.1
More in thread, seems that I have a culprit
Pablichjenkov
07/21/2023, 4:11 AMAnimatedContent(
targetState = childComponent,
transitionSpec = { getTransitionByAnimationType(animationType) }
) {
it.Content(Modifier)
}
where:
@OptIn(ExperimentalAnimationApi::class)
private fun getTransitionByAnimationType(animationType: AnimationType): ContentTransform {
return when (animationType) {
AnimationType.Direct -> {
slideInHorizontally(
initialOffsetX = { fullWidth ->
fullWidth
},
animationSpec = tween(
durationMillis = 300,
delayMillis = 0
)
) with
slideOutHorizontally(
targetOffsetX = { fullWidth ->
-fullWidth
},
animationSpec = tween(
durationMillis = 300,
delayMillis = 0
)
)
}
AnimationType.Reverse -> {
slideInHorizontally(
initialOffsetX = { fullWidth ->
-fullWidth
},
animationSpec = tween()
) with
slideOutHorizontally(
targetOffsetX = { fullWidth ->
fullWidth
},
animationSpec = tween()
)
}
AnimationType.Exit,
AnimationType.Enter -> {
fadeIn(
animationSpec = tween()
) with fadeOut(
animationSpec = tween()
)
}
}
}
but then I noticed that with
has been deprecated.Pablichjenkov
07/21/2023, 5:09 AMIgor Demin
07/21/2023, 10:23 AMimplementation("org.jetbrains.skiko:skiko") {
version {
strictly("0.7.68")
}
}
Igor Demin
07/21/2023, 10:29 AMIf I commented out the following code, the problem is gone:Is it possible to create a compilable reproducer from this code? We will appreciate it, it will help to fix the issue faster.
Pablichjenkov
07/21/2023, 1:44 PMElijah Semyonov
07/21/2023, 3:53 PMval types = listOf(AnimationType.Direct, AnimationType.Enter, AnimationType.Exit, AnimationType.Reverse)
var index by remember { mutableStateOf(0) }
Column(Modifier.fillMaxSize(), verticalArrangement = Arrangement.Center) {
var targetState by remember { mutableStateOf(5f) }
Button(onClick = {
index = (index + 1) % types.size
targetState += 5f
}) {
Text("Click")
}
AnimatedContent(
targetState = targetState,
transitionSpec = { getTransitionByAnimationType(types[index]) }
) {
Box(Modifier.size(it.dp, it.dp).background(Color.Black)) {
}
}
}
Hey, I couldn’t quite figure out the specific reproduction path in your code, so I kinda derived it from its content and came up with the code above inside setContent
There is nothing weird happening.Pablichjenkov
07/21/2023, 4:29 PMElijah Semyonov
07/21/2023, 4:33 PMPablichjenkov
07/21/2023, 4:34 PMElijah Semyonov
07/21/2023, 4:35 PMPablichjenkov
07/21/2023, 5:20 PMPablichjenkov
07/21/2023, 5:28 PMXcode Version 14.3.1 (14E300c)
works good.
You guys should probably start including the Xcode version/versions
used when tested the releases and other iOS stuff like `MacOS version`in the release notes too. Apple stuff aren't the greatest at keeping back compatibility and come really bundled up. Anything outside that combo will breakPablichjenkov
07/21/2023, 10:53 PMPablichjenkov
07/21/2023, 10:58 PM#0 0x00000001cde83c00 in semaphore_wait_trap ()
Which sounds suspiciousPablichjenkov
07/23/2023, 2:32 AMCannot find a version of 'org.jetbrains.skiko:skiko' that satisfies the version constraints:
Seems due to a transitive version conflict
Then tried:
configurations.all {
resolutionStrategy.force("org.jetbrains.skiko:skiko:0.7.68")
}
but doesn’t seems to take effect. Same error message.Pablichjenkov
07/24/2023, 4:57 AMElijah Semyonov
07/24/2023, 12:37 PMPablichjenkov
07/24/2023, 12:56 PMElijah Semyonov
07/24/2023, 12:57 PMPablichjenkov
07/26/2023, 6:54 PM