Status Update
Comments
gr...@google.com <gr...@google.com> #2
Please upgrade to
gr...@google.com <gr...@google.com> #4
Yep, you're right. Looks like the root cause of this separate issue was already fixed by 1.3.0
version would pull in the fix.
That fix is part of a 1.2.X
release, unfortunately.
I'll leave this open while we investigate what that would take.
gr...@google.com <gr...@google.com> #5
My apologies for not trying the latest alpha release beforehand. Upgrading to version 1.3.0
solves my case. Thank you for pointing that out.
ja...@gmail.com <ja...@gmail.com> #6
When using fragment-ktx:1.3.0-alpha03
, I'm still able to reproduce this issue. The following crash occurs on a configuration change:
java.lang.IllegalStateException: Fragment androidx.fragment.app.Fragment$4@5ff632e does not have a view
at androidx.fragment.app.Fragment$4.onFindViewById(Fragment.java:2711)
at androidx.fragment.app.FragmentStateManager.createView(FragmentStateManager.java:464)
at androidx.fragment.app.FragmentManager.moveToState(FragmentManager.java:1170)
at androidx.fragment.app.FragmentManager.moveToState(FragmentManager.java:1316)
at androidx.fragment.app.FragmentManager.moveFragmentToExpectedState(FragmentManager.java:1394)
at androidx.fragment.app.FragmentManager.moveToState(FragmentManager.java:1460)
at androidx.fragment.app.FragmentManager.dispatchStateChange(FragmentManager.java:2695)
at androidx.fragment.app.FragmentManager.dispatchActivityCreated(FragmentManager.java:2644)
at androidx.fragment.app.Fragment.performActivityCreated(Fragment.java:2784)
at androidx.fragment.app.FragmentStateManager.activityCreated(FragmentStateManager.java:507)
at androidx.fragment.app.FragmentManager.moveToState(FragmentManager.java:1171)
at androidx.fragment.app.FragmentManager.moveToState(FragmentManager.java:1316)
at androidx.fragment.app.FragmentManager.moveFragmentToExpectedState(FragmentManager.java:1394)
at androidx.fragment.app.FragmentManager.moveToState(FragmentManager.java:1460)
at androidx.fragment.app.FragmentManager.dispatchStateChange(FragmentManager.java:2695)
at androidx.fragment.app.FragmentManager.dispatchActivityCreated(FragmentManager.java:2644)
at androidx.fragment.app.FragmentController.dispatchActivityCreated(FragmentController.java:251)
at androidx.fragment.app.FragmentActivity.onStart(FragmentActivity.java:546)
at androidx.appcompat.app.AppCompatActivity.onStart(AppCompatActivity.java:201)
at android.app.Instrumentation.callActivityOnStart(Instrumentation.java:1392)
at android.app.Activity.performStart(Activity.java:7172)
at android.app.ActivityThread.handleStartActivity(ActivityThread.java:2967)
at android.app.servertransaction.TransactionExecutor.performLifecycleSequence(TransactionExecutor.java:180)
at android.app.servertransaction.TransactionExecutor.cycleToPath(TransactionExecutor.java:165)
at android.app.servertransaction.TransactionExecutor.executeLifecycleState(TransactionExecutor.java:142)
at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:70)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1816)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:193)
at android.app.ActivityThread.main(ActivityThread.java:6854)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:860)
gr...@google.com <gr...@google.com> #7
Thanks, this looks like an issue with DialogFragment
so fixing that underlying issue should fix PreferenceDialogFragmentCompat
as well.
gr...@google.com <gr...@google.com> #8
Branch: androidx-master-dev
commit 3c698888435fee8af2d911e54d1b9df9fd46648c
Author: Ian Lake <ilake@google.com>
Date: Tue Apr 21 16:46:50 2020
Fix onFindViewById in DialogFragment
Instead of only considering the Fragment's view,
DialogFragment should also consider the Dialog's
view when calling onFindViewById(). This ensures
that any <fragment> or FragmentContainerView that
is created as part of the Dialog's view structure
will properly be reattached to its view hierarchy
after a configuration change.
Test: updated DialogFragmentInflatedChildTest tests pass
BUG: 154366601
Change-Id: I59ada3193974f00ab4df475d992e237baa03c5bf
M fragment/fragment/src/androidTest/java/androidx/fragment/app/DialogFragmentInflatedChildTest.kt
M fragment/fragment/src/main/java/androidx/fragment/app/DialogFragment.java
M fragment/fragment/src/main/java/androidx/fragment/app/Fragment.java
M fragment/fragment/src/main/java/androidx/fragment/app/FragmentManager.java
M fragment/fragment/src/main/java/androidx/fragment/app/FragmentStateManager.java
se...@google.com <se...@google.com> #9
This has been fixed internally and will be available in Fragment 1.3.0-alpha04.
You can confirm the fix in your project by following the snapshot instructions at buildId
of 6419956
and Fragment 1.3.0-SNAPSHOT
.
se...@google.com <se...@google.com> #10
That was quick! It works as expected now. Much appreciated
ap...@google.com <ap...@google.com> #11
Branch: androidx-main
commit 76a2a7b35ef1398119cc0a5d7d0f553ce37eeef4
Author: Sean McQuillan <seanmcq@google.com>
Date: Mon Dec 04 13:40:44 2023
Text doesn't crash when text is very very tall
Previously: Constraints would run out of bits of text was too large
Now: Inner measures are constrained first by width, then by height
Fixes:
Test: ./gradlew :com:found:found:cAT
Relnote: Fix crash that impacted very large text measured with infinite constraints.
Change-Id: I1a7df0f35e5506b4ca05c4e2091142012a07908f
M compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/text/modifiers/LayoutUtilsKtTest.kt
M compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/text/modifiers/TextAnnotatedStringNodeTest.kt
M compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/text/modifiers/TextStringSimpleNodeTest.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/text/modifiers/LayoutUtils.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/text/modifiers/TextAnnotatedStringNode.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/text/modifiers/TextStringSimpleNode.kt
ap...@google.com <ap...@google.com> #12
Branch: androidx-main
commit 3a0cbbb01cb74bcbfc72797c5eb5bac5ad9e4cce
Author: Sean McQuillan <seanmcq@google.com>
Date: Tue Dec 05 10:39:42 2023
Add docs and more tests for fixCoercedHeightAndWidthForBits
Bug:
Test: ./gradlew :com:found:found:cAT
Change-Id: I7faf92e19d24550e4ceaf11c64afe6f67bd274cf
M compose/foundation/foundation/src/androidInstrumentedTest/kotlin/androidx/compose/foundation/text/modifiers/LayoutUtilsKtTest.kt
M compose/foundation/foundation/src/commonMain/kotlin/androidx/compose/foundation/text/modifiers/LayoutUtils.kt
na...@google.com <na...@google.com> #13
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.compose.foundation:foundation:1.6.0-beta03
androidx.compose.foundation:foundation-android:1.6.0-beta03
androidx.compose.foundation:foundation-desktop:1.6.0-beta03
Description
Reproduction
Text
LazyColumn
(same length text inColumn
does not crash)See attached sample project. I use a larger font size there to speed up the reproduction (rendering 5k times 24sp is a lot faster than 50k times 14sp).
Stack trace