-
Notifications
You must be signed in to change notification settings - Fork 89
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
NoSuchElementException in Anvil.render() #119
Comments
@danhawkes Can you please provide a bit more context? What kind of layout is causing this? |
It's a two-way bound spinner field, something like this:
I believe it's caused by a race condition, as I can select an item from the spinner successfully several times, but occasionally the error occurs. Note all calls to render are happening on the main thread. |
I got the same error here when I use Anvil.render(this) inside my onStateChanged method from a RenderableView with a recycler view. class CustomView(context: Context : RenderableView(context)) {
fun onStateChanged(state: AppState) {
state = state
Anvil.render(this)
}
override fun view() {
RecyclerViewDSL7.recyclerView {
init {
// setup adapters
}
}
}
} |
Running version
0.5.2
:The text was updated successfully, but these errors were encountered: