Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
Mono organizations on
GitHub to continue tracking issues. Bugzilla will remain
available for reference in read-only mode. We will continue to work
on open Bugzilla bugs, copy them to the new locations
as needed for follow-up, and add the new items under Related
Our sincere thanks to everyone who has contributed on this bug
tracker over the years. Thanks also for your understanding as we
make these adjustments and improvements for the future.
Please create a new report on
Developer Community or GitHub with
your current version information, steps to reproduce, and relevant error
messages or log files if you are hitting an issue that looks similar to
this resolved bug and you do not yet see a matching new report.
Created attachment 15694 [details]
text from output window
I updated my app to use XF 126.96.36.199-pre2, but now I get the "Recursive entry to executePendingTransactions" exceptions every time I try to navigate. With the old version (2.1) I only got it sometimes and with 188.8.131.5208-pre3 I didn't see it at all.
My MainPage is a MasterDetailPage (MasterBehavior=Split) with NavigationPage for both Master and Detail. And my app uses AppCompat. On a phone, this is different, but I'm only testing on the tablet now.
The Master shows a ListView and when the user taps an item, then a new page is pushed to the Master navigation. OnAppearing of that new page in the Master I replace the whole navigation stack of the detail with a new page. I.e. I call InsertPageBefore to insert the new page at the beginning and then do a PopToRootAsync.
This results in an IllegalStateException: Recursive entry to executePendingTransactions
I attached all the text from my output window including the stack trace of the exception at the very end. The stack trace includes Xamarin.Forms.Platform.Android.AppCompat.NavigationPageRenderer.OnPopToRootAsync, so it appears that it happens in my master page's OnAppearing event where I call this method:
public static async Task NavigateDetailTo(ViewModel viewModel, bool focusDetail)
var mainPage = MainPage;
var md = mainPage as MasterDetailPage;
if(md != null)
var detailNav = md.Detail.Navigation;
var currentRoot = detailNav.NavigationStack;
var currentVM = currentRoot.BindingContext;
if (currentVM == null || currentVM.GetType() != viewModel.GetType())
var newPage = ViewFactory.CreatePage(viewModel);
currentRoot.BindingContext = viewModel;
if(detailNav.NavigationStack.Count > 1)
The output also shows that the app hangs when I try to build my MasterDetailPage with many thread/GC problems, but I'll open a separate bug for that.
I'll try to make a repro project for this bug and attach it when it is finished.
Created attachment 15696 [details]
repro project with XF 2.2
This repro project uses XF 184.108.40.206. The exception happens every time you tap an item in the ListView in the Master.
Created attachment 15697 [details]
repro project with XF 220.127.116.1129
This project uses the exact same code as the others, but it uses XF 18.104.22.16829. The exception comes sometimes when going back.
Created attachment 15698 [details]
repro project with XF 22.214.171.12408
This project also uses the exact same code, but XF 126.96.36.19908.
Navigation works as expected. There is no exception.
This is the same exception as in https://bugzilla.xamarin.com/show_bug.cgi?id=39403 although that was said to be fixed in 2.2.0-pre1. Well, maybe in case of a TabbedPage, but not with a MasterDetailPage.
*** Bug 40639 has been marked as a duplicate of this bug. ***
I now checked with XF 188.8.131.52 and 184.108.40.206-pre2 - still the same problem.
I would look at this myself, but unfortunately bug #39403 was fixed before XF was open sourced and thus I don't see what has been changed for that. Apparently those changes fixed the same exception for a TabbedPage but made it worse in my situation.
We have a fix in for this problem; it will be available in an upcoming release.
Should be fixed in 2.3.1-pre1
I have checked this issue with Xamarin.Forms 2.3.1-pre1 and used sample project attached in comment #1 and observed that its working fine.
Hence closing this issue.
Yes, looks good so far. Thank you!