Zhuinden / flowless

[DEPRECATED] Based on Flow 1.0-alpha. To keep your life simple, use zhuinden/simple-stack instead.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Flow.get() throws IllegalStateException before `onPostCreate()`

Zhuinden opened this issue · comments

Consider a way to obtain the instances in the context wrapper without relying on the retained fragment.

This came up in:

  • AsyncTask, where onPostExecute() is called after InternalLifecycleIntegration is already detached
  • Context.getSystemService() calling serviceProvider to see if it exists before onPostCreate(): Zhuinden/ExampleGithubClient#1

The first half should be fixed by 40ee88d

The second half should be fixed by 94faa27

....Flow cannot exist before onActivityCreated() if Flow is installed into the Activity installed by the Fragment.

Welp.

wontfix unless we go back to delegate, in which case services should be separated, in which case there is no point to this lib.