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

"Configurations must be unique" error occurring in production #831

Open
pavel163 opened this issue Dec 27, 2024 · 3 comments
Open

"Configurations must be unique" error occurring in production #831

pavel163 opened this issue Dec 27, 2024 · 3 comments
Labels
question Further information is requested

Comments

@pavel163
Copy link

I have a root component on our screen which includes four configurations: A, B, C, where each configuration corresponds to a different screen. According to the logic, configurations B and C can only be added to the stack with A. However, I encounter production cases where the stack forms as A, B, C, B, which contradicts the designed behavior, as navigating to any screen should first require returning to a state where only A is in the stack.

Multiple root components are showing this issue

@arkivanov
Copy link
Owner

Sorry but I don't understand the issue. Can you ask a question or describe in more details?

@pavel163
Copy link
Author

I have a component similar to DefaultRootComponent, and it's organized in such a way that from one screen you can move to others (in the example these are Tabs). Over the last 90 days, there have been errors when a user navigated the following path: A (Tabs) -> B (DynamicFeatures) -> A (Tabs) -> C (CustomNavigation) -> A (Tabs) -> B (DynamicFeatures). For some reason, when these users returned to A (Tabs), the backstack was not cleared (the pop method was used for returning), and I receive the error java.lang.IllegalStateException - Configurations must be unique: [A, B, C, B].

@arkivanov
Copy link
Owner

It's hard to tell without any code or reproducer. Make sure you are using appropriate navigation functions. Duplicated configurations are not allowed. A possible issue is when the user double-clicks on a button or similar. Consider using pushNew for navigation.

@arkivanov arkivanov added the question Further information is requested label Dec 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants