Skip to content
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 when pressing back after changing queset elementSelection #639

Closed
mnalis opened this issue Sep 4, 2024 · 1 comment
Closed

Crash when pressing back after changing queset elementSelection #639

mnalis opened this issue Sep 4, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@mnalis
Copy link
Collaborator

mnalis commented Sep 4, 2024

How to Reproduce

  1. open Quest selection and display order
  2. click a gear icon on e.g. Is there a shelter at this stop?
  3. do some change (e.g. modify today -4 years to today -5 years)
  4. confirm OK
  5. notice that the gear had not changed a color to RED (modified)
  6. press android back button
  7. get crash Unfortunately, SCEE has stopped.

Crash log:

scee crash on settings change

java.lang.NullPointerException
	at de.westnordost.streetcomplete.screens.settings.quest_selection.QuestSelection.isInteractionEnabled(QuestSelection.kt:12)
	at de.westnordost.streetcomplete.screens.settings.quest_selection.QuestSelectionItemKt.QuestSelectionItem(QuestSelectionItem.kt:114)
	at de.westnordost.streetcomplete.screens.settings.quest_selection.QuestSelectionListKt$QuestSelectionList$lambda$7$lambda$6$$inlined$itemsIndexed$default$3.invoke(LazyDsl.kt:464)
	at de.westnordost.streetcomplete.screens.settings.quest_selection.QuestSelectionListKt$QuestSelectionList$lambda$7$lambda$6$$inlined$itemsIndexed$default$3.invoke(LazyDsl.kt:183)
	at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:139)
	at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:35)
	at androidx.compose.foundation.lazy.LazyListItemProviderImpl$Item$1.invoke(LazyListItemProvider.kt:79)
	at androidx.compose.foundation.lazy.LazyListItemProviderImpl$Item$1.invoke(LazyListItemProvider.kt:77)
	at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:109)
	at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:35)
	at androidx.compose.runtime.CompositionLocalKt.CompositionLocalProvider(CompositionLocal.kt:248)
	at androidx.compose.foundation.lazy.layout.LazyLayoutPinnableItemKt.LazyLayoutPinnableItem(LazyLayoutPinnableItem.kt:58)
	at androidx.compose.foundation.lazy.LazyListItemProviderImpl.Item(LazyListItemProvider.kt:77)
	at androidx.compose.foundation.lazy.layout.LazyLayoutItemContentFactoryKt$SkippableItem$1.invoke(LazyLayoutItemContentFactory.kt:135)
	at androidx.compose.foundation.lazy.layout.LazyLayoutItemContentFactoryKt$SkippableItem$1.invoke(LazyLayoutItemContentFactory.kt:134)
	at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:109)
	at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:35)
	at androidx.compose.runtime.CompositionLocalKt.CompositionLocalProvider(CompositionLocal.kt:248)
	at androidx.compose.runtime.saveable.SaveableStateHolderImpl.SaveableStateProvider(SaveableStateHolder.kt:84)
	at androidx.compose.foundation.lazy.layout.LazySaveableStateHolder.SaveableStateProvider(LazySaveableStateHolder.kt:85)
	at androidx.compose.foundation.lazy.layout.LazyLayoutItemContentFactoryKt.SkippableItem-JVlU9Rs(LazyLayoutItemContentFactory.kt:134)
	at androidx.compose.foundation.lazy.layout.LazyLayoutItemContentFactoryKt.access$SkippableItem-JVlU9Rs(LazyLayoutItemContentFactory.kt:1)
	at androidx.compose.foundation.lazy.layout.LazyLayoutItemContentFactory$CachedItemContent$createContentLambda$1.invoke(LazyLayoutItemContentFactory.kt:101)
	at androidx.compose.foundation.lazy.layout.LazyLayoutItemContentFactory$CachedItemContent$createContentLambda$1.invoke(LazyLayoutItemContentFactory.kt:91)
	at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:109)
	at androidx.compose.runtime.internal.ComposableLambdaImpl.invoke(ComposableLambda.jvm.kt:35)
	at androidx.compose.runtime.RecomposeScopeImpl.compose(RecomposeScopeImpl.kt:192)
	at androidx.compose.runtime.ComposerImpl.recomposeToGroupEnd(Composer.kt:2556)
	at androidx.compose.runtime.ComposerImpl.skipCurrentGroup(Composer.kt:2827)
	at androidx.compose.runtime.ComposerImpl.doCompose(Composer.kt:3314)
	at androidx.compose.runtime.ComposerImpl.recompose$runtime_release(Composer.kt:3265)
	at androidx.compose.runtime.CompositionImpl.recompose(Composition.kt:940)
	at androidx.compose.runtime.Recomposer.performRecompose(Recomposer.kt:1155)
	at androidx.compose.runtime.Recomposer.access$performRecompose(Recomposer.kt:127)
	at androidx.compose.runtime.Recomposer$runRecomposeAndApplyChanges$2$1.invoke(Recomposer.kt:583)
	at androidx.compose.runtime.Recomposer$runRecomposeAndApplyChanges$2$1.invoke(Recomposer.kt:551)
	at androidx.compose.ui.platform.AndroidUiFrameClock$withFrameNanos$2$callback$1.doFrame(AndroidUiFrameClock.android.kt:41)
	at androidx.compose.ui.platform.AndroidUiDispatcher.performFrameDispatch(AndroidUiDispatcher.android.kt:109)
	at androidx.compose.ui.platform.AndroidUiDispatcher.access$performFrameDispatch(AndroidUiDispatcher.android.kt:41)
	at androidx.compose.ui.platform.AndroidUiDispatcher$dispatchCallback$1.doFrame(AndroidUiDispatcher.android.kt:69)
	at android.view.Choreographer$CallbackRecord.run(Choreographer.java:858)
	at android.view.Choreographer.doCallbacks(Choreographer.java:672)
	at android.view.Choreographer.doFrame(Choreographer.java:605)
	at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:846)
	at android.os.Handler.handleCallback(Handler.java:742)
	at android.os.Handler.dispatchMessage(Handler.java:95)
	at android.os.Looper.loop(Looper.java:157)
	at android.app.ActivityThread.main(ActivityThread.java:5603)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:774)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:652)

Expected Behavior

  • at step 5, color of the gear should be changed, as quest settings were modified
  • at step 7, there should be no crash, but app should go to previous menu

Does it happen in normal StreetComplete?
regular StreetComplete does not have that functionality

Versions affected
SCEE 58.22, Android 6.0.1 (Xiaomi Redmi Note 3)

@mnalis mnalis added the bug Something isn't working label Sep 4, 2024
@Helium314
Copy link
Owner

at step 5, color of the gear should be changed, as quest settings were modified

I don't want to bother with this. There are too many changes happening in SC, and I don't trust that quest selection screen is stable.

The actual issue it not something I can reproduce though. It points to the quest not being in the questTypeRegistry, but in that case it should not be in the quest selection screen...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants