question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[epoxy-paging] Notify Executor crash in PagedListEpoxyController.submitList when used with MvRx

See original GitHub issue

This is a follow on from #567 but specifically when used with MvRx.

I’m seeing sporadic: java.lang.IllegalArgumentException: The notify executor for your PagedList must use the same thread as the model building handler set in PagedListEpoxyController.modelBuildingHandler exceptions when used with MvRx.

I’ve checked the loopers in my Fragment’s invalidate() and Looper.myLooper == Looper.getMainLooper. I’m using the default modelBuildingHandler so I don’t think this is an obvious threading issue

My paging setup is here and my submit is here.

This might be something to do with the fact that MvRx is async all the time. I’ll try and debug this more tomorrow, but figured I’d throw this up here in case anyone is using MvRx + Paging + Epoxy together.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:8 (8 by maintainers)

github_iconTop GitHub Comments

2reactions
chrisbanescommented, Feb 9, 2019

Woops, turns out that I was manually setting defaultModelBuildingHandler 🤦‍♂️ . Thanks for the help!

0reactions
elihartcommented, Feb 10, 2019

Ah, glad you figured it out. Any thoughts on how to make it harder to make this mistake?

I think an easy change would be to print out the thread information of both threads when the same thread validation is done.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Timeline : try to get a better PagedList/Epoxy integration. Still ...
The notify thread of your PagedList (from setNotifyExecutor in the PagedList Builder) must be. * the same as this thread. Otherwise Epoxy will...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found