This may help someone who may face a similar error:
After performing a series of test cases to find out the root cause of this crash, finally it was one line in the code that was the culprit.
And the line was -
@Override
public void onDestroy()
{
super.onDestroy();
tap.getEntriesByRule(view); // Culprit
}
Explanation:
The problem with this line is----
IT MESSED UP THE PENDING TRANSACTION.
While you are at fragment fragNoPop
and when you rotate the device, you goes to fragment fragPop
.
In fragPop, we have a culprit onDestroy() which again redirects to fragNoPop
with a call to tap.getEntriesByRule(view);
which is already destroyed on rotation. So now it is attached again causing a mess.
One line was enough for causing errors like execPendingActions
.
So first check such activity methods before anything else. Beware!